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

set_proposed_finalizers should not have side-effects if transaction fails #77

Closed
arhag opened this issue Apr 26, 2024 · 0 comments · Fixed by #99
Closed

set_proposed_finalizers should not have side-effects if transaction fails #77

arhag opened this issue Apr 26, 2024 · 0 comments · Fixed by #99
Assignees
Labels
bug The product is not working as was intended. 👍 lgtm

Comments

@arhag
Copy link
Member

arhag commented Apr 26, 2024

Currently, the proposed finalizer policy will take affect even if the transaction is aborted. Instead, if the transaction is aborted, the chain should act as if the finalizer policy was not proposed. This requires changes to state stored in Chainbase, which means changes to the snapshot structure as well. Since this is the first time it is changing since Leap 5, we require adding a new version of the chain state (captured in database_header_object).

Note: It appears that we have made changes to Chainbase in the past without updating the version in database_header_object. The last official version in that object was 2 which was introduced with the changes for EOSIO 2.0. Since then we have made other changes to Chainbase without bumping to version higher.

Regardless, we should start using it now. To correct for the mistake of not touching this over the past updates, we should do the following:

  1. Retroactively pretend that version 2 includes not just the changes introduced in EOSIO 2.0 but also every other change to Chainbase since then up to and including Leap 5.0. The comments should be updated to reflect this.
  2. We should update the current_version to a new version 3 that captures the changes we introduce in this Spring 1.0 release.
  3. We should also bump the minimum_version to 3.

Since we are changing Chainbase anyway, it would be good opportunity to remove kv_database_config from the global_property_object (and from the snapshot) in this version 3 as well.

@arhag arhag added this to the Savanna: Production-Ready milestone Apr 26, 2024
@arhag arhag added bug The product is not working as was intended. 👍 lgtm labels Apr 26, 2024
@linh2931 linh2931 moved this from Todo to In Progress in Team Backlog Apr 30, 2024
@linh2931 linh2931 moved this from In Progress to Awaiting Review in Team Backlog May 2, 2024
@github-project-automation github-project-automation bot moved this from Awaiting Review to Done in Team Backlog May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The product is not working as was intended. 👍 lgtm
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants