SDK 0.8.4
DFX
feat: "rust" canister type
You can now declare "rust" canisters in dfx.json.
{
"canisters": {
"canister_name": {
"type": "rust",
"package": "crate_name",
"candid": "path/to/canister_name.did"
}
}
}
Don't forget to place a Cargo.toml
in your project root.
Then dfx will build the rust canister with your rust toolchain.
Please also make sure that you have added the WebAssembly compilation target.
rustup target add wasm32-unknown-unknown
You can also create new dfx project with a default rust canister.
dfx new --type=rust <project-name>
chore: updating dfx new template
Updates dependencies to latest for Webpack, and updates config. Additionally simplifies environment variables for canister ID's in config.
Additionally adds some polish to the starter template, including a favicon and using more semantic html in the example app
feat: environment variable overrides for executable pathnames
You can now override the location of any executable normally called from the cache by specifying
an environment variable. For example, DFX_ICX_PROXY_PATH will specify the path for icx-proxy
.
feat: dfx deploy --mode=reinstall
dfx deploy
can now reinstall a single canister, controlled by a new --mode=reinstall
parameter.
This is destructive (it resets the state of the canister), so it requires a confirmation
and can only be performed on a single canister at a time.
dfx canister install --mode=reinstall <canister>
also requires the same confirmation,
and no longer works with --all
.
Replica
The included replica now supports canister_heartbeat. This only works with rust canisters for the time being,
and does not work with the emulator (dfx start --emulator
).