Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems with pickle.load(f) when f = filesystem.open(path) #67

Open
matschreiner opened this issue Jan 27, 2020 · 0 comments
Open

Problems with pickle.load(f) when f = filesystem.open(path) #67

matschreiner opened this issue Jan 27, 2020 · 0 comments

Comments

@matschreiner
Copy link

I can do the following just fine:

with file_system.open("/testing/blob", "rb") as f:
    byte_string = f.read()
    blob = pickle.loads(byte_string)

But if I do

with file_system.open("/testing/blob", "rb") as f:
    blob = pickle.load(f)

I get

Traceback (most recent call last):
  File "/programming/desupervised/mathias-playground/.venv/lib/python3.8/site-packages/IPython/core/interactiveshell.py", line 3319, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-4-e3e05a84eaca>", line 2, in <module>
    blob = pickle.load(f)
  File "/programming/desupervised/mathias-playground/.venv/lib/python3.8/site-packages/fs/iotools.py", line 116, in readinto
    return self._f.readinto(b)
  File "/programming/desupervised/mathias-playground/.venv/lib/python3.8/site-packages/fs_s3fs/_s3fs.py", line 154, in readinto
    return self._f.readinto()
TypeError: readinto() takes exactly one argument (0 given)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant