[IBC] Implement ICS-24 - Tracking IBC store transitions in the network state#847
[IBC] Implement ICS-24 - Tracking IBC store transitions in the network state#847
Conversation
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## ibc/initial_module #847 +/- ##
======================================================
- Coverage 31.44% 30.91% -0.54%
======================================================
Files 110 114 +4
Lines 9190 9595 +405
======================================================
+ Hits 2890 2966 +76
- Misses 5955 6282 +327
- Partials 345 347 +2
☔ View full report in Codecov by Sentry. |
️✅ There are no secrets present in this pull request anymore.If these secrets were true positive and are still valid, we highly recommend you to revoke them. 🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request. |
Olshansk
left a comment
There was a problem hiding this comment.
Reviewed a handful of files and replied to the question around testing.
Lmk if it helps and also please rebased this and the other branches with master when you have a chance!
36a8056 to
8cd1fab
Compare
c742a50 to
d430efe
Compare
|
🚨 I REWROTE HISTORY 🚨 This PR was based off of numerous other branches which have now been merged into main. Because of this I have rebased entirely off of |
8cd1fab to
f482e14
Compare
24c4047 to
2c4a04b
Compare
d505fb0 to
5bb0adf
Compare
@Olshansk Dunno why it did this, I merged with main earlier today o-o did again should be fine now |
|
@h5law Replied to some of the lingering comments. Re-request a review once done / replied to and I'll take a final look. |



Description
Summary generated by Reviewpad on 12 Jul 23 20:45 UTC
This pull request includes the following changes:
The file
main_test.gowas newly added to the repository and includes various changes such as package definition, imports, variable declaration, and function definitions related to IBC modules testing.The file
proofs_ics23.goincludes changes in error handling for the functionscreateMembershipProofandcreateNonMembershipProof, replacing the errorcoreTypes.ErrCreatingProofwithcoreTypes.ErrIBCCreatingProoffor more specific error messages.The file
keys_ics03.gowas renamed from theibc/hostdirectory to theibc/pathdirectory. Additionally, the package declaration was changed fromhosttopath. These changes seem related to the organization of the file within the codebase.The
config.validator2.jsonfile includes changes in theibcsection, adding two new keys:private_keyandstores_dir. Theenabledkey remains unchanged. Theprivate_keykey has been assigned a long string value, and thestores_dirkey has been assigned the value "/var/ibc".The file
internal/testutil/ibc/mock.goincludes renaming of the functionsBaseIbcMocktoBaseIBCMockandIbcMockWithHosttoIBCMockWithHost. These changes update the function names to follow proper naming conventions.The file includes the implementation of a store manager for IBC (Inter-Blockchain Communication), responsible for managing provable stores, caching, pruning, and restoring data.
The addition of a new function,
GetIBCStoreUpdates, which retrieves the set of key-value pairs updated at the current height for the IBC store.Changes in the state hashes used in the tests in the file
state_test.go.The file
runtime/manager_test.goincludes the addition of new fieldsPrivateKeyandStoresDirto theIBCstruct in theNewManagerFromReadersfunction.Changes in the
config.validator4.jsonfile include modifications in theibcsection, adding two new properties:private_keyandstores_dir. Theenabledproperty remains unchanged.The file
prefix.gowas renamed from theibc/hostpackage to theibc/pathpackage. The similarity index indicates that most of the content remains unchanged.There was a change in error handling logic in a file involving the renaming of the error variable and addressing the error during the creation of a new public key.
The file
gov.goincludes changes in import statements, variable declarations, and function modifications related to new IBC store transaction fees.The file
persistence/types/ibc.gois a new file added to the codebase, containing functions and constants related to IBC.The file
persistence/types/ibc.goin thepersistencepackage includes changes, introducing methods for setting and retrieving key-value pairs in the IBC store table.The file
persistence/trees.goincludes changes related to the addition of a new tree and corresponding functions to handle updates for the tree.The file
utils_test.goincludes changes in the casing of a function call fromibcUtils.IbcMockWithHosttoibcUtils.IBCMockWithHost.The file
ibc/host/path_test.gowas renamed toibc/path/path_test.gowith no other changes in the file.Changes in default variable values related to IBC functionality.
The file
db.goincludes a new function,initialiseIBCTables, responsible for initializing an IBC store table in a PostgreSQL database.A new file,
ibc.feature.wip, was added, containing integration and end-to-end tests for various scenarios related to IBC functionality.Changes in the
PROTOCOL_STATE_HASH.mdfile include additions and modifications related to the IBC state tree and the handling of IBCMessage objects.The file
ibc/host.goincludes changes in comments, import statements, and the addition of fields and methods related to the host's interaction with the IBC store.A new file,
convert.go, was added in theibc/typesdirectory, containing functions and imports to work with IBC messages.Changes in the
utils_test.gofile include modifications in the casing of a function call fromibcUtils.IbcMockWithHosttoibcUtils.IBCMockWithHost.The file
ibc/host/path_test.gowas renamed toibc/path/path_test.gowith no other changes in the file.Changes in default variable values related to IBC functionality.
A new file,
db.go, was added, containing a functionIssue
Fixes #840
Type of change
Please mark the relevant option(s):
List of changes
IbcMessageprotobuf with 2 typesUpdateIbcStoreandPruneIbcStoreTesting
make develop_test; if any code changes were mademake test_e2eon k8s LocalNet; if any code changes were madee2e-devnet-testpasses tests on DevNet; if any code was changedRequired Checklist
godocformat comments on touched members (see: tip.golang.org/doc/comment)If Applicable Checklist
shared/docs/*if I updatedshared/*README(s)