-
Notifications
You must be signed in to change notification settings - Fork 9
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
feat: adding hardhat #626
feat: adding hardhat #626
Conversation
- Add Hardhat node service with Docker configuration - Configure hardhat.config.js with local network settings - Add 20 test accounts with 10,000 ETH each - Add web3 Python package to backend requirements - Update .gitignore for Hardhat artifacts and cache
- Add contract compilation setup with hardhat - Configure project structure for smart contracts - Fix file path for GhostContract.json artifact - Add necessary dependencies for contract compilation - Setup directory structure for contracts and artifacts
- Moved web3 python package into backend requirements file - Added access to compiled hardhat contract in jsonrpc service - Added database migration file so that a transaction has the ghost contract address of hardhat network - When a genlayer contract is deployed then a hardhat contract is deployed, both are linked in the CurrentState table - When a genlayer write method is executed then the new transaction gets the hardhat contract from the CurrentState table - When a genlayer transaction changes from status then a rollup transaction is created on the hardhat network - todo: remove rollup transaction table, put hardhat port in env, link genlayer account to hardhat account, check for out of gas, remove prints
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #626 +/- ##
=======================================
Coverage 18.61% 18.61%
=======================================
Files 123 123
Lines 9618 9618
Branches 299 299
=======================================
Hits 1790 1790
Misses 7744 7744
Partials 84 84 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
…ements as it gave an import error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good job. Let's try to see if we can have the same addresses for both contracts (genlayer contract and ghost contract)
- Add genlayer-consensus smart contracts to hardhat/contracts directory - Update hardhat.config.js to enable new code generator (viaIR: true) - Add @openzeppelin/contracts and @openzeppelin/contracts-upgradeable dependencies - Configure hardhat Docker container for contract compilation - Verify hardhat node functionality in genlayer-studio This commit sets up the smart contract development environment with the necessary dependencies and configurations to compile and deploy genlayer-consensus contracts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comment about amm intelligent contract example
- Added migration for ghost_contract_address column in transactions table - Fixed security issues in hardhat docker configuration - Ensured proper migration sequence (0d9538be0318 -> cb34b6b353ed) Migration changes: - Added new column ghost_contract_address (String, nullable) to transactions table - Provided proper upgrade and downgrade paths - Verified migration execution and current head state TODO: Frontend issues to fix: - Methods panel not opening after transaction acceptance - Need to investigate UI response after successful transactions
091c28f
to
02df53c
Compare
- Deleted amm_adaptive.py because is not using the new syntax I will upload the new amm_adaptive.py whenevir will be ready
- Fixed contract deployment state updates for frontend synchronization - Improved contract method interactions and state management - Ensured proper state updates after contract value changes
Quality Gate failedFailed conditions |
🎉 This PR is included in version 0.27.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Fixes #625
What
Why
Testing done
Decisions made
At the moment one hardhat account is used.
Checks
Reviewing tips
User facing release notes
The simulator contains the hardhat network development environment