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

Pass **kwargs into pipe_file() #992

Closed
hungcs opened this issue Jul 19, 2022 · 0 comments · Fixed by #993
Closed

Pass **kwargs into pipe_file() #992

hungcs opened this issue Jul 19, 2022 · 0 comments · Fixed by #993

Comments

@hungcs
Copy link
Contributor

hungcs commented Jul 19, 2022

Is there a reason why pipe_file() silently drops **kwargs here? https://github.com/fsspec/filesystem_spec/blob/master/fsspec/spec.py#L679

could this be changed to

def pipe_file(self, path, value, **kwargs):
    """Set the bytes of given file"""
    with self.open(path, "wb", **kwargs) as f:
        f.write(value)

Happy to open a pr for this!
I'm trying to pass in content_type="image/svg+xml" here and it's being silently ignored.

fsspec/adlfs#294

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

Successfully merging a pull request may close this issue.

1 participant