Skip to content

Bug/etcm 636 [!pr] #925

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

Merged
merged 8 commits into from
Feb 25, 2021
Merged

Bug/etcm 636 [!pr] #925

merged 8 commits into from
Feb 25, 2021

Conversation

AnastasiiaL
Copy link
Contributor

Description

None.get on bestBlock happened because of the inconsistency between cache and db. This PR introduces uni and integration tests that try to reproduce the issue. In case of it test - it's not possible to reproduce as probable cause is the thread of execution dying in the middle of updates.

Also updating one method with preferred order of execution - first saving to cache, after to db.

@leo-bogastry
Copy link
Contributor

Is this PR dependant on #925 being merged? Meaning that you will have to update the tests?

@AnastasiiaL
Copy link
Contributor Author

Is this PR dependant on #925 being merged? Meaning that you will have to update the tests?

mostly that's a separate effort here of investigating the underlying causes of that none.get situation. But the tests will be impacted a bit, given that the getBestBlock will return option after Bogdan's PR is merged.

Copy link

@pullrequest pullrequest bot left a comment

Choose a reason for hiding this comment

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

✅ This pull request was sent to the PullRequest network.


@AnastasiiaL you can click here to see the review status or cancel the code review job - or - cancel by adding [!pr] to the title of the pull request.

@AnastasiiaL AnastasiiaL changed the title Bug/etcm 636 Bug/etcm 636 [!pr] Feb 16, 2021
Copy link

@pullrequest pullrequest bot left a comment

Choose a reason for hiding this comment

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

This pull request would normally be cancelled because the title contains "[!pr]"; however since the review was requested manually from the PullRequest dashboard, it was sent to our network to be reviewed. If you wish to cancel PullRequest review, you can do so manually from the PullRequest dashboard.

Copy link

@pullrequest pullrequest bot left a comment

Choose a reason for hiding this comment

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

⚠️ Warning

PullRequest detected a force-push on this branch. This may have caused some information to be lost, and additional time may be required to complete review of the code. Read More

Copy link

@pullrequest pullrequest bot left a comment

Choose a reason for hiding this comment

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

This looks reasonable overall. There were two main themes to my comments:

  • Repeated chackpoint typo
  • Trying to make the tests more readable. This includes:
    • Shortening the setup. Boilerplate tends to hide bugs.
    • Emphasizing what differentiates some seemingly similar tests.
    • Perhaps improving some of the prose test descriptions? Some didn't seem to obviously correspond to the actual code (e.g. not sure about the 'from morpho' part and the 'and back' part of 'longer chain to a shorter one and back' wasn't clear to me)
    • Trying to clarify the state of the blockchain at important times. There's a lot of updating of the chain and which implicitly asks the reader to track chain state in their head.

However, I don't have full context on this area so the comments in the second bullet here may be off the mark.

Image of Eric E Eric E


Reviewed with ❤️ by PullRequest

Copy link
Contributor

@1015bit 1015bit left a comment

Choose a reason for hiding this comment

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

👍 Only left some minor comments. Let's have a quick call today and then it's ✔️ from my side.

@AnastasiiaL AnastasiiaL merged commit b45bf0c into develop Feb 25, 2021
@AnastasiiaL AnastasiiaL deleted the bug/ETCM-636 branch February 25, 2021 13:56
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.

4 participants