Uniswap / permit2

🔑🔑🔑 next generation token approvals mechanism
MIT License
759 stars 187 forks source link

deploy onto new network #249

Open thelostone-mc opened 7 months ago

thelostone-mc commented 7 months ago

When i run

forge script --broadcast --rpc-url https://evm-rpc-arctic-1.sei-apis.com/ --private-key <PRIVATE_KEY> --verify script/DeployPermit2.s.sol:DeployPermit2

It errors out with

[⠊] Compiling...
[⠒] Compiling 1 files with 0.8.17Compiler run successful!
[⠢] Compiling 1 files with 0.8.17
[⠆] Solc 0.8.17 finished in 7.42s
Traces:
  [2120457] → new DeployPermit2@0x5b73C5498c1E3b4dbA84de0F1833c4a029d90519
    └─ ← 10421 bytes of code

  [147] DeployPermit2::setUp()
    └─ ← ()

  [9079256848778899849] DeployPermit2::run()
    ├─ [0] VM::startBroadcast()
    │   └─ ← ()
    ├─ [0] → new <unknown>@0x8a8dDbE4c64CF1857360DC25883a581933D5ca4b
    │   └─ ← 9345 bytes of code
    └─ ← EvmError: Revert

I've also tried it with a sepolia RPC but end up with the same error. Would love some guidance on how to get past this

hensha256 commented 7 months ago

Have you edited the deploy script from main at all? The address its trying to deploy to isnt the canonical deploy address that I would expect.

saurabh commented 3 months ago

I get the same error. I haven't made any modifications at all. Simply forge install and then forge script --broadcast etc. like below:

$ forge script --broadcast --chain-id 325000 --rpc-url https://rpc-campnetwork.xyz --private-key <PK> --verify script/DeployPermit2.s.sol:DeployPermit2
[⠢] Compiling...
No files changed, compilation skipped
Traces:
  [2117050] → new DeployPermit2@0x5b73C5498c1E3b4dbA84de0F1833c4a029d90519
    └─ ← 10353 bytes of code

  [144] DeployPermit2::setUp()
    └─ ← ()

  [9079256848778920913] DeployPermit2::run() 
    ├─ [0] VM::startBroadcast()
    │   └─ ← ()
    ├─ [0] → new Permit2@0x000000000022D473030F116dDEE9F6B43aC78BA3
    │   └─ ← 9152 bytes of code
    └─ ← "EvmError: Revert"

Error:
Script failed.
supradexodus commented 1 week ago

Permit2 should be already in that chain.