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

Cherry pick #1858 to release/1.5.x #1861

Merged
merged 2 commits into from
Feb 28, 2022
Merged

Conversation

nategraf
Copy link
Contributor

Description

This PR cheery picks #1858 to the release branch,
1.5.x and additionally sets the version number to 1.5.4-stable for release.

piersy and others added 2 commits February 28, 2022 12:12
* Enusre pending state is ready for tx execution

This commit ensures that StateDB.Prepare is called on the pending state
before it is returned from the miner/worker. This prevents access logs
from previous transaction executions from interfering with the gas cost
calculations of the subsequently executed transaction.

The problem this solves was introdued by this upstream PR
ethereum/go-ethereum#21509 which added an
access list to the state which was used to reduce gas costs for repeated
access of the same state locations, this resulted in the pending block
having the access list of the last executed transaction, which could
cause gas estimates to be wrong when the estimated transaction accessed
some of the same state as the prior transaction.

* Add more in depth comment on call to Prepare
@nategraf nategraf requested a review from a team as a code owner February 28, 2022 20:16
@nategraf nategraf requested review from mcortesi and piersy and removed request for a team February 28, 2022 20:16
@piersy
Copy link
Contributor

piersy commented Feb 28, 2022

Coverage from tests in ./e2e_test/... for ./consensus/istanbul/... at commit f8a8126

coverage: 51.8% of statements across all listed packages
coverage:  64.4% of statements in consensus/istanbul
coverage:  52.3% of statements in consensus/istanbul/backend
coverage:   0.0% of statements in consensus/istanbul/backend/backendtest
coverage:  50.0% of statements in consensus/istanbul/backend/internal/db
coverage:  46.0% of statements in consensus/istanbul/backend/internal/enodes
coverage:  24.3% of statements in consensus/istanbul/backend/internal/replica
coverage:  71.3% of statements in consensus/istanbul/core
coverage:   0.0% of statements in consensus/istanbul/proxy
coverage:  75.3% of statements in consensus/istanbul/uptime
coverage: 100.0% of statements in consensus/istanbul/uptime/store
coverage:  51.8% of statements in consensus/istanbul/validator
coverage:  79.2% of statements in consensus/istanbul/validator/random
CommentID: 729a2ec306

@nategraf nategraf merged commit cf07944 into release/1.5.x Feb 28, 2022
@nategraf nategraf deleted the victor/cherry-pick-1858 branch February 28, 2022 23:18
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.

2 participants