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

Allow zip output from writing in-memory dataset #402

Open
brendan-ward opened this issue May 1, 2024 · 0 comments
Open

Allow zip output from writing in-memory dataset #402

brendan-ward opened this issue May 1, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@brendan-ward
Copy link
Member

Follow-on to #397

Some drivers create multiple files and we cannot write them to an io.BytesIO object and have them correctly handled later, but GDAL creates these successfully within the in-memory directory that we use.

It would be possible to write these to the io.BytesIO object if we zipped the in-memory directory, and then write that zipfile to the io.BytesIO object.

We could handle this by adding a zipped=True (or similar) parameter to write() / write_arrow() / write_dataframe() functions.

Alternatively, it might be possible to pass in an open zipfile.ZipFile instance and write files / directories from the in-memory directory to it. Unclear if this would be simpler.

@brendan-ward brendan-ward added the enhancement New feature or request label May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant