-
Notifications
You must be signed in to change notification settings - Fork 792
Refactor branch walk #1175 #1176
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
Conversation
14868ad to
4ad2512
Compare
libraries/chain/database.cpp
Outdated
| witness_time_pairs.push_back( std::make_pair( b->data.witness, b->data.timestamp ) ); | ||
| } | ||
|
|
||
| ilog( "Encountered a block num collision due to a fork. Walking the current fork to determine the correct block. block_num:${n}", ("n", height) ); |
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.
We should combine these messages and make the logging accurate. Something like, "Encountered block num collision at block ${n} produced by witnesses ${w}" This also removes the statement that we are walking the fork, which we are not doing at this point in the code.
|
Still not building. Will fix the build and address the above comment momentarily. |
4ad2512 to
1f80f5f
Compare
libraries/chain/database.cpp
Outdated
| return result; | ||
| } | ||
|
|
||
| void database::_maybe_warn_multiple_production( const database& db, uint32_t height )const |
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.
If this method is a member of database, why pass a const reference to itself?
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.
Good catch, originally it wasn't, but then I saw _fork_db was private.
0422f28 to
33ecf12
Compare
PR for #1175