Skip to content

fix: fix inspect database error#2484

Merged
zzzckck merged 2 commits intobnb-chain:developfrom
jingjunLi:fix-inspect-database
May 27, 2024
Merged

fix: fix inspect database error#2484
zzzckck merged 2 commits intobnb-chain:developfrom
jingjunLi:fix-inspect-database

Conversation

@jingjunLi
Copy link
Copy Markdown
Contributor

@jingjunLi jingjunLi commented May 21, 2024

Description

When executing inspect, an error in judgment causes block data to be repeatedly traversed, resulting in a large amount of data being marked as unaccounted.

Rationale

In Go, directly comparing two interface values for equality is generally unsafe, especially for complex types like the database interface ethdb.Database. This is because interface comparison checks not only their values but also whether their dynamic types match.

Add the HasSeparateBlockStore interface to indicate whether a separate block store is enabled.

Example

add an example CLI or API response...

Changes

Notable changes:

  • add each change in a bullet point here
  • ...

@jingjunLi jingjunLi requested review from RenRick, flywukong and fynnss May 21, 2024 04:17
Copy link
Copy Markdown
Contributor

@flywukong flywukong left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Contributor

@sysvm sysvm left a comment

Choose a reason for hiding this comment

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

LGTM

@zzzckck zzzckck merged commit 05543e5 into bnb-chain:develop May 27, 2024
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