Skip to content
This repository was archived by the owner on Aug 2, 2022. It is now read-only.

Add log path for unsupported log version exception - #9906

Merged
huangminghuang merged 2 commits into
release/2.1.xfrom
add_log_path_to_assert_msg
Jan 19, 2021
Merged

huangminghuang merged 2 commits into
release/2.1.xfrom
add_log_path_to_assert_msg

Conversation

@allenhan2

@allenhan2 allenhan2 commented Jan 13, 2021 •

Copy link
Copy Markdown
Contributor

Change Description

For issue: #9871

Change Type

Select ONE:

  • Documentation
  • Stability bug fix
  • Other
  • Other - special case

warn 2021-01-19T17:55:50.003 thread-0 chain_plugin.cpp:1321 plugin_initialize ] 3190001 block_log_unsupported_version: unsupported version of block log
Unsupported version of block log. Block log version is 808464432 while code supports version(s) [1,4], log file: /Users/yue.han/workspace/eosio/develop/bin/dogfooding/data/blocks/blocks.log
{"version":808464432,"min":1,"max":4,"log":"/Users/yue.han/workspace/eosio/develop/bin/dogfooding/data/blocks/blocks.log"}
thread-0 block_log.cpp:57 read_from

error 2021-01-19T17:55:50.003 thread-0 main.cpp:163 main ] 3190001 block_log_unsupported_version: unsupported version of block log
Unsupported version of block log. Block log version is 808464432 while code supports version(s) [1,4], log file: /Users/yue.han/workspace/eosio/develop/bin/dogfooding/data/blocks/blocks.log
{"version":808464432,"min":1,"max":4,"log":"/Users/yue.han/workspace/eosio/develop/bin/dogfooding/data/blocks/blocks.log"}
thread-0 block_log.cpp:57 read_from
rethrow
{}
thread-0 chain_plugin.cpp:1321 plugin_initialize

Testing Changes

Select ANY that apply:

  • New Tests
  • Existing Tests
  • Test Framework
  • CI System
  • Other

Consensus Changes

  • Consensus Changes

API Changes

  • API Changes

Documentation Additions

  • Documentation Additions

Comment thread libraries/chain/block_log.cpp Outdated
uint32_t first_block_num = 0;
std::variant<genesis_state, chain_id_type> chain_context;
fc::path log_path;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Just pass the log_path as a parameter to block_log_preamble::read_from() is enough. There's no reason the keep log_path as a member variable.

@huangminghuang
huangminghuang merged commit 5ec99e0 into release/2.1.x Jan 19, 2021
@allenhan2
allenhan2 deleted the add_log_path_to_assert_msg branch January 19, 2021 19:49
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants