-
Notifications
You must be signed in to change notification settings - Fork 359
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
Fix the connection delay logic to use the header update block time #1917
Merged
Conversation
This file contains 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
hu55a1n1
changed the title
Return update height from update_client_{dst,src} methods
Fix the connection delay logic to use the target chain's latest block time and header update block time.
Feb 24, 2022
hu55a1n1
changed the title
Fix the connection delay logic to use the target chain's latest block time and header update block time.
Fix the connection delay logic to use the header update block time.
Feb 24, 2022
romac
reviewed
Feb 24, 2022
hu55a1n1
commented
Feb 24, 2022
hu55a1n1
commented
Feb 24, 2022
romac
changed the title
Fix the connection delay logic to use the header update block time.
Fix the connection delay logic to use the header update block time
Feb 25, 2022
hu55a1n1
force-pushed
the
hu55a1n1/1772-fix-conn-delay-check
branch
from
March 8, 2022 12:37
fc3b986
to
6181fb9
Compare
soareschen
requested changes
Mar 10, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we have an integration test to ensure that the connection delay logic is working correctly?
hu55a1n1
commented
Mar 10, 2022
hu55a1n1
commented
Mar 10, 2022
6 tasks
6 tasks
ancazamfir
reviewed
Mar 29, 2022
ancazamfir
reviewed
Mar 30, 2022
ancazamfir
reviewed
Mar 30, 2022
ancazamfir
reviewed
Mar 30, 2022
ancazamfir
reviewed
Mar 30, 2022
…malsystems/ibc-rs into hu55a1n1/1772-fix-conn-delay-check
soareschen
requested changes
Mar 30, 2022
soareschen
requested changes
Apr 1, 2022
soareschen
reviewed
Apr 1, 2022
soareschen
reviewed
Apr 1, 2022
soareschen
approved these changes
Apr 1, 2022
ancazamfir
approved these changes
Apr 5, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!! Thanks @hu55a1n1 !
5 tasks
hu55a1n1
added a commit
to hu55a1n1/hermes
that referenced
this pull request
Sep 13, 2022
…nformalsystems#1917) * Return update height from update_client_{dst,src} methods * Add query_host_consensus_state() * Set scheduled time appropriately * Handle connection delay only if batch contains packet events * Apply suggestion * Fix mock impl * Fix schedule_time calculation * Update comment * Fix comment * Add .changelog entry * Improve has_packet_msgs() * Implement query_host_consensus_state() for wrapper chain handles * Apply suggestion * Fix clippy errors * Rework update methods * Minor refactoring * Avoid partitioning events * Handle misbehaviour case explicitly * Add connection delay test * Use first UpdateClient event to determine processed_height * Add comment * Check for frozen clients in case of misbehavior during client update * Adjust connection delay for avg block time * Add TODO for moving to /header endpoint * Make update_client_dst() similar to update_client_src() * Fix integration test * Compare scheduled time against latest chain time * Allow query_host_consensus_state to return latest state when Height is zero * Fix conn delay elapsed calculation * Cleanup * Check for block delay * Add config comment for max_expected_time_per_block * Wait for conn delay * More comments * Extract all connection-delay logic from RelayPath * Address review feedback * Address review feedback * Closures for conn-delay specific lazy eval * Minor refactoring * Add helpers has_conn_delay_elapsed() and conn_delay_remaining() * Handle connection block delay * Cast block delay to u32 * Extract out CLI specific link code * Make opdata methods priv * Apply suggestions from review Co-authored-by: Soares Chen <[email protected]> Co-authored-by: Anca Zamfir <[email protected]>
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.
Closes: #1772
Description
Fix the connection delay logic to use the target chain's latest block time and header update block time.
PR author checklist:
unclog
.docs/
).Reviewer checklist:
Files changed
in the GitHub PR explorer.