refactor(storage): create StorageProtocol#922
Merged
Conversation
1 task
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #922 +/- ##
=========================================
Coverage ? 85.38%
=========================================
Files ? 288
Lines ? 22392
Branches ? 3372
=========================================
Hits ? 19119
Misses ? 2604
Partials ? 669 ☔ View full report in Codecov by Sentry. |
jansegre
previously approved these changes
Jan 12, 2024
msbrogli
requested changes
Jan 12, 2024
b00ac06 to
0babd4f
Compare
jansegre
previously approved these changes
Jan 16, 2024
msbrogli
previously approved these changes
Jan 19, 2024
edcaf56 to
2044574
Compare
6151b38 to
79dbc63
Compare
jansegre
approved these changes
Jan 19, 2024
msbrogli
approved these changes
Jan 19, 2024
79dbc63 to
30c055b
Compare
2 tasks
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.
Motivation
To externalize storage dependencies from the verification process, we need to inject a storage into some methods used in verification, so it can either receive a
TransactionStorage(rocksdb), or a simple memory storage that will be implemented in next PRs. To unify both of them in a single interface, a Python protocol is introduced,StorageProtocol.Acceptance Criteria
StorageProtocol, a protocol for unifying a subset of storage methods.TransactionStorageso it conforms to theStorageProtocol.StorageProtocol, and update usages accordingly.Transactionmethods so they depend on aStorageProtocol, and update usages accordingly.Checklist
master, confirm this code is production-ready and can be included in future releases as soon as it gets merged