Closed Blockcowboy2 closed 2 days ago
When you spin up your contract parachain with pop, you are also running the relay chain. In this setup, the relay chain (Rococo) runs on port 51867, while your contracts chain runs on port 51875. To deploy your contract, use the following command:
pop up contract --constructor new --args "false" --suri //Alice --url ws://127.0.0.1:51875
Thank you. Now I have a signing error
Pop CLI : Building a contract
ā
[==] Checking clippy linting rules
Finished dev
profile [unoptimized + debuginfo] target(s) in 0.20s
[==] Building cargo project
Finished release
profile [optimized] target(s) in 0.13s
ā
ā The contract was built in RELEASE mode.
ā
ā Your contract artifacts are ready. You can find them in:
ā /Users/freeman/Polkadot/flipper/target/ink
ā
ā - flipper.contract (code + metadata)
ā - flipper.wasm (the contract's code)
ā - flipper.json (the contract's metadata)
ā
ā Pop CLI : Deploy a smart contract
ā
ā Doing a dry run to estimate the gas... ā Gas limit: Weight { ref_time: 133264469, proof_size: 16535 }
ā
Error: Extrinsic params error: The chain expects a signed extension with the name CheckMetadataHash, but we did not provide one
I am trying to replicate the issue. Are you only using a Flipper smart contract and the pop generated contracts
parachain? or you have made some modifications?
No modifications. Yes default Flipper and default contracts parachain.
No changes.
Contract creation: pop new contract flipper
I created new contract parachain and new flipper after clearing cache. Followed instructions. Same error.
Installed on different computer to eliminate toolchain, etc. as variable.
I got the same error when trying to deploy to contract created with : %pop new contract flipper
deployed with:
pop up contract --constructor new --args "false" --suri //Alice --url ws://
The contract did deploy with the default parachain using: pop up contract --constructor new --args "false" --suri //Alice
Should subxt be updated based on recent change that impacted CheckMetadataHash ?
https://github.com/paritytech/subxt/blob/master/CHANGELOG.md
I downgraded the parachain version and used cargo to build and deploy instead of pop to get around .37 subxt change.
Pop CLI : Deploy a smart contract ā ā Gas limit estimate: Weight { ref_time: 146371034, proof_size: 16689 } ā ā Contract deployed and instantiated: The Contract Address is "5FsMSSbNFhXiXS92G31EpEBiXj88ofvQV62HmyUAvkwM6xP3" ā ā š Deployment complete
Recommend use of V1.10 instead of V1.11.
Installed on different computer to eliminate toolchain, etc. as variable.
I got the same error when trying to deploy to contract created with : %pop new contract flipper
deployed with: pop up contract --constructor new --args "false" --suri //Alice --url ws://
The contract did deploy with the default parachain using: pop up contract --constructor new --args "false" --suri //Alice
If you don't specify a parachain it automatically executes thesubstrate-contracts-node
https://github.com/paritytech/substrate-contracts-node . So it seems the issue is in pop contracts template: https://github.com/r0gue-io/contracts-parachain
Thank you for all the information. I'm currently looking into it and will get back to you soon.
My pleasure. Let me know when updated and I will test again. Need to know how to create a parachain with contract and asset.
Should subxt be updated based on recent change that impacted CheckMetadataHash ?
https://github.com/paritytech/subxt/blob/master/CHANGELOG.md
Sorry for the delay. I'm working on upgrading it, but it involves an upgrade to another library we're using.
In the meantime, if you want to make it work, a workaround is to comment out this line in the parachain: https://github.com/r0gue-io/contracts-parachain/blob/794b87755c4cb5ce88320c720c90ed73a461cc9a/runtime/src/lib.rs#L112
hi @AlexD10S I got the same issue Error: Extrinsic params error: The chain expects a signed extension with the name CheckMetadataHash, but we did not provide one
This is my command :
pop up contract --constructor new --args false --suri //Alice --url wss://rpc1.paseo.popnetwork.xyz
Noted: I dont run parachain contract locally, i use the POP network RPC My pop version: 0.3.0
We just merge the fix into main
, we'll do a release soon but in the meantime you can install it from the repository and it will work:
cargo install --locked --git https://github.com/r0gue-io/pop-cli
Should subxt be updated based on recent change that impacted CheckMetadataHash ?
https://github.com/paritytech/subxt/blob/master/CHANGELOG.md
@Blockcowboy2 Thank you again for reporting this issue. Apologies for the delay in fixing it; we had to apply the changes to the third-party libraries we were using as well.
Note: Using contract template.
š Network launched successfully - ctrl-c to terminate ā āļø rococo-local ā alice: ā portal: https://polkadot.js.org/apps/?rpc=ws://127.0.0.1:**51867**#/explorer ā logs: tail -f /var/folders/cl/cptzdfls60jf6z6pcrq3dbkm0000gn/T/zombie-db27a062-3320-4b30-9301-aa682a711f9f/alice/alice.log ā bob: ā portal: https://polkadot.js.org/apps/?rpc=ws://127.0.0.1:51871#/explorer ā logs: tail -f /var/folders/cl/cptzdfls60jf6z6pcrq3dbkm0000gn/T/zombie-db27a062-3320-4b30-9301-aa682a711f9f/bob/bob.log ā āļø local_testnet: 2000 ā collator-01: ā portal: https://polkadot.js.org/apps/?rpc=ws://127.0.0.1:51875#/explorer ā logs: tail -f /var/folders/cl/cptzdfls60jf6z6pcrq3dbkm0000gn/T/zombie-db27a062-3320-4b30-9301-aa682a711f9f/collator-01/collator-01.log
flipper % pop up contract --constructor new --args "false" --suri //Alice --url ws://127.0.0.1:51867
NOTE: contract has not yet been built. ā
ā Pop CLI : Building a contract ā [==] Checking clippy linting rules Finished
dev
profile [unoptimized + debuginfo] target(s) in 0.20s [==] Building cargo project Finishedrelease
profile [optimized] target(s) in 0.13s āā The contract was built in RELEASE mode. ā
ā Your contract artifacts are ready. You can find them in: ā /Users/freeman/Polkadot/flipper/target/ink ā
ā - flipper.contract (code + metadata) ā - flipper.wasm (the contract's code) ā - flipper.json (the contract's metadata) ā
ā Pop CLI : Deploy a smart contract ā Warning: This chain does not yet support checking for compatibility of your contract types (https://use.ink/faq#type-comparison). ā² Anyhow error: Rpc error: RPC error: ErrorObject { code: ServerError(4003), message: "Client error: Execution failed: Other: Exported method ContractsApi_instantiate is not found", data: None } ā ā Deployment failed.