-
Notifications
You must be signed in to change notification settings - Fork 8
Implement docstring, missing methods, basic streaming #56
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
Merged
Merged
Changes from 21 commits
Commits
Show all changes
39 commits
Select commit
Hold shift + click to select a range
62380ed
Auto generating schema, docstring
Razikus 38f0f04
All messages into dataclasses
Razikus 0bdce95
Adding missing pytz
Razikus 9df2c4b
Covering api
Razikus 6bf405d
stream set
Razikus 044450f
StreamSet from buffer
Razikus 6fd0748
Streams as file-like objects
Razikus 6e95a93
Streams as file-like objects
Razikus f8cf508
Decrease test set size
Razikus ec7bf30
Decrease test set size
Razikus ddeb59d
Incrased reader size for one test
Razikus 30e0a9d
Changed definition, test for smaller set
Razikus 47dfdd1
structure change
Razikus 5d5d63f
Update grpc
Razikus 44e3501
Added tests, typing, docstring, replication, exporttx
Razikus 333442b
Updated docstring
Razikus 6bf7954
Autopep
Razikus b42d673
Added skips for older immudb versions
Razikus bc979ec
Autopep8 fixes
Razikus 8fa332a
Autopep fixes
Razikus 81f887e
removed unused imports
Razikus 5f80d7e
docs(ImmudbClient): revise and reformat docstring
NickAnderegg f100954
docs(openSession, openManagedSession): revise docstring
NickAnderegg 2679cff
docs(ImmudbClient.*): revise and clarify docstrings for various methods
NickAnderegg 4039e5e
docs(ImmudbClient.*): revise docstrings
NickAnderegg 50e437a
Add license
Razikus 07780c9
Adding comments
Razikus 8e7afe2
VerifiableSQL
Razikus 8d5b2ad
Merge branch 'feature/fullapisupport' of github.com:codenotary/immudb…
Razikus ea8a460
VerifiedSQL, 1.4.0 bump
Razikus 8fc5e96
removed unused dependency
Razikus 40ac334
StreamHistory, StreamZScan
Razikus 58ae1b7
stream verifiable get, stream zscan
Razikus cba5785
Verified Set
Razikus 433a5fa
removed bad assert
Razikus ff66cce
Stream Exec All
Razikus d268d96
Auto pep 8
Razikus 3ae0055
Adjustin pep8
Razikus 0380aac
Documentation update
Razikus File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
|
|
||
|
|
||
| import immudb.datatypesv2 as datatypesv2 | ||
|
|
||
|
|
||
| def convertResponse(fromResponse, toHumanDataClass=True): | ||
| """Converts response from GRPC to python dataclass | ||
| Args: | ||
| fromResponse (GRPCResponse): GRPC response from immudb | ||
| toHumanDataClass (bool, optional): decides if final product should be converted to 'human' dataclass (final product have to override _getHumanDataClass method). Defaults to True. | ||
| Returns: | ||
| DataClass: corresponding dataclass type | ||
| """ | ||
| if fromResponse.__class__.__name__ == "RepeatedCompositeContainer": | ||
| all = [] | ||
| for item in fromResponse: | ||
| all.append(convertResponse(item)) | ||
| return all | ||
| schemaFrom = datatypesv2.__dict__.get( | ||
| fromResponse.__class__.__name__, None) | ||
| if schemaFrom: | ||
| construct = dict() | ||
| for field in fromResponse.ListFields(): | ||
| construct[field[0].name] = convertResponse(field[1], False) | ||
| if toHumanDataClass: | ||
| return schemaFrom(**construct)._getHumanDataClass() | ||
| else: | ||
| return schemaFrom(**construct) | ||
| else: | ||
| return fromResponse | ||
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.