Implement reading qvd files from Python IO#27
Open
msimmoteit-neozo wants to merge 1 commit intoSBentley:masterfrom
Open
Implement reading qvd files from Python IO#27msimmoteit-neozo wants to merge 1 commit intoSBentley:masterfrom
msimmoteit-neozo wants to merge 1 commit intoSBentley:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi,
I'm a big fan of this library. It has really helped me to work with QVD files. Thank you so much.
Currently this library only works when reading in qvd files via a file name, but I have a use case, where the data I want to read in is not available in to my Python interpreter in that format. I would like to read in qvd files from either in-memory bytes from Python or from Python File objects:
As a starting point I implemented this myself.
Now, with these changes, qvd files can be read in the current way:
But also via
I also added an error message for a common mistake one could make:
There is room for improvement here, as there is code duplication between the function
read_qvdandread_qvd_from_buffer. I tried to unify it, but the BufRead of the Cursor over theVec<u8>and the BufRead on the file behaved differently, so I let it like it is.Maybe someone else finds a way to make it better?