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

[1.0.4] Fix fetch block with no block log #1059

Merged
merged 3 commits into from
Dec 10, 2024

Conversation

heifner
Copy link
Member

@heifner heifner commented Dec 6, 2024

The startup of producer_plugin uses fetch_block_by_number to prime on_irreversible_block with LIB.

const auto lib_num = chain.last_irreversible_block_num();
const auto lib = chain.fetch_block_by_number(lib_num);

When running without a block log, fetch_block_by_number always returned nullptr for LIB.

Update fetch_block_by_number and fetch_block_by_id to find LIB in fork database.

Resolves #1052

@heifner heifner requested review from greg7mdp and linh2931 December 6, 2024 19:50
@heifner heifner added the OCI Work exclusive to OCI team label Dec 6, 2024
@heifner heifner linked an issue Dec 6, 2024 that may be closed by this pull request
libraries/chain/fork_database.cpp Show resolved Hide resolved
@ericpassmore
Copy link
Contributor

Note:start
category: System Stability
component: Internal
summary: Fix fetch block with no block log. This removes unneeded warning by fixing underlying issue.
Note:end

@heifner heifner merged commit fbe8949 into release/1.0 Dec 10, 2024
36 checks passed
@heifner heifner deleted the GH-1052-fetch_block_no_block_log-1.0 branch December 10, 2024 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCI Work exclusive to OCI team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Invalid warn message on startup
4 participants