Skip to content
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

use height to hash in short sync #19007

Merged
merged 3 commits into from
Dec 11, 2024
Merged

Conversation

almogdepaz
Copy link
Contributor

@almogdepaz almogdepaz commented Dec 9, 2024

Purpose:

dont use the cache to locate the forkpoint

Current Behavior:

we use the block records cache to determine fork point even though the cache may contain orphan blocks, this can cause us to use a wrong fork point while syncing

New Behavior:

use height to hash which is more correct

Testing Notes:

@almogdepaz almogdepaz added full_node sync Fixed Required label for PR that categorizes merge commit message as "Fixed" for changelog labels Dec 9, 2024
@almogdepaz almogdepaz requested a review from arvidn December 9, 2024 16:54
@almogdepaz almogdepaz marked this pull request as ready for review December 9, 2024 16:54
@almogdepaz almogdepaz requested a review from a team as a code owner December 9, 2024 16:54
Copy link

coveralls-official bot commented Dec 9, 2024

Pull Request Test Coverage Report for Build 12275663924

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 8 of 8 (100.0%) changed or added relevant lines in 1 file are covered.
  • 244 unchanged lines in 14 files lost coverage.
  • Overall coverage increased (+0.07%) to 91.537%

Files with Coverage Reduction New Missed Lines %
chia/_tests/wallet/test_transaction_store.py 1 99.58%
chia/_tests/core/full_node/stores/test_full_node_store.py 1 99.5%
chia/_tests/core/full_node/stores/test_block_store.py 2 99.53%
chia/_tests/pools/test_pool_rpc.py 3 99.07%
chia/wallet/transaction_record.py 3 97.74%
chia/wallet/wallet_transaction_store.py 5 97.9%
chia/_tests/blockchain/test_blockchain.py 9 99.26%
chia/_tests/core/full_node/test_full_node.py 10 98.62%
chia/_tests/wallet/sync/test_wallet_sync.py 12 98.63%
chia/_tests/core/mempool/test_mempool.py 13 98.75%
Totals Coverage Status
Change from base Build 12209661102: 0.07%
Covered Lines: 104661
Relevant Lines: 114156

💛 - Coveralls

chia/full_node/full_node.py Outdated Show resolved Hide resolved
@arvidn arvidn requested a review from emlowe December 11, 2024 12:37
@arvidn arvidn added the ready_to_merge Submitter and reviewers think this is ready label Dec 11, 2024
@pmaslana pmaslana merged commit 3ab83f0 into main Dec 11, 2024
364 checks passed
@pmaslana pmaslana deleted the fix-contains-block-in-short-sync branch December 11, 2024 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Fixed Required label for PR that categorizes merge commit message as "Fixed" for changelog full_node ready_to_merge Submitter and reviewers think this is ready sync
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants