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

Syncing deployment DisputeGameFactory: contract DisputeGameFactory.0.8.15. script failed: Error parsing version #10114

Closed
wy51084915 opened this issue Apr 11, 2024 · 7 comments

Comments

@wy51084915
Copy link

Bug Description
i'm trying to build my first L2 chain in the guide of https://docs.optimism.io/builders/chain-operators/tutorials/create-l2-rollup,when i finished deploying the L1 contract with the command :
forge script scripts/Deploy.s.sol:Deploy --private-key $GS_ADMIN_PRIVATE_KEY --broadcast --rpc-url $L1_RPC_URL --slow it worked well with the output:

`ONCHAIN EXECUTION COMPLETE & SUCCESSFUL.
Total Paid: 0.103279203582127804 ETH (34057669 gas * avg 3.031470256 gwei)

Transactions saved to: /Users/user/optimism/packages/contracts-bedrock/broadcast/Deploy.s.sol/11155111/run-latest.json

Sensitive values saved to: /Users/user/optimism/packages/contracts-bedrock/cache/Deploy.s.sol/11155111/run-latest.json

then i ran
forge script scripts/Deploy.s.sol:Deploy --sig 'sync()' --rpc-url $L1_RPC_URL
to Generate contract artifacts and an error occured :

Logs:
`": []\n },\n "additionalContracts": [],\n "isFixedGasLimit": false\n}'"])
│ └─ ← [Return] 0x6e756c6c
├─ [0] VM::ffi(["bash", "-c", "echo DisputeGameFactory.0.8.15 | sed -E 's/[.][0-9]+\.[0-9]+\.[0-9]+//g'"])
│ └─ ← [Return] 0x4469737075746547616d65466163746f7279
├─ [0] VM::getCode("DisputeGameFactory.sol:DisputeGameFactory.0.8.15") [staticcall]
│ └─ ← [Revert] Error parsing version
└─ ← [Revert] Error parsing version

== Logs ==
Connected to network with chainid 11155111
Storing temp deployment data in /Users/user/optimism/packages/contracts-bedrock/deployments/getting-started/.deploy
DeployConfig: reading file /Users/user/optimism/packages/contracts-bedrock/deploy-config/getting-started.json
Deploying from Deploy
Deployment context: getting-started
Syncing 27 deployments
Using deployment artifact /Users/user/optimism/packages/contracts-bedrock/broadcast/Deploy.s.sol/11155111/run-latest.json
Syncing deployment AddressManager: contract AddressManager
Syncing deployment DisputeGameFactory: contract DisputeGameFactory.0.8.15
Error:
script failed: Error parsing version`

Environment Information:

  • Operating System: MacOs M1
  • Package Version
    git 2.44.0
    go 1.22.1
    node 21.7.1
    pnpm 8.15.6
    foundry 0.2.0
    make 3.81
    jq 1.7.1
    direnv 2.34.0
    solc. 0.8.15

anybody can help solve this? Thx!

@420516460
Copy link

420516460 commented Apr 11, 2024

can you show more specify foundry version? in path xxx/optimism to run command:
forge --version

will get like this:
forge 0.2.0 (4603195 2024-04-10T00:17:25.834634784Z)

and what is your optimism branch version number? is it tutorials/chain?

@Ajmali124
Copy link

i have got the same problem

The forge version is
forge 0.2.0 (14daacf 2024-04-09T00:17:09.802796000Z)

and yes it is the tutorials/chain

@420516460
Copy link

420516460 commented Apr 12, 2024

i have got the same problem

The forge version is forge 0.2.0 (14daacf 2024-04-09T00:17:09.802796000Z)

and yes it is the tutorials/chain

your version is right, have you checked if contracts have been deployed to L1?

in the latest version of optimism(v1.7.2+), we don‘t rely on the artifacts, so it's fine in latest version no need to run this command.

i m not sure this changes if have been sync to the branch tutorials/chain, i will retry what you did

@wy51084915
Copy link
Author

wy51084915 commented Apr 12, 2024

can you show more specify foundry version? in path xxx/optimism to run command: forge --version

will get like this: forge 0.2.0 (4603195 2024-04-10T00:17:25.834634784Z)

and what is your optimism branch version number? is it tutorials/chain?

yes, i got forge version == 0.2.0 and i'm under the branch tutorials/chain
i finally choose to skip the step and just copy the artifacts from its peer folder(sepolia), which may be generated by optimism earlier, and that worked.

@wy51084915
Copy link
Author

i have got the same problem
The forge version is forge 0.2.0 (14daacf 2024-04-09T00:17:09.802796000Z)
and yes it is the tutorials/chain

your version is right, have you checked if contracts have been deployed to L1?

in the latest version of optimism(v1.7.2+), we don‘t rely on the artifacts, so it's fine in latest version no need to run this command.

i m not sure this changes if have been sync to the branch tutorials/chain, i will retry what you did

yes , the deployment is successful , but under the branch "tutorials/chain", to generate the L2's genesis files need the artifacts.So i have to get it.

@420516460
Copy link

i have got the same problem
The forge version is forge 0.2.0 (14daacf 2024-04-09T00:17:09.802796000Z)
and yes it is the tutorials/chain

your version is right, have you checked if contracts have been deployed to L1?
in the latest version of optimism(v1.7.2+), we don‘t rely on the artifacts, so it's fine in latest version no need to run this command.
i m not sure this changes if have been sync to the branch tutorials/chain, i will retry what you did

yes , the deployment is successful , but under the branch "tutorials/chain", to generate the L2's genesis files need the artifacts.So i have to get it.

wooo nice! yep i have met some similar issues, the artifacts are practically no longer needed at this time, but the documentation hasn't been updated yet.

i m guessing you need to change this when you run the go run cmd/main.go genesis l2 \ step:

...
 --deployment-dir . /packages/contracts-bedrock/deployments/getting-started/ \
...

this flag need artifacts.

@wy51084915
Copy link
Author

i have got the same problem
The forge version is forge 0.2.0 (14daacf 2024-04-09T00:17:09.802796000Z)
and yes it is the tutorials/chain

your version is right, have you checked if contracts have been deployed to L1?
in the latest version of optimism(v1.7.2+), we don‘t rely on the artifacts, so it's fine in latest version no need to run this command.
i m not sure this changes if have been sync to the branch tutorials/chain, i will retry what you did

yes , the deployment is successful , but under the branch "tutorials/chain", to generate the L2's genesis files need the artifacts.So i have to get it.

wooo nice! yep i have met some similar issues, the artifacts are practically no longer needed at this time, but the documentation hasn't been updated yet.

i m guessing you need to change this when you run the go run cmd/main.go genesis l2 \ step:

...
 --deployment-dir . /packages/contracts-bedrock/deployments/getting-started/ \
...

this flag need artifacts.

yes, just change the --deployment-dir . /packages/contracts-bedrock/deployments/getting-started/ to --deployment-dir . /packages/contracts-bedrock/deployments/sepolia/ , and everything will be fine

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

No branches or pull requests

3 participants