فهرست منبع

Test ethers 6.13.6-beta.1, use solc 0.8.27 and `prague` EVM version (#5663)

Ernesto García 5 ماه پیش
والد
کامیت
08566bfe0d
7فایلهای تغییر یافته به همراه13 افزوده شده و 10 حذف شده
  1. 2 1
      .github/actions/setup/action.yml
  2. 2 0
      .github/workflows/checks.yml
  3. 1 1
      foundry.toml
  4. 2 2
      hardhat.config.js
  5. 4 4
      package-lock.json
  6. 1 1
      package.json
  7. 1 1
      test/metatx/ERC2771Forwarder.test.js

+ 2 - 1
.github/actions/setup/action.yml

@@ -13,7 +13,8 @@ runs:
         path: '**/node_modules'
         key: npm-v3-${{ hashFiles('**/package-lock.json') }}
     - name: Install dependencies
-      run: npm ci
+      ## TODO: Remove when EIP-7702 authorizations are enabled in latest non-beta ethers version
+      run: npm ci --legacy-peer-deps
       shell: bash
       if: steps.cache.outputs.cache-hit != 'true'
     - name: Install Foundry

+ 2 - 0
.github/workflows/checks.yml

@@ -118,6 +118,8 @@ jobs:
       - uses: actions/checkout@v4
       - name: Set up environment
         uses: ./.github/actions/setup
+      ## TODO: Remove when EIP-7702 authorizations are enabled in latest non-beta ethers version
+      - run: rm package-lock.json package.json # Dependencies already installed
       - uses: crytic/slither-action@v0.4.1
 
   codespell:

+ 1 - 1
foundry.toml

@@ -1,5 +1,5 @@
 [profile.default]
-solc_version = '0.8.24'
+solc_version = '0.8.27'
 evm_version = 'prague'
 optimizer = true
 optimizer-runs = 200

+ 2 - 2
hardhat.config.js

@@ -18,7 +18,7 @@ const { argv } = require('yargs/yargs')()
     compiler: {
       alias: 'compileVersion',
       type: 'string',
-      default: '0.8.24',
+      default: '0.8.27',
     },
     src: {
       alias: 'source',
@@ -38,7 +38,7 @@ const { argv } = require('yargs/yargs')()
     evm: {
       alias: 'evmVersion',
       type: 'string',
-      default: 'cancun',
+      default: 'prague',
     },
     // Extra modules
     coverage: {

+ 4 - 4
package-lock.json

@@ -24,7 +24,7 @@
         "chai": "^4.2.0",
         "eslint": "^9.0.0",
         "eslint-config-prettier": "^10.0.0",
-        "ethers": "^6.13.4",
+        "ethers": "6.13.6-beta.1",
         "glob": "^11.0.0",
         "globals": "^16.0.0",
         "graphlib": "^2.1.8",
@@ -4483,9 +4483,9 @@
       }
     },
     "node_modules/ethers": {
-      "version": "6.13.7",
-      "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.13.7.tgz",
-      "integrity": "sha512-qbaJ0uIrjh+huP1Lad2f2QtzW5dcqSVjIzVH6yWB4dKoMuj2WqYz5aMeeQTCNpAKgTJBM5J9vcc2cYJ23UAimQ==",
+      "version": "6.13.6-beta.1",
+      "resolved": "https://registry.npmjs.org/ethers/-/ethers-6.13.6-beta.1.tgz",
+      "integrity": "sha512-sJZklf+m7QrlzYnOFbR0qHPqgYHeevbY98VIhzvnSdzhJVN/nNV/skKc/4wjyxbWRhK9t7r6ENcwUwLPjfxTLw==",
       "dev": true,
       "funding": [
         {

+ 1 - 1
package.json

@@ -66,7 +66,7 @@
     "chai": "^4.2.0",
     "eslint": "^9.0.0",
     "eslint-config-prettier": "^10.0.0",
-    "ethers": "^6.13.4",
+    "ethers": "6.13.6-beta.1",
     "glob": "^11.0.0",
     "globals": "^16.0.0",
     "graphlib": "^2.1.8",

+ 1 - 1
test/metatx/ERC2771Forwarder.test.js

@@ -174,7 +174,7 @@ describe('ERC2771Forwarder', function () {
       // Because the relayer call consumes gas until the `CALL` opcode, the gas left after failing
       // the subcall won't enough to finish the top level call (after testing), so we add a
       // moderated buffer.
-      const gasLimit = estimate + 2_000n;
+      const gasLimit = estimate + 10_000n;
 
       // The subcall out of gas should be caught by the contract and then bubbled up consuming
       // the available gas with an `invalid` opcode.