Missing `candid:service`

I install ic_eth as follows:

dfx canister create ic_eth
dfx canister install -m install --wasm=out/ic_eth.wasm ic_eth

out/ic_eth.wasm is a copy of compiled (by Rust) ic_eth. The file out/ic_eth.did exists and is a Candid file src/ic_eth/ic_eth.did.

From dfx.json:

    "ic_eth": {
      "type": "rust",
      "candid": "src/ic_eth/ic_eth.did",
      "package": "ic_eth"
    },

Why does the following not work?

dfx canister metadata ic_eth candid:service

I missing something about how to install Candid for Rust’s .wasm.

"metadata": [
        {
          "name": "candid:service"
        }
      ]

try adding this to the ic_eth’s config.

1 Like

No, I want to do it not through standard dfx.json, bu through out/ic_eth.wasm located in an other location than dfx.json points. I want to do it for an arbitrary .wasm file, not .wasm file specified by dfx.json.

you need to use ic-wasm

here is an example:

ic-wasm wasm_files/escrow.wasm -o wasm_files/escrow.wasm metadata candid:service -f src/escrow/escrow.did -v public
2 Likes