Currently I'm in the works of running this contract and am having an issue instantiating the contract.
I ran the following commands:
make
and next optimize the contract using:
docker run --rm -v "$(pwd)":/contract \ --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ enigmampc/secret-contract-optimizer
Having done this, I start the local testnet:
docker run -it --rm \ -p 26657:26657 -p 26656:26656 -p 1337:1337 \ -v $(pwd):/root/code \ --name localsecret ghcr.io/scrtlabs/localsecret
Then, inside the docker (docker exec -it localsecret /bin/bash and run cd code after), I store the contract:
secretd tx compute store contract.wasm.gz --from a --gas 1000000 -y --keyring-backend test
Running secretd query compute list-code, no output is obtained. So maybe something goes wrong here.
Nonetheless, trying to instantiate the contract, I run the following command:
secretd tx compute instantiate 1 '{"name": "test", "symbol":"TTT", "decimals":10, "prng_seed":"VGVzdA=="}' --label test --from a
This returns the following error:
Error: unexpected end of JSON input
Hi everyone,
Currently I'm in the works of running this contract and am having an issue instantiating the contract.
I ran the following commands:
make
and next optimize the contract using:
docker run --rm -v "$(pwd)":/contract \ --mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \ --mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \ enigmampc/secret-contract-optimizer
Having done this, I start the local testnet:
docker run -it --rm \ -p 26657:26657 -p 26656:26656 -p 1337:1337 \ -v $(pwd):/root/code \ --name localsecret ghcr.io/scrtlabs/localsecret
Then, inside the docker (
docker exec -it localsecret /bin/bash
and runcd code
after), I store the contract:secretd tx compute store contract.wasm.gz --from a --gas 1000000 -y --keyring-backend test
Running
secretd query compute list-code
, no output is obtained. So maybe something goes wrong here.Nonetheless, trying to instantiate the contract, I run the following command:
secretd tx compute instantiate 1 '{"name": "test", "symbol":"TTT", "decimals":10, "prng_seed":"VGVzdA=="}' --label test --from a
This returns the following error:
Error: unexpected end of JSON input
Do you know how to resolve this error?