Closed aaku1234 closed 2 years ago
Please report issues and seek support with ink
on their repos and element channels
And specifically for this one, why not open an issue on that repo :wink:
Hey @aaku1234, can you tell us a little bit more about the versions of the tools you're using? E.g, rustc
, cargo-contract
, substrate-contracts-node
.
Hey @aaku1234, can you tell us a little bit more about the versions of the tools you're using? E.g,
rustc
,cargo-contract
,substrate-contracts-node
.
Hello @HCastano,these are the version of my rustc - rustc 1.36.0-nightly cargo-contract - cargo-contract 0.15.0-unknown-x86_64-linux-gnu substrate-contracts-node - substrate-contracts-node 0.1.0-acbf103-x86_64-linux-gnu
Your rustc
version is quite old. For context, our CI is using cargo 1.58.0-nightly (ad50d0d26 2021-11-17)
. You can update using rustup update nightly
.
Your smart-contracts-node
is also a bit outdated. The latest commit is 9dd43c31. You can update with cargo install contracts-node --git https://github.com/paritytech/substrate-contracts-node.git --force --locked
.
Can you perform these updates and try deploying your contract again?
After updating rustc ,this is the version - rustc 1.56.0 (09c42c458 2021-10-18)
and my smart-contract-node version - substrate-contracts-node 0.1.0-9dd43c3-x86_64-linux-gnu
When I build the contract by command "cargo +nightly contract build" I got this error
I also tried adding overflow-checks = falsein
Cargo.toml` but getting the same error
ERROR: Validation of the Wasm failed. ERROR: An unexpected panic function import was found in the contract Wasm. This typically goes back to a known bug in the Rust compiler: https://github.com/rust-lang/rust/issues/78744
As a workaround try to insert overflow-checks = false
into your Cargo.toml
.
This will disable safe math operations, but unfortunately we are currently not
aware of a better workaround until the bug in the compiler is fixed.
ERROR: An unexpected import function was found in the contract Wasm: _ZN4core9panicking5panic17hb051bf2d675326efE. The only allowed import functions are those starting with one of the following prefixes: seal, memory
This is related to https://github.com/paritytech/ink/issues/364. We're working around it by disabling overflow-checks
(see this PR for example). Can you do the same and see if you can successfully deploy your contract?
@aaku1234 I'm gonna go ahead and close this issue. Feel free to ping us/re-open this if you feel like it hasn't been resolved.
system.extrinsic failed others deploying smart contract .Following this github code for ERC721 https://github.com/allanperlee/Nftoken