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

Store COINBASE in storage_var #1069

Merged
merged 2 commits into from
Apr 4, 2024

Conversation

ClementWalter
Copy link
Member

@ClementWalter ClementWalter commented Apr 4, 2024

Made coinbase storage var a constructor argument rather than a hardcoded value.

Time spent on this PR: 1 hour
(methodology: searched the whole source tree for "coinbase", "0xCA40", "precompiles", and "uninitialized")

Pull request type

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

Currently Coinbase is a hardcoded constant value (0xCA40796aFB5472abaeD28907D5ED6FC74c04954a) duplicated in a few places in the .py and .cairo sources.

Resolves #1011

What is the new behavior?

That constant is now defined in a single location in constants.py and imported as needed. Accordingly, codebase is also passed as a new argument in the "kakarot" and "EVM" constructors.


This change is Reviewable

@ClementWalter ClementWalter merged commit 42bbc4e into kkrt-labs:main Apr 4, 2024
6 checks passed
@ClementWalter ClementWalter deleted the cw/coinbase-storage-var branch April 4, 2024 15:09
This was referenced Apr 11, 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.

dev: make coinbase storage var a constructor argument rather than a hardcoded value
3 participants