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

add Get/SetContentIOBuffer #38

Closed
casperdcl opened this issue May 17, 2020 · 0 comments · Fixed by #39
Closed

add Get/SetContentIOBuffer #38

casperdcl opened this issue May 17, 2020 · 0 comments · Fixed by #39
Assignees
Labels
enhancement New feature or request

Comments

@casperdcl
Copy link
Contributor

Support file-like IO (open().read(), write()) methods.

Currently can only Get/SetContent based on strings or filenames.

CC @shcheklein @efiop

@casperdcl casperdcl added the enhancement New feature or request label May 17, 2020
@casperdcl casperdcl self-assigned this May 17, 2020
casperdcl added a commit that referenced this issue May 17, 2020
shcheklein pushed a commit that referenced this issue May 30, 2020
* add files.GetContentIOBuffer

Fixes #38

* files: tidy and abstract common wrapper

* add encoding param

* mode decode to IoBuffer

* remove `read(chunksize)` for now

- see 
#39 (comment)

* add files.MediaIoReadable.__iter__

* add files.GetContentIOBuffer(remove_bom)

* tidy remove_bom

* test GetContentIOBuffer

* fix GetBOM usage

* misc tidy

* test GetContentIOBuffer(remove_bom)

* fix error handling

* fix tests encoding

* silly assertion fix
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

Successfully merging a pull request may close this issue.

1 participant