Skip to content

chore: migrate rust/candid_type_generation to icp-cli#1408

Draft
marc0olo wants to merge 1 commit into
masterfrom
chore/migrate-rust-candid-type-generation-to-icp-cli
Draft

chore: migrate rust/candid_type_generation to icp-cli#1408
marc0olo wants to merge 1 commit into
masterfrom
chore/migrate-rust-candid-type-generation-to-icp-cli

Conversation

@marc0olo

Copy link
Copy Markdown
Member

Summary

  • Replaces dfx.json with icp.yaml using the @dfinity/rust@v3.3.0 recipe
  • Moves src/backend/, adds workspace Cargo.toml, renames Cargo package to backend
  • Updates build.rs to resolve candid/nns_governance.did relative to the new backend/ location
  • Updates scripts/fetch_candid.sh to use icp canister metadata instead of dfx canister --network ic metadata
  • Adds Makefile with a test target that calls list_neurons_pretty
  • Adds rust-toolchain.toml with wasm32-unknown-unknown target
  • Adds CI workflow candid_type_generation.yml using ghcr.io/dfinity/icp-dev-env-rust:1.0.0
  • Deletes legacy rust-candid-type-generation-example.yml workflow
  • Adds example-level .gitignore to un-ignore backend/src/declarations/ (committed ic-cdk-bindgen output)

Test plan

  • CI job rust-candid_type_generation passes on this PR
  • icp network start -d && icp deploy && make test succeeds locally
  • make test asserts list_neurons_pretty returns a text response (success or expected error from local→mainnet inter-canister call)

🤖 Generated with Claude Code

- Replace dfx.json with icp.yaml using @dfinity/rust@v3.3.0 recipe
- Move src/ to backend/, add workspace Cargo.toml, rename package to backend
- Update build.rs to resolve candid/ path relative to new backend/ location
- Update scripts/fetch_candid.sh to use icp canister metadata instead of dfx
- Add Makefile with test target for list_neurons_pretty
- Add rust-toolchain.toml with wasm32-unknown-unknown target
- Add CI workflow candid_type_generation.yml with icp-dev-env-rust:1.0.0
- Delete legacy rust-candid-type-generation-example.yml workflow
- Regenerate Cargo.lock for new workspace structure

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant