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

Fix some trie prints on dev #3660

Merged
merged 3 commits into from
Dec 23, 2021
Merged

Fix some trie prints on dev #3660

merged 3 commits into from
Dec 23, 2021

Conversation

BeniaminDrasovean
Copy link
Contributor

Do not snapshot after start in epoch on peer trie. (this was done for the user trie on a previous PR)

sasurobert
sasurobert previously approved these changes Dec 22, 2021
@@ -301,7 +301,10 @@ func (tsm *trieStorageManager) Get(key []byte) ([]byte, error) {
return nil, ErrContextClosing
}

val, _ := tsm.mainStorer.Get(key)
val, err := tsm.mainStorer.Get(key)
if checkIfClosingError(err) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this ok? Shouldn't have been !checkIfClosingError(err) ? Also, I would call this simply isClosingError

Here and on L317, L329

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If there is a closing err, it should not continue to search in other dbs, but return the err. Changed the func name.

@codecov
Copy link

codecov bot commented Dec 22, 2021

Codecov Report

Merging #3660 (53ac8a8) into development (33514b4) will decrease coverage by 0.01%.
The diff coverage is 32.00%.

❗ Current head 53ac8a8 differs from pull request most recent head 8579495. Consider uploading reports for the commit 8579495 to get more accurate results
Impacted file tree graph

@@               Coverage Diff               @@
##           development    #3660      +/-   ##
===============================================
- Coverage        73.70%   73.68%   -0.02%     
===============================================
  Files              587      587              
  Lines            76011    76030      +19     
===============================================
+ Hits             56022    56024       +2     
- Misses           15552    15562      +10     
- Partials          4437     4444       +7     
Impacted Files Coverage Δ
trie/trieStorageManager.go 49.86% <28.57%> (-0.84%) ⬇️
trie/snapshotTrieStorageManager.go 61.76% <33.33%> (-3.87%) ⬇️
state/peerAccountsDB.go 83.82% <37.50%> (-6.35%) ⬇️
p2p/libp2p/netMessenger.go 74.72% <0.00%> (-0.28%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 731ca46...8579495. Read the comment docs.

Copy link
Contributor

@LucianMincu LucianMincu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

System tests passed.

@LucianMincu LucianMincu merged commit 831ec19 into development Dec 23, 2021
@LucianMincu LucianMincu deleted the trie-err-on-dev branch December 23, 2021 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants