`dfx` fails to deploy `.did` files for custom canisters
Open
Nobody has claimed this yet.
needs-triage
- Dominant language
- Rust
- Stars
- 204
- Forks
- 98
- PR merge metrics
- No merged PRs in 30d
Description
I tried the following:
- Create a
dfx.jsonfile with
"nns-ledger": {
"build": "",
"candid": "candid/nns-ledger.did",
"remote": {
"id": {
"ic": "ryjl3-tyaaa-aaaaa-aaaba-cai",
"local": "ryjl3-tyaaa-aaaaa-aaaba-cai"
}
},
"type": "custom",
"wasm": ""
},
- Deploy it with
dfx deploy nns-ledger.
I expected to see this happen: ls .dfx/local/lsp/ryjl3-tyaaa-aaaaa-aaaba-cai.did to show the file that MS Code should pass syntax check of import ICPLedger "canister:nns-ledger";.
Instead, this happened: The file is missing and MS Code complaints.
Meta
dfx --version:
dfx 0.24.3+rev701.cc3c1c92
Further log output
Found keyring identity suffix - PEM file is stored in keyring.
Deploying:
All canisters have already been created.
Deployed canisters.
URLs:
Frontend canister via browser:
bootstrapper_frontend:
- http://ufxgi-4p777-77774-qaadq-cai.localhost:8080/ (Recommended)
- http://127.0.0.1:8080/?canisterId=ufxgi-4p777-77774-qaadq-cai (Legacy)
example_frontend:
- http://vu5yx-eh777-77774-qaaga-cai.localhost:8080/ (Recommended)
- http://127.0.0.1:8080/?canisterId=vu5yx-eh777-77774-qaaga-cai (Legacy)
internet_identity:
- http://ucwa4-rx777-77774-qaada-cai.localhost:8080/ (Recommended)
- http://127.0.0.1:8080/?canisterId=ucwa4-rx777-77774-qaada-cai (Legacy)
package_manager_frontend:
- http://vg3po-ix777-77774-qaafa-cai.localhost:8080/ (Recommended)
- http://127.0.0.1:8080/?canisterId=vg3po-ix777-77774-qaafa-cai (Legacy)
Backend canister via Candid interface:
battery: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=vpyes-67777-77774-qaaeq-cai
bookmark: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=umunu-kh777-77774-qaaca-cai
bootstrapper: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=ulvla-h7777-77774-qaacq-cai
bootstrapper_data: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=u6s2n-gx777-77774-qaaba-cai
cycles_ledger: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=um5iw-rqaaa-aaaaq-qaaba-cai
example_backend: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=vb2j2-fp777-77774-qaafq-cai
internet_identity: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=ucwa4-rx777-77774-qaada-cai
main_indirect: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=vt46d-j7777-77774-qaagq-cai
package_manager: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=vizcg-th777-77774-qaaea-cai
repository: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=uzt4z-lp777-77774-qaabq-cai
simple_indirect: http://127.0.0.1:8080/?canisterId=uqqxf-5h777-77774-qaaaa-cai&id=v27v7-7x777-77774-qaaha-cai
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with the shown dfx.json entry, candid/nns-ledger.did, and dfx deploy nns-ledger. Check whether .dfx/local/lsp/ryjl3-tyaaa-aaaaa-aaaba-cai.did is created; done means the file exists so MS Code can syntax-check import ICPLedger "canister:nns-ledger".
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- blockchain, cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100