From 7837dedb0a7bca795634c1a213e599b693c8518d Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Tue, 19 Jul 2022 19:08:44 +0200 Subject: [PATCH 01/11] chore: Release 0.11.1-beta.0 (#2360) Signed-off-by: Marcin Nowak-Liebiediew --- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f79458b629..5fa2de6aa6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.0" +version = "0.11.1-beta.0" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index ca242a219d..e5a94282ab 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -57,6 +57,7 @@ "0.9.3", "0.10.0", "0.10.1", - "0.11.0" + "0.11.0", + "0.11.1-beta.0" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 7370a7ba3e..5d213fde11 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.0" +version = "0.11.1-beta.0" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From ce9a01477edbbd2602b449f03d21b8dcad6d1ae7 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Thu, 21 Jul 2022 18:04:50 +0200 Subject: [PATCH 02/11] chore: Release 0.11.1-beta.1 (#2366) * chore: Release 0.11.1-beta.1 Signed-off-by: Marcin Nowak-Liebiediew --- .github/workflows/e2e.yml | 6 +++--- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 843c1c5914..2cb55a9373 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -11,7 +11,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-10.15, macos-11, ubuntu-20.04] + os: [macos-11, ubuntu-20.04] rust: ["1.60.0"] binary_path: ["target/release"] steps: @@ -63,11 +63,11 @@ jobs: fail-fast: false matrix: backend: ["ic-ref", "replica"] - # macos-latest is currently macos-10.15, ubuntu-latest is currently ubuntu-20.04 + # macos-latest is currently macos-11, ubuntu-latest is currently ubuntu-20.04 # ubuntu-18.04 not supported due to: # /home/runner/.cache/dfinity/versions/0.8.3-34-g36e39809/ic-starter: # /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found - os: [macos-10.15, macos-11, ubuntu-20.04] + os: [macos-11, ubuntu-20.04] rust: ["1.60.0"] steps: - uses: actions/checkout@v1 diff --git a/Cargo.lock b/Cargo.lock index 5fa2de6aa6..be93b585ed 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.0" +version = "0.11.1-beta.1" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index e5a94282ab..7747580462 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -58,6 +58,7 @@ "0.10.0", "0.10.1", "0.11.0", - "0.11.1-beta.0" + "0.11.1-beta.0", + "0.11.1-beta.1" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 5d213fde11..646932ea6d 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.0" +version = "0.11.1-beta.1" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From 5759f2b0f9ba1409f0d92ced30f42beafe5fa1de Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Thu, 21 Jul 2022 18:26:34 +0200 Subject: [PATCH 03/11] Revert "chore: Release 0.11.1-beta.1 (#2366)" (#2367) This reverts commit ce9a01477edbbd2602b449f03d21b8dcad6d1ae7. --- .github/workflows/e2e.yml | 6 +++--- Cargo.lock | 2 +- public/manifest.json | 3 +-- src/dfx/Cargo.toml | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 2cb55a9373..843c1c5914 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -11,7 +11,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-11, ubuntu-20.04] + os: [macos-10.15, macos-11, ubuntu-20.04] rust: ["1.60.0"] binary_path: ["target/release"] steps: @@ -63,11 +63,11 @@ jobs: fail-fast: false matrix: backend: ["ic-ref", "replica"] - # macos-latest is currently macos-11, ubuntu-latest is currently ubuntu-20.04 + # macos-latest is currently macos-10.15, ubuntu-latest is currently ubuntu-20.04 # ubuntu-18.04 not supported due to: # /home/runner/.cache/dfinity/versions/0.8.3-34-g36e39809/ic-starter: # /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found - os: [macos-11, ubuntu-20.04] + os: [macos-10.15, macos-11, ubuntu-20.04] rust: ["1.60.0"] steps: - uses: actions/checkout@v1 diff --git a/Cargo.lock b/Cargo.lock index be93b585ed..5fa2de6aa6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.1" +version = "0.11.1-beta.0" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index 7747580462..e5a94282ab 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -58,7 +58,6 @@ "0.10.0", "0.10.1", "0.11.0", - "0.11.1-beta.0", - "0.11.1-beta.1" + "0.11.1-beta.0" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 646932ea6d..5d213fde11 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.1" +version = "0.11.1-beta.0" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From fabbb067b841664b43c41d7700f0bf78029fa535 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Thu, 21 Jul 2022 20:52:37 +0200 Subject: [PATCH 04/11] chore: Release 0.11.1-beta.1 (#2368) Signed-off-by: Marcin Nowak-Liebiediew --- .github/workflows/e2e.yml | 6 +++--- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 843c1c5914..2cb55a9373 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -11,7 +11,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macos-10.15, macos-11, ubuntu-20.04] + os: [macos-11, ubuntu-20.04] rust: ["1.60.0"] binary_path: ["target/release"] steps: @@ -63,11 +63,11 @@ jobs: fail-fast: false matrix: backend: ["ic-ref", "replica"] - # macos-latest is currently macos-10.15, ubuntu-latest is currently ubuntu-20.04 + # macos-latest is currently macos-11, ubuntu-latest is currently ubuntu-20.04 # ubuntu-18.04 not supported due to: # /home/runner/.cache/dfinity/versions/0.8.3-34-g36e39809/ic-starter: # /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found - os: [macos-10.15, macos-11, ubuntu-20.04] + os: [macos-11, ubuntu-20.04] rust: ["1.60.0"] steps: - uses: actions/checkout@v1 diff --git a/Cargo.lock b/Cargo.lock index 5fa2de6aa6..be93b585ed 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.0" +version = "0.11.1-beta.1" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index e5a94282ab..7747580462 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -58,6 +58,7 @@ "0.10.0", "0.10.1", "0.11.0", - "0.11.1-beta.0" + "0.11.1-beta.0", + "0.11.1-beta.1" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 5d213fde11..646932ea6d 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.0" +version = "0.11.1-beta.1" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From b8dc2eb29707938755adbbf27d4316fdc4db3290 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Fri, 22 Jul 2022 18:57:14 +0200 Subject: [PATCH 05/11] chore: Release 0.11.1-beta.2 (#2370) Signed-off-by: Marcin Nowak-Liebiediew --- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 955e31b885..a20529c459 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.1" +version = "0.11.1-beta.2" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index 7747580462..ba7e04d997 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -59,6 +59,7 @@ "0.10.1", "0.11.0", "0.11.1-beta.0", - "0.11.1-beta.1" + "0.11.1-beta.1", + "0.11.1-beta.2" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 373a91d68c..adc18c0d1e 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.1" +version = "0.11.1-beta.2" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From 40b9e8b6bc577956ae23b4f3fbe1e39473f51f2b Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Thu, 28 Jul 2022 10:39:23 +0200 Subject: [PATCH 06/11] chore: Release 0.11.1-beta.3 (#2383) --- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a20529c459..414647e749 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.2" +version = "0.11.1-beta.3" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index ba7e04d997..2deb40de1a 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -60,6 +60,7 @@ "0.11.0", "0.11.1-beta.0", "0.11.1-beta.1", - "0.11.1-beta.2" + "0.11.1-beta.2", + "0.11.1-beta.3" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index adc18c0d1e..6e8c9c55ad 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.2" +version = "0.11.1-beta.3" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From f13ed90273e342ec4d75b166c812b469943ab71b Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Wed, 3 Aug 2022 15:48:16 +0200 Subject: [PATCH 07/11] chore: Update the manifest latest to 0.11.1 --- public/manifest.json | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/public/manifest.json b/public/manifest.json index 2deb40de1a..d04451f5de 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -1,6 +1,6 @@ { "tags": { - "latest": "0.11.0" + "latest": "0.11.1" }, "versions": [ "0.5.0", @@ -58,9 +58,6 @@ "0.10.0", "0.10.1", "0.11.0", - "0.11.1-beta.0", - "0.11.1-beta.1", - "0.11.1-beta.2", - "0.11.1-beta.3" + "0.11.1" ] } From 97b6b423e90a965c410c90f67d40e199a5fe3104 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Wed, 3 Aug 2022 15:57:14 +0200 Subject: [PATCH 08/11] update cargo files --- Cargo.lock | 2 +- src/dfx/Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 414647e749..bdea261367 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.3" +version = "0.11.1" dependencies = [ "actix", "actix-cors", diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 6e8c9c55ad..afec421943 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.3" +version = "0.11.1" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs" From b8016a896f8ab8aed0ae70bc35875e796a9d1b74 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Wed, 3 Aug 2022 16:09:28 +0200 Subject: [PATCH 09/11] changelog --- CHANGELOG.adoc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index 4cf1def259..054093fc20 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -5,6 +5,12 @@ == DFX +== Dependencies + += 0.11.1 + +== DFX + === fix: dfx now only adds candid:service metadata to custom canisters that have at least one build step This way, if a canister uses a premade canister wasm, dfx will use it as-is. From 34933cdda9cc73bdbfcb59349afa211560173f89 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Wed, 3 Aug 2022 18:04:32 +0200 Subject: [PATCH 10/11] Merge branch 'master' into mnl/update-0.11.1-latest --- CHANGELOG.adoc => CHANGELOG.md | 910 ++++++++++++++++----------------- 1 file changed, 446 insertions(+), 464 deletions(-) rename CHANGELOG.adoc => CHANGELOG.md (68%) diff --git a/CHANGELOG.adoc b/CHANGELOG.md similarity index 68% rename from CHANGELOG.adoc rename to CHANGELOG.md index 21cbd0605e..54ae21b770 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.md @@ -1,24 +1,23 @@ -= dfx changelog -:doctype: book +# dfx changelog -= UNRELEASED +# UNRELEASED -== DFX +## DFX -=== feat!: changed update-settings syntax +### feat!: changed update-settings syntax -When using `+dfx canister update-settings+`, it is easy to mistake `+--controller+` for `+--add-controller+`. For this reason `+--controller+` has been renamed to `+--set-controller+`. +When using `dfx canister update-settings`, it is easy to mistake `--controller` for `--add-controller`. For this reason `--controller` has been renamed to `--set-controller`. -=== feat!: removed the internal webserver +### feat!: removed the internal webserver This is a breaking change. The only thing this was still serving was the /_/candid endpoint. If you need to retrieve the candid interface for a local canister, you can use `dfx canister metadata candid:service`. -=== fix: dfx wallet upgrade: improved error messages: +### fix: dfx wallet upgrade: improved error messages: - if there is no wallet to upgrade - if trying to upgrade a local wallet from outside of a project directory -=== fix: dfx deploy and dfx canister install write .old.did files under .dfx/ +### fix: dfx deploy and dfx canister install write .old.did files under .dfx/ When dfx deploy and dfx canister install upgrade a canister, they ensure that the new candid interface is compatible with the previous candid interface. They write @@ -26,36 +25,33 @@ a file with extension .old.did that contains the previous interface. In some circumstances these files could be written in the project directory. dfx now always writes them under the .dfx/ directory. -=== feat: enable canister sandboxing +### feat: enable canister sandboxing Canister sandboxing is enabled to be consistent with the mainnet. -== Dependencies +# 0.11.1 -= 0.11.1 +## DFX -== DFX - -=== fix: dfx now only adds candid:service metadata to custom canisters that have at least one build step +### fix: dfx now only adds candid:service metadata to custom canisters that have at least one build step This way, if a canister uses a premade canister wasm, dfx will use it as-is. -=== fix: "canister alias not defined" in the Motoko language server +### fix: "canister alias not defined" in the Motoko language server -It is now possible to develop multiple-canister projects using the https://marketplace.visualstudio.com/items?itemName=dfinity-foundation.vscode-motoko[Motoko VSCode extension]. +It is now possible to develop multiple-canister projects using the [Motoko VSCode extension](https://marketplace.visualstudio.com/items?itemName=dfinity-foundation.vscode-motoko). -=== fix: improve browser compatibility for the JavaScript language binding +### fix: improve browser compatibility for the JavaScript language binding Patches a JavaScript language binding compatibility issue encountered in web browsers which do not support the (?.) operator. -=== feat: print dfx.json schema +### feat: print dfx.json schema dfx is now capable of displaying the schema for `dfx.json`. You can see the schema by running `dfx schema` or write the schema to a file with `dfx schema --outfile path/to/file/schema.json`. -=== feat: support for configuring assets in assets canister -- The `+.ic-assets.json+` file should be placed inside directory with assets, or its subdirectories. Multiple config files can be used (nested in subdirectories). Example of `.ic-assets.json` file format: -[source, json] ----- +### feat: support for configuring assets in assets canister +- The `.ic-assets.json` file should be placed inside directory with assets, or its subdirectories. Multiple config files can be used (nested in subdirectories). Example of `.ic-assets.json` file format: +``` json [ { "match": ".*", @@ -76,68 +72,65 @@ dfx is now capable of displaying the schema for `dfx.json`. You can see the sche "ignore": true } ] ----- -- Configuring assets works only during asset creation - any changes to `+.ic-assets.json+` files won't have any effect effect for assets that have already been created. We are working on follow up implementation with improvements to handle updating these properties. +``` +- Configuring assets works only during asset creation - any changes to `.ic-assets.json` files won't have any effect effect for assets that have already been created. We are working on follow up implementation with improvements to handle updating these properties. - `headers` from multiple applicable rules are being stacked/concatenated, unless `null` is specified, which resets/empties the headers. - Both `"headers": {}` and absence of `headers` field don't have any effect on end result. -- Valid JSON format is required, i.e. the array of maps, `+match+` field is required. Only the following fields are accepted: `+cache+`, `+ignore+`, `+headers+`, `+match+`. The glob pattern has to be valid. +- Valid JSON format is required, i.e. the array of maps, `match` field is required. Only the following fields are accepted: `cache`, `ignore`, `headers`, `match`. The glob pattern has to be valid. - The way matching rules work: -+ -. The most deeply nested config file takes precedence over the one in parent dir. In other words, properties from a rule matching a file in a subdirectory override properties from a rule matching a file in a parent directory -. Order of rules within file matters - last rule in config file takes precedence over the first one -+ -- The way `+ignore+` field works: -+ -. By default, files that begin with a `.` are ignored, while all other files are included. -. The `.ignore` field overrides this, if present. -. If a directory is ignored, file and directories within it cannot be un-ignored. -. A file can be ignored and un-ignored many times, as long as any of its parent directories haven't been ignored. -++ + 1. The most deeply nested config file takes precedence over the one in parent dir. In other words, properties from a rule matching a file in a subdirectory override properties from a rule matching a file in a parent directory + 2. Order of rules within file matters - last rule in config file takes precedence over the first one + +- The way `ignore` field works: + 1. By default, files that begin with a `.` are ignored, while all other files are included. + 2. The `.ignore` field overrides this, if present. + 3. If a directory is ignored, file and directories within it cannot be un-ignored. + 4. A file can be ignored and un-ignored many times, as long as any of its parent directories haven't been ignored. -=== fix: Allow `+dfx deploy+` to not take arguments for canisters not being installed +### fix: Allow `dfx deploy` to not take arguments for canisters not being installed -A longstanding bug with `+dfx deploy+` is that if an installation is skipped (usually an implicitly included dependency), it still requires arguments even if the installed canister doesn't. As of this release that bug is now fixed. +A longstanding bug with `dfx deploy` is that if an installation is skipped (usually an implicitly included dependency), it still requires arguments even if the installed canister doesn't. As of this release that bug is now fixed. -=== feat: Add additional logging from bitcoin canister in replica. +### feat: Add additional logging from bitcoin canister in replica. Configures the replica to emit additional logging from the bitcoin canister whenever the bitcoin feature is enabled. This helps show useful information to developers, such as the bitcoin height that the replica currently sees. -=== fix: make `+build+` field optional for custom canisters +### fix: make `build` field optional for custom canisters -Prior to 0.11.0, a custom canister's `+build+` field could be left off if `+dfx build+` was never invoked. To aid in deploying prebuilt canisters, this behavior is now formalized; omitting `+build+` is equivalent to `+build: []+`. +Prior to 0.11.0, a custom canister's `build` field could be left off if `dfx build` was never invoked. To aid in deploying prebuilt canisters, this behavior is now formalized; omitting `build` is equivalent to `build: []`. -=== feat: Use `+--locked+` for Rust canisters +### feat: Use `--locked` for Rust canisters -`+dfx build+`, in Rust canisters, now uses the `+--locked+` flag when building with Cargo. To offset this, `+dfx new --type rust+` now runs `+cargo update+` on the resulting project. +`dfx build`, in Rust canisters, now uses the `--locked` flag when building with Cargo. To offset this, `dfx new --type rust` now runs `cargo update` on the resulting project. -=== feat: Enable threshold ecdsa signature +### feat: Enable threshold ecdsa signature ECDSA signature signing is now enabled by default in new projects, or by running `dfx start --clean`. A test key id "Secp256k1:dfx_test_key" is ready to be used by locally created canisters. -== Dependencies +## Dependencies -=== Updated `+agent-rs+` to 0.20.0 +### Updated `agent-rs` to 0.20.0 -=== Updated `+candid+` to 0.7.15 +### Updated `candid` to 0.7.15 -=== Replica +### Replica Updated replica to elected commit 6e86169e98904047833ba6133e5413d2758d90eb. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/72225[72225] -* https://dashboard.internetcomputer.org/proposal/71669[71669] -* https://dashboard.internetcomputer.org/proposal/71164[71164] -* https://dashboard.internetcomputer.org/proposal/70375[70375] -* https://dashboard.internetcomputer.org/proposal/70002[70002] +* [72225](https://dashboard.internetcomputer.org/proposal/72225) +* [71669](https://dashboard.internetcomputer.org/proposal/71669) +* [71164](https://dashboard.internetcomputer.org/proposal/71164) +* [70375](https://dashboard.internetcomputer.org/proposal/70375) +* [70002](https://dashboard.internetcomputer.org/proposal/70002) -= 0.11.0 +# 0.11.0 -== DFX +## DFX -=== feat: renamed canisters in new projects to _frontend and _backend +### feat: renamed canisters in new projects to _frontend and _backend The names of canisters created for new projects have changed. After `dfx new `, the canister names are: @@ -145,35 +138,35 @@ After `dfx new `, the canister names are: - `_backend` (previously ``) - `_frontend` (previously `_assets`) -=== feat: Enable threshold ecdsa signature +### feat: Enable threshold ecdsa signature -=== feat: new command: dfx canister metadata +### feat: new command: dfx canister metadata For example, to query a canister's candid service definition: `dfx canister metadata hello_backend candid:service` -=== refactor: deprecate /_/candid internal webserver +### refactor: deprecate /_/candid internal webserver The dfx internal webserver now only services the /_/candid endpoint. This is now deprecated. If you were using this to query candid definitions, you can instead use `dfx canister metadata`. -=== refactor: optimize from ic-wasm +### refactor: optimize from ic-wasm Optimize Rust canister WASM module via ic-wasm library instead of ic-cdk-optimizer. A separate installation of ic-cdk-optimizer is no longer needed. The actual optimization was kept the same. -=== feat: Read dfx canister call argument from a file or stdin +### feat: Read dfx canister call argument from a file or stdin Enables passing large arguments that cannot be passed directly in the command line using the `--argument-file` flag. For example: * Named file: `dfx canister call --argument-file ./my/argument/file.txt my_canister_name greet` * Stdin: `echo '( null )' | dfx canister call --argument-file - my_canister_name greet` -=== fix: Use default setting for BTC adapter idle seconds +### fix: Use default setting for BTC adapter idle seconds A lower threshold was no longer necessary. -=== feat: Allow users to configure logging level of bitcoin adapter +### feat: Allow users to configure logging level of bitcoin adapter The bitcoin adapter's logging can be very verbose if debug logging is enabled, making it difficult to make sense of what's going on. On the other hand, these logs are useful for triaging problems. @@ -187,7 +180,7 @@ To get the best of both worlds, this release adds support for an additional conf By default, a log level of "info" is used, which is relatively quiet. Users can change it to "debug" for more verbose logging. -=== chore: update Candid UI canister with commit bffa0ae3c416e8aa3c92c33722a6b1cb31d0f1c3 +### chore: update Candid UI canister with commit bffa0ae3c416e8aa3c92c33722a6b1cb31d0f1c3 This includes the following changes: @@ -195,21 +188,21 @@ This includes the following changes: * Better flamegraph support * Fix bigint error for vec nat8 type -=== feat: dfx will look up the port of the running webserver from .dfx/webserver-port, if present +### feat: dfx will look up the port of the running webserver from .dfx/webserver-port, if present After `dfx start --host 127.0.0.1:0`, the dfx webserver will listen on an ephemeral port. It stores the port value in .dfx/webserver-port. dfx will now look for this file, and if a port is contained within, use that port to connect to the dfx webserver. -=== fix: dfx commands once again work from any subdirectory of a dfx project +### fix: dfx commands once again work from any subdirectory of a dfx project Running `dfx deploy`, `dfx canister id`, `dfx canister call` and so forth work as expected if run from within any subdirectory of a dfx project. Previously, this would create canister_ids.json or .dfx/local/canister_ids.json within the subdirectory. -=== feat: Post-installation tasks +### feat: Post-installation tasks -You can now add your own custom post-installation/post-deployment tasks to any canister type. The new `+post-install+` key for canister objects in `+dfx.json+` can be a command or list of commands, similar to the `+build+` key of `+custom+` canisters, and receives all the same environment variables. For example, to replicate the upload task performed with `+assets+` canisters, you might set `+"post-install": "icx-asset sync $CANISTER_ID dist"+`. +You can now add your own custom post-installation/post-deployment tasks to any canister type. The new `post-install` key for canister objects in `dfx.json` can be a command or list of commands, similar to the `build` key of `custom` canisters, and receives all the same environment variables. For example, to replicate the upload task performed with `assets` canisters, you might set `"post-install": "icx-asset sync $CANISTER_ID dist"`. -=== feat: assets are no longer copied from source directories before being uploaded to asset canister +### feat: assets are no longer copied from source directories before being uploaded to asset canister Assets are now uploaded directly from their source directories, rather than first being copied to an output directory. @@ -218,66 +211,66 @@ If you're using `dfx deploy`, you won't see any change in functionality. If you `dfx canister install --mode=upgrade`, changed files in asset source directories will be detected and uploaded even without an intervening `dfx build`. -=== fix: Added src/declarations to .gitignore for new projects +### fix: Added src/declarations to .gitignore for new projects -=== fix: remove deprecated candid path environment variable +### fix: remove deprecated candid path environment variable -The environment variable format `+CANISTER_CANDID_{name}+`, used in Rust projects, was deprecated in 0.9.2, to be unified with the variables `+CANISTER_CANDID_PATH_{name}+` which are used in other project types. It has now been removed. Note that you will need to update `+ic-cdk-macros+` if you use the `+#[import]+` macro. +The environment variable format `CANISTER_CANDID_{name}`, used in Rust projects, was deprecated in 0.9.2, to be unified with the variables `CANISTER_CANDID_PATH_{name}` which are used in other project types. It has now been removed. Note that you will need to update `ic-cdk-macros` if you use the `#[import]` macro. -=== feat: deprecate `+dfx config+` for removal +### feat: deprecate `dfx config` for removal -The `+dfx config+` command has several issues and is ultimately a poor replacement for https://stedolan.github.io/jq/[`+jq+`]. The command is being deprecated, and will be removed in a later release; we recommend switching to `+jq+` or similar tools (e.g. `+ConvertTo-Json+` in PowerShell, `+to json+` in nushell, etc.) +The `dfx config` command has several issues and is ultimately a poor replacement for [`jq`](https://stedolan.github.io/jq). The command is being deprecated, and will be removed in a later release; we recommend switching to `jq` or similar tools (e.g. `ConvertTo-Json` in PowerShell, `to json` in nushell, etc.) -=== feat: Better build scripts for type:custom +### feat: Better build scripts for type:custom -Build scripts now always receive a CWD of the DFX project root, instead of wherever `+dfx+` was invoked from, and a bare script `+script.sh+` can be specified without needing to prefix with `+./+`. +Build scripts now always receive a CWD of the DFX project root, instead of wherever `dfx` was invoked from, and a bare script `script.sh` can be specified without needing to prefix with `./`. -=== feat: rust, custom, and asset canisters now include candid:service metadata +### feat: rust, custom, and asset canisters now include candid:service metadata Motoko canisters already included this metadata. Also added this metadata to the asset canister wasm, which will cause the next deploy to install this new version. -=== feat: Add safeguard to freezing threshold +### feat: Add safeguard to freezing threshold Some developers mistakenly think that the freezing threshold is measured in cycles, but it is actually measured in seconds. To stop them from accidentally freezing their canisters, setting a freezing threshold above 50M seconds (~1.5 years) now requires a confirmation. -=== fix: restores assets to webpack devserver +### fix: restores assets to webpack devserver -=== chore: updates webpack dependencies for dfx new project +### chore: updates webpack dependencies for dfx new project -Resolves an issue where `+webpack-cli+` was was breaking when users tried to run `+npm start+` in a fresh project. For affected users of 0.10.1, you can resolve this issue manually by running `+npm install webpack@latest webpack-cli@latest terser-webpack-plugin@latest+`. +Resolves an issue where `webpack-cli` was was breaking when users tried to run `npm start` in a fresh project. For affected users of 0.10.1, you can resolve this issue manually by running `npm install webpack@latest webpack-cli@latest terser-webpack-plugin@latest`. -=== feat: Support for new ledger notify function +### feat: Support for new ledger notify function -Ledger 7424ea8 deprecates the existing `+notify+` function with a switch parameter between creating and topping up a canister, and introduces two -functions for doing the same. This should *mostly* be invisible to users, except that previously, if `+dfx ledger create-canister+` or `+dfx ledger top-up+` -failed, you would call `+dfx ledger notify+` after correcting the issue. In order to support the change, this command has been changed to two subcommands: -`+dfx ledger notify create-canister+` and `+dfx ledger notify top-up+`. +Ledger 7424ea8 deprecates the existing `notify` function with a switch parameter between creating and topping up a canister, and introduces two +functions for doing the same. This should *mostly* be invisible to users, except that previously, if `dfx ledger create-canister` or `dfx ledger top-up` +failed, you would call `dfx ledger notify` after correcting the issue. In order to support the change, this command has been changed to two subcommands: +`dfx ledger notify create-canister` and `dfx ledger notify top-up`. -=== feat: `+--from-subaccount+` +### feat: `--from-subaccount` -Previously, the ledger commands assumed all transfers were made from the default subaccount for the identity principal. This feature adds a `+--from-subaccount+` flag to `+dfx ledger transfer+`, `+dfx ledger create-canister+`, and `+dfx ledger top-up+`, to enable making transfers from a selected subaccount. A `+--subaccount+` flag is also added to `+dfx ledger balance+` for convenience. Subaccounts are expected as 64-character hex-strings (i.e. 32 bytes). +Previously, the ledger commands assumed all transfers were made from the default subaccount for the identity principal. This feature adds a `--from-subaccount` flag to `dfx ledger transfer`, `dfx ledger create-canister`, and `dfx ledger top-up`, to enable making transfers from a selected subaccount. A `--subaccount` flag is also added to `dfx ledger balance` for convenience. Subaccounts are expected as 64-character hex-strings (i.e. 32 bytes). -=== feat: cargo audit when building rust canisters +### feat: cargo audit when building rust canisters When a canister with type `rust` is built and `cargo-audit` is installed, dfx will now check for vulnerabilities in the dependencies. If a vulnerability is found, dfx will recommend that the user update to a version without known vulnerabilities. -=== fix: Freezing Threshold now documented +### fix: Freezing Threshold now documented Calls made to retrieve the help output for `canister update-settings` was missing the `freezing-threshold` parameter. -=== chore: warnings and errors are more visible +### chore: warnings and errors are more visible `WARN` and `ERROR` messages are now clearly labelled as such, and the labels are colored accordingly. This is now included when running `dfx canister update-settings -h`. -=== fix: canister call uses candid file if canister type cannot be determined +### fix: canister call uses candid file if canister type cannot be determined The candid file specified in the field `canisters..candid` of dfx.json, or if that not exists `canisters..remote.candid`, is now used when running `dfx canister call`, even when dfx fails to determine the canister type. -=== fix: btc/canister http adapter socket not found by replica after restart +### fix: btc/canister http adapter socket not found by replica after restart After running `dfx start --enable-bitcoin` twice in a row (stopping dfx in between), the second launched replica would fail to connect to the btc adapter. This is because ic-starter @@ -288,7 +281,7 @@ to the btc adapter. Now dfx reuses the previously-used unix domain socket path, for both the btc adapter and for the canister http adapter. -=== fix: dfx stop now waits until dfx and any child processes exit +### fix: dfx stop now waits until dfx and any child processes exit Previously, `dfx stop` would send the TERM signal to the running dfx and its child processes, and then exit immediately. @@ -296,17 +289,17 @@ and then exit immediately. This avoids interference between a dfx process performing cleanup at shutdown and a dfx process that is starting. -=== fix: dfx ping no longer creates a default identity +### fix: dfx ping no longer creates a default identity dfx ping now uses the anonymous identity, and no longer requires dfx.json to be present. -=== fix: Initialize replica with bitcoin regtest flag +### fix: Initialize replica with bitcoin regtest flag When the bitcoin feature is enabled, dfx was launching the replica with the "bitcoin_testnet" feature. The correct feature to use is "bitcoin_regtest". -=== dfx bootstrap now looks up the port of the local replica +### dfx bootstrap now looks up the port of the local replica `dfx replica` writes the port of the running replica to one of these locations: @@ -315,7 +308,7 @@ The correct feature to use is "bitcoin_regtest". `dfx bootstrap` will now use this port value, so it's no longer necessary to edit dfx.json after running `dfx replica`. -=== feat: dfx.json local network settings can be set on the local network, rather than defaults +### feat: dfx.json local network settings can be set on the local network, rather than defaults In `dfx.json`, the `bootstrap`, `bitcoin`, `canister_http`, and `replica` settings can now be specified on the local network, rather than in the `defaults` field. @@ -323,8 +316,7 @@ If one of these four fields is set for the local network, the corresponding fiel in `defaults` will be ignored. Example: -[source, json] ----- +``` json { "networks": { "local": { @@ -335,36 +327,36 @@ Example: } } } ----- +``` -== Dependencies +## Dependencies -=== Rust Agent +### Rust Agent Updated agent-rs to 0.18.0 -=== Motoko +### Motoko Updated Motoko from 0.6.28 to 0.6.29. -=== Replica +### Replica Updated replica to elected commit 8993849de5fab76e796d67750facee55a0bf6649. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/69804[69804] -* https://dashboard.internetcomputer.org/proposal/67990[67990] -* https://dashboard.internetcomputer.org/proposal/67483[67483] -* https://dashboard.internetcomputer.org/proposal/66895[66895] -* https://dashboard.internetcomputer.org/proposal/66888[66888] -* https://dashboard.internetcomputer.org/proposal/65530[65530] -* https://dashboard.internetcomputer.org/proposal/65327[65327] -* https://dashboard.internetcomputer.org/proposal/65043[65043] -* https://dashboard.internetcomputer.org/proposal/64355[64355] -* https://dashboard.internetcomputer.org/proposal/63228[63228] -* https://dashboard.internetcomputer.org/proposal/62143[62143] +* [69804](https://dashboard.internetcomputer.org/proposal/69804) +* [67990](https://dashboard.internetcomputer.org/proposal/67990) +* [67483](https://dashboard.internetcomputer.org/proposal/67483) +* [66895](https://dashboard.internetcomputer.org/proposal/66895) +* [66888](https://dashboard.internetcomputer.org/proposal/66888) +* [65530](https://dashboard.internetcomputer.org/proposal/65530) +* [65327](https://dashboard.internetcomputer.org/proposal/65327) +* [65043](https://dashboard.internetcomputer.org/proposal/65043) +* [64355](https://dashboard.internetcomputer.org/proposal/64355) +* [63228](https://dashboard.internetcomputer.org/proposal/63228) +* [62143](https://dashboard.internetcomputer.org/proposal/62143) -=== ic-ref +### ic-ref Updated ic-ref to 0.0.1-173cbe84 - add ic0.performance_counter system interface @@ -373,33 +365,34 @@ Updated ic-ref to 0.0.1-173cbe84 - support gzip-compressed canister modules - enable canisters to send HTTP requests -= 0.10.1 +# 0.10.1 -== DFX +## DFX -=== fix: Webpack config no longer uses CopyPlugin +### fix: Webpack config no longer uses CopyPlugin Dfx already points to the asset canister's assets directory, and copying to disk could sometimes lead to an annoying "too many open files" error. -=== fix: HSMs are once again supported on Linux +### fix: HSMs are once again supported on Linux On Linux, dfx 0.10.0 failed any operation with an HSM with the following error: - Error: IO: Dynamic loading not supported - +``` +Error: IO: Dynamic loading not supported +``` The fix was to once again dynamically-link the Linux build. -=== feat: error explanation and fixing instructions engine +### feat: error explanation and fixing instructions engine Dfx is now capable of providing explanations and remediation suggestions for entire categories of errors at a time. Explanations and suggestions will slowly be added over time. To see an example of an already existing suggestion, run `dfx deploy --network ic` while using an identity that has no wallet configured. -=== chore: add context to errors +### chore: add context to errors Most errors that happen within dfx are now reported in much more detail. No more plain `File not found` without explanation what even was attempted. -=== fix: identities with configured wallets are not broken anymore and removed only when using the --drop-wallets flag +### fix: identities with configured wallets are not broken anymore and removed only when using the --drop-wallets flag When an identity has a configured wallet, dfx no longer breaks the identity without actually removing it. Instead, if the --drop-wallets flag is specified, it properly removes everything and logs what wallets were linked, @@ -407,68 +400,76 @@ and when the flag is not specified, it does not remove anything. The behavior for identities without any configured wallets is unchanged. -=== feat: bitcoin integration: dfx now generates the bitcoin adapter config file +### feat: bitcoin integration: dfx now generates the bitcoin adapter config file dfx command-line parameters for bitcoin integration: - dfx start --enable-bitcoin # use default node 127.0.0.1:18444 - dfx start --enable-bitcoin --bitcoin-node +``` bash +dfx start --enable-bitcoin # use default node 127.0.0.1:18444 +dfx start --enable-bitcoin --bitcoin-node +``` The above examples also work for dfx replica. These default to values from dfx.json: - .defaults.bitcoin.nodes - .defaults.bitcoin.enabled +``` +.defaults.bitcoin.nodes +.defaults.bitcoin.enabled +``` The --bitcoin-node parameter, if specified on the command line, implies --enable-bitcoin. If --enable-bitcoin or .defaults.bitcoin.enabled is set, then dfx start/replica will launch the ic-btc-adapter process and configure the replica to communicate with it. -=== feat: print wallet balance in a human readable form #2184 +### feat: print wallet balance in a human readable form #2184 -Default behaviour changed for `+dfx wallet balance+`, it will now print cycles amount upscaled to trillions. +Default behaviour changed for `dfx wallet balance`, it will now print cycles amount upscaled to trillions. -New flag `+--precise+` added to `+dfx wallet balance+`. Allows to get exact amount of cycles in wallet (without upscaling). +New flag `--precise` added to `dfx wallet balance`. Allows to get exact amount of cycles in wallet (without upscaling). -=== feat: canister http integration +### feat: canister http integration dfx command-line parameters for canister http requests integration: - dfx start --enable-canister-http - dfx replica --enable-canister-http +``` +dfx start --enable-canister-http +dfx replica --enable-canister-http +``` This defaults to the following value in dfx.json: - .defaults.canister_http.enabled +``` +.defaults.canister_http.enabled +``` -=== fix: specifying ic provider with a trailing slash is recognised correctly +### fix: specifying ic provider with a trailing slash is recognised correctly Specifying the network provider as `https://ic0.app/` instead of `https://ic0.app` is now recognised as the real IC network. -=== Binary cache +### Binary cache Added ic-canister-http-adapter to the binary cache. -== Dependencies +## Dependencies -=== Updated agent-rs to 0.17.0 +### Updated agent-rs to 0.17.0 -== Motoko +## Motoko Updated Motoko from 0.6.26 to 0.6.28. -== Replica +## Replica Updated replica to elected commit b90edb9897718730f65e92eb4ff6057b1b25f766. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/61004[61004] -* https://dashboard.internetcomputer.org/proposal/60222[60222] -* https://dashboard.internetcomputer.org/proposal/59187[59187] -* https://dashboard.internetcomputer.org/proposal/58479[58479] -* https://dashboard.internetcomputer.org/proposal/58376[58376] -* https://dashboard.internetcomputer.org/proposal/57843[57843] -* https://dashboard.internetcomputer.org/proposal/57395[57395] +* [61004](https://dashboard.internetcomputer.org/proposal/61004) +* [60222](https://dashboard.internetcomputer.org/proposal/60222) +* [59187](https://dashboard.internetcomputer.org/proposal/59187) +* [58479](https://dashboard.internetcomputer.org/proposal/58479) +* [58376](https://dashboard.internetcomputer.org/proposal/58376) +* [57843](https://dashboard.internetcomputer.org/proposal/57843) +* [57395](https://dashboard.internetcomputer.org/proposal/57395) -== icx-proxy +## icx-proxy Updated icx-proxy to commit c312760a62b20931431ba45e5b0168ee79ea5cda @@ -477,42 +478,41 @@ Updated icx-proxy to commit c312760a62b20931431ba45e5b0168ee79ea5cda * Added Prometheus metrics endpoint * Added root and invalid ssl and dns mapping -= 0.10.0 +# 0.10.0 -== DFX +## DFX -=== feat: Use null as default value for opt arguments +### feat: Use null as default value for opt arguments Before this, `deploy`ing a canister with an `opt Foo` init argument without specifying an `--argument` would lead to an error: -[source, bash] ----- +``` bash $ dfx deploy Error: Invalid data: Expected arguments but found none. ----- +``` With this change, this isn't an error anymore, but instead `null` is passed as a value. In general, if the user does _not_ provide an `--argument`, and if the init method expects only `opt` arguments, then `dfx` will supply `null` for each argument. Note in particular that this does not try to match `opt` arguments for heterogeneous (`opt`/non-`opt`) signatures. Note moreover that this only impacts a case that would previously error out, so no existing (working) workflows should be affected. -=== feat: dfx identity set-wallet now checks that the provided canister is actually a wallet +### feat: dfx identity set-wallet now checks that the provided canister is actually a wallet This check was previously performed on local networks, but not on mainnet. -=== feat: dfx canister call --candid ... +### feat: dfx canister call --candid ... Allows one to provide the .did file for calls to an arbitrary canister. -=== feat: Install arbitrary wasm into canisters +### feat: Install arbitrary wasm into canisters -You no longer need a DFX project setup with a build task to install an already-built wasm module into a canister ID. The new `+--wasm +` flag to `+dfx canister install+` will bypass project configuration and install the wasm module at `++`. A DFX project setup is still recommended for general use; this should mostly be used for installing pre-built canisters. Note that DFX will also not perform its usual checks for API/ABI/stable-memory compatibility in this mode. +You no longer need a DFX project setup with a build task to install an already-built wasm module into a canister ID. The new `--wasm ` flag to `dfx canister install` will bypass project configuration and install the wasm module at ``. A DFX project setup is still recommended for general use; this should mostly be used for installing pre-built canisters. Note that DFX will also not perform its usual checks for API/ABI/stable-memory compatibility in this mode. -=== feat: Support for 128-bit cycle counts +### feat: Support for 128-bit cycle counts -Cycle counts can now exceed the previously set maximum of 2^64. The new limit is 2^128. A new wallet version has been bundled with this release that supports the new cycle count. You will not be able to use this feature with your existing wallets without running `+dfx wallet upgrade+`, but old wallets will still work just fine with old cycle counts. +Cycle counts can now exceed the previously set maximum of 2^64. The new limit is 2^128. A new wallet version has been bundled with this release that supports the new cycle count. You will not be able to use this feature with your existing wallets without running `dfx wallet upgrade`, but old wallets will still work just fine with old cycle counts. -=== fix: dfx start will once again notice if dfx is already running +### fix: dfx start will once again notice if dfx is already running dfx will once again display 'dfx is already running' if dfx is already running, rather than 'Address already in use'. @@ -521,37 +521,36 @@ As a consequence, after `dfx start` failed to notice that dfx was already runnin it would replace .dfx/pid with an empty file. Later invocations of `dfx stop` would display no output and return a successful exit code, but leave dfx running. -=== fix: dfx canister update-settings works even if the canister id is not known to the project. +### fix: dfx canister update-settings works even if the canister id is not known to the project. This makes the behavior match the usage text of the command: ` Specifies the canister name or id to update. You must specify either canister name/id or the --all option` -=== feat: dfx deploy --upgrade-unchanged or dfx canister install --mode upgrade --upgrade-unchanged +### feat: dfx deploy --upgrade-unchanged or dfx canister install --mode upgrade --upgrade-unchanged When upgrading a canister, `dfx deploy` and `dfx canister install` skip installing the .wasm if the wasm hash did not change. This avoids a round trip through stable memory for all assets on every dfx deploy, for example. By passing this argument, dfx will instead install the wasm even if its hash matches the already-installed wasm. -=== feat: Introduce DFX_CACHE_ROOT environment variable +### feat: Introduce DFX_CACHE_ROOT environment variable A new environment variable, `DFX_CACHE_ROOT`, has been introduced to allow setting the cache root directory to a different location than the configuration root directory. Previously `DFX_CONFIG_ROOT` was repurposed for this which only allowed one location to be set for both the cache and configuration root directories. This is a breaking change since setting `DFX_CONFIG_ROOT` will no longer set the cache root directory to that location. -=== fix: Error if nonzero cycles are passed without a wallet proxy +### fix: Error if nonzero cycles are passed without a wallet proxy Previously, `dfx canister call --with-cycles 1` would silently ignore the `--with-cycles` argument as the DFX principal has no way to pass cycles and the call must be forwarded through the wallet. Now it will error instead of silently ignoring it. To forward a call through the wallet, use `--wallet $(dfx identity get-wallet)`, or `--wallet $(dfx identity --network ic get-wallet)` for mainnet. -=== feat: Configure subnet type of local replica +### feat: Configure subnet type of local replica The local replica sets its parameters according to the subnet type defined in defaults.replica.subnet_type, defaulting to 'application' when none is specified. This makes it less likely to accidentally hit the 'cycles limit exceeded' error in production. Since the previous default was `system`, you may see these types errors in development instead. Possible values for defaults.replica.subnet_type are: "application", "verifiedapplication", "system" Example how to specify the subnet type: -[source, json] ----- +``` json { "defaults": { "replica": { @@ -559,56 +558,59 @@ Example how to specify the subnet type: } } } ----- +``` -=== feat: Introduce command for local cycles top-up +### feat: Introduce command for local cycles top-up `dfx ledger fabricate-cycles ` can be used during local development to create cycles out of thin air and add them to a canister. Instead of supplying a canister name or id it is also possible to use `--all` to add the cycles to every canister in the current project. When no amount is supplied, the command uses 10T cycles as default. Using this command with `--network ic` will result in an error. -=== feat: Private keys can be stored in encrypted format +### feat: Private keys can be stored in encrypted format `dfx identity new` and `dfx identity import` now ask you for a password to encrypt the private key (PEM file) when it is stored on disk. If you decide to use a password, your key will never be written to disk in plain text. In case you don't want to enter your password all the time and want to take the risk of storing your private key in plain text, you can use the `--disable-encryption` flag. The `default` identity as well as already existing identities will NOT be encrypted. If you want to encrypt an existing identity, use the following commands: -[source, bash] ----- +``` bash dfx identity export identity_name > identity.pem # if you have set old_identity_name as the identity that is used by default, switch to a different one dfx identity use other_identity dfx identity remove identity_name dfx identity import identity_name identity.pem ----- +``` -=== feat: Identity export +### feat: Identity export If you want to get your identity out of dfx, you can use `dfx identity export identityname > exported_identity.pem`. But be careful with storing this file as it is not protected with your password. -=== feat: Identity new/import now has a --force flag +### feat: Identity new/import now has a --force flag If you want to script identity creation and don't care about overwriting existing identities, you now can use the `--force` flag for the commands `dfx identity new` and `dfx identity import`. -=== fix: Do not automatically create a wallet on IC +### fix: Do not automatically create a wallet on IC When running `dfx deploy --network ic`, `dfx canister --network ic create`, or `dfx identity --network ic get-wallet` dfx no longer automatically creates a cycles wallet for the user if none is configured. Instead, it will simply report that no wallet was found for that user. Dfx still creates the wallet automatically when running on a local network, so the typical workflow of `dfx start --clean` and `dfx deploy` will still work without having to manually create the wallet. -=== fix: Identities cannot exist and not at the same time +### fix: Identities cannot exist and not at the same time When something went wrong during identity creation, the identity was not listed as existing. But when trying to create an identity with that name, it was considered to be already existing. -=== feat: dfx start and dfx replica can now launch the ic-btc-adapter process +### feat: dfx start and dfx replica can now launch the ic-btc-adapter process Added command-line parameters: - dfx start --enable-bitcoin --btc-adapter-config - dfx replica --enable-bitcoin --btc-adapter-config +``` bash +dfx start --enable-bitcoin --btc-adapter-config +dfx replica --enable-bitcoin --btc-adapter-config +``` These default to values from dfx.json: - .defaults.bitcoin.btc_adapter_config - .defaults.bitcoin.enabled +``` +.defaults.bitcoin.btc_adapter_config +.defaults.bitcoin.enabled +``` The --btc-adapter-config parameter, if specified on the command line, implies --enable-bitcoin. @@ -617,56 +619,55 @@ then dfx start/replica will launch the ic-btc-adapter process. This integration is not yet complete, pending upcoming functionality in ic-starter. -=== fix: report context of errors +### fix: report context of errors dfx now displays the context of an error in several places where previously the only error message would be something like "No such file or directory." -=== chore: updates starter project for Node 18 +### chore: updates starter project for Node 18 Webpack dev server now works for Node 18 (and should work for Node 17). A few packages are also upgraded -== updating dependencies +## updating dependencies Updated to version 0.14.0 of agent-rs -== Cycles wallet +## Cycles wallet -Module hash: bb001d1ebff044ba43c060956859f614963d05c77bd778468fce4de095fe8f92 -https://github.com/dfinity/cycles-wallet/commit/f18e9f5c2f96e9807b6f149c975e25638cc3356b +- Module hash: bb001d1ebff044ba43c060956859f614963d05c77bd778468fce4de095fe8f92 +- https://github.com/dfinity/cycles-wallet/commit/f18e9f5c2f96e9807b6f149c975e25638cc3356b -== Replica +## Replica Updated replica to elected commit b3788091fbdb8bed7e527d2df4cc5e50312f476c. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/57150[57150] -* https://dashboard.internetcomputer.org/proposal/54964[54964] -* https://dashboard.internetcomputer.org/proposal/53702[53702] -* https://dashboard.internetcomputer.org/proposal/53231[53231] -* https://dashboard.internetcomputer.org/proposal/53134[53134] -* https://dashboard.internetcomputer.org/proposal/52627[52627] -* https://dashboard.internetcomputer.org/proposal/52144[52144] -* https://dashboard.internetcomputer.org/proposal/50282[50282] +* [57150](https://dashboard.internetcomputer.org/proposal/57150) +* [54964](https://dashboard.internetcomputer.org/proposal/54964) +* [53702](https://dashboard.internetcomputer.org/proposal/53702) +* [53231](https://dashboard.internetcomputer.org/proposal/53231) +* [53134](https://dashboard.internetcomputer.org/proposal/53134) +* [52627](https://dashboard.internetcomputer.org/proposal/52627) +* [52144](https://dashboard.internetcomputer.org/proposal/52144) +* [50282](https://dashboard.internetcomputer.org/proposal/50282) Added the ic-btc-adapter binary to the cache. -== Motoko +## Motoko Updated Motoko from 0.6.25 to 0.6.26. -= 0.9.3 +# 0.9.3 -== DFX +## DFX -=== feat: dfx deploy now displays URLs for the frontend and candid interface +### feat: dfx deploy now displays URLs for the frontend and candid interface -=== dfx.json +### dfx.json In preparation for BTC integration, added configuration for the bitcoind port: -[source, json] ----- +``` json { "canisters": {}, "defaults": { @@ -675,9 +676,9 @@ In preparation for BTC integration, added configuration for the bitcoind port: } } } ----- +``` -== icx-proxy +## icx-proxy Updated icx-proxy to commit 594b6c81cde6da4e08faee8aa8e5a2e6ae815602, now static-linked. @@ -685,29 +686,29 @@ Updated icx-proxy to commit 594b6c81cde6da4e08faee8aa8e5a2e6ae815602, now static * no longer proxies /_/raw to the dfx internal webserver * allows for generic StreamingCallback tokens -== Replica +## Replica Updated replica to blessed commit d004accc3904e24dddb13a11d93451523e1a8a5f. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/49653[49653] -* https://dashboard.internetcomputer.org/proposal/49011[49011] -* https://dashboard.internetcomputer.org/proposal/48427[48427] -* https://dashboard.internetcomputer.org/proposal/47611[47611] -* https://dashboard.internetcomputer.org/proposal/47512[47512] -* https://dashboard.internetcomputer.org/proposal/47472[47472] -* https://dashboard.internetcomputer.org/proposal/45984[45984] -* https://dashboard.internetcomputer.org/proposal/45982[45982] +* [49653](https://dashboard.internetcomputer.org/proposal/49653) +* [49011](https://dashboard.internetcomputer.org/proposal/49011) +* [48427](https://dashboard.internetcomputer.org/proposal/48427) +* [47611](https://dashboard.internetcomputer.org/proposal/47611) +* [47512](https://dashboard.internetcomputer.org/proposal/47512) +* [47472](https://dashboard.internetcomputer.org/proposal/47472) +* [45984](https://dashboard.internetcomputer.org/proposal/45984) +* [45982](https://dashboard.internetcomputer.org/proposal/45982) -== Motoko +## Motoko Updated Motoko from 0.6.21 to 0.6.25. -= 0.9.2 +# 0.9.2 -== DFX +## DFX -=== feat: Verify Candid and Motoko stable variable type safety of canister upgrades +### feat: Verify Candid and Motoko stable variable type safety of canister upgrades Newly deployed Motoko canisters now embed the Candid interface and Motoko stable signatures in the Wasm module. `dfx deploy` and `dfx canister install` will automatically check @@ -715,11 +716,11 @@ Newly deployed Motoko canisters now embed the Candid interface and Motoko stable 1) the backward compatible of Candid interface in both upgrade and reinstall mode; 2) the type safety of Motoko stable variable type in upgrade mode to avoid accidentally lossing data; -See https://smartcontracts.org/docs/language-guide/compatibility.html[Upgrade compatibility] for more details. +See [Upgrade compatibility](https://smartcontracts.org/docs/language-guide/compatibility.html) for more details. -=== feat: Unified environment variables across build commands +### feat: Unified environment variables across build commands -The three canister types that use a custom build tool - `assets`, `rust`, and `custom` - now all support the same set of environment variables during the build task: +The three canister types that use a custom build tool - `assets`, `rust`, and `custom` - now all support the same set of environment variables during the build task: * `DFX_VERSION` - The version of DFX that was used to build the canister. * `DFX_NETWORK` - The network name being built for. Usually `ic` or `local`. @@ -729,14 +730,13 @@ The three canister types that use a custom build tool - `assets`, `rust`, and `c * `CANISTER_ID` - Same as `CANISTER_ID_{self}`, where `{self}` is the name of _this_ canister. * `CANISTER_CANDID_PATH` - Same as `CANISTER_CANDID_PATH_{self}`, where `{self}` is the name of _this_ canister. -=== feat: Support for local ledger calls +### feat: Support for local ledger calls -If you have an installation of the ICP Ledger (see https://github.com/dfinity/ic/tree/master/rs/rosetta-api/ledger_canister#deploying-locally[Ledger Installation Guide]), `dfx ledger balance` and `dfx ledger transfer` now support +If you have an installation of the ICP Ledger (see [Ledger Installation Guide](https://github.com/dfinity/ic/tree/master/rs/rosetta-api/ledger_canister#deploying-locally)), `dfx ledger balance` and `dfx ledger transfer` now support `--ledger-canister-id` parameter. Some examples: -[source, bash] ----- +``` bash $ dfx ledger \ --network local \ balance \ @@ -748,38 +748,36 @@ $ dfx ledger \ transfer --amount 0.1 --memo 0 \ --ledger-canister-id rrkah-fqaaa-aaaaa-aaaaq-cai 8af54f1fa09faeca18d294e0787346264f9f1d6189ed20ff14f029a160b787e8 Transfer sent at block height: 1 ----- +``` -=== feat: `dfx ledger account-id` can now compute canister addresses +### feat: `dfx ledger account-id` can now compute canister addresses The `dfx ledger account-id` can now compute addresses of principals and canisters. The command also supports ledger subaccounts now. -[source, bash] ----- +``` bash dfx ledger account-id --of-principal 53zcu-tiaaa-aaaaa-qaaba-cai dfx ledger --network small02 account-id --of-canister ledger_demo dfx ledger account-id --of-principal 53zcu-tiaaa-aaaaa-qaaba-cai --subaccount 0000000000000000000000000000000000000000000000000000000000000001 ----- +``` -=== feat: Print the full error chain in case of a failure +### feat: Print the full error chain in case of a failure All `dfx` commands will now print the full stack of errors that led to the problem, not just the most recent error. Example: -[source] ----- +``` Error: Subaccount '00000000000000000000000000000000000000000000000000000000000000000' is not a valid hex string Caused by: Odd number of digits ----- +``` -=== fix: dfx import will now import pem files created by `quill generate` +### fix: dfx import will now import pem files created by `quill generate` `quill generate` currently outputs .pem files without an `EC PARAMETERS` section. `dfx identity import` will now correctly identify these as EC keys, rather than Ed25519. -=== fix: retry on failure for ledger create-canister, top-up, transfer +### fix: retry on failure for ledger create-canister, top-up, transfer dfx now calls `transfer` rather than `send_dfx`, and sets the created_at_time field in order to retry the following commands: @@ -787,7 +785,7 @@ dfx now calls `transfer` rather than `send_dfx`, and sets the created_at_time fi * dfx ledger top-up * dfx ledger transfer -=== feat: Remote canister support +### feat: Remote canister support It's now possible to specify that a canister in dfx.json references a "remote" canister on a specific network, that is, a canister that already exists on that network and is managed by some other project. @@ -795,8 +793,7 @@ that is, a canister that already exists on that network and is managed by some o Motoko, Rust, and custom canisters may be configured in this way. This is the general format of the configuration in dfx.json: -[source, json] ----- +``` json { "canisters": { "": { @@ -809,7 +806,7 @@ This is the general format of the configuration in dfx.json: } } } ----- +``` The "id" field, if set for a given network, specifies the canister ID for the canister on that network. The canister will not be created or installed on these remote networks. @@ -819,12 +816,11 @@ The "candid" field, if set within the remote object, specifies the candid file t building other canisters on a network for which the canister is remote. This definition can differ from the candid definitions for local builds. -For example, if have an installation of the ICP Ledger (see https://github.com/dfinity/ic/tree/master/rs/rosetta-api/ledger_canister#deploying-locally[Ledger Installation Guide]) +For example, if have an installation of the ICP Ledger (see [Ledger Installation Guide](https://github.com/dfinity/ic/tree/master/rs/rosetta-api/ledger_canister#deploying-locally)) in your dfx.json, you could configure the canister ID of the Ledger canister on the ic network as below. In this case, the private interfaces would be available for local builds, but only the public interfaces would be available when building for `--network ic`. -[source, json] ----- +``` json { "canisters": { "ledger": { @@ -845,7 +841,7 @@ when building for `--network ic`. } } } ----- +``` As a second example, suppose that you wanted to write a mock of the ledger in Motoko. In this case, since the candid definition is provided for remote networks, @@ -857,8 +853,7 @@ This way, you can define public update/query functions to aid in local testing, when building/deploying to mainnet, references to methods not found in `ledger.public.did` will be reports as compilation errors. -[source, json] ----- +``` json { "canisters": { "ledger": { @@ -878,17 +873,16 @@ will be reports as compilation errors. } } } ----- +``` -=== feat: Generating remote canister bindings +### feat: Generating remote canister bindings It's now possible to generate the interface of a remote canister using a .did file using the `dfx remote generate-binding |--all` command. This makes it easier to write mocks for local development. Currently, dfx can generate .mo, .rs, .ts, and .js bindings. This is how you specify how to generate the bindings in dfx.json: -[source, json] ----- +``` json { "canisters": { "": { @@ -900,9 +894,9 @@ This is how you specify how to generate the bindings in dfx.json: } } } ----- +``` -== ic-ref +## ic-ref Upgraded from a432156f24faa16d387c9d36815f7ddc5d50e09f to ab8e3f5a04f0f061b8157c2889f8f5de05f952bb @@ -910,66 +904,64 @@ Upgraded from a432156f24faa16d387c9d36815f7ddc5d50e09f to ab8e3f5a04f0f061b8157c * Include canister_ranges in the state tree * Removed limit on cycles in a canister -== Replica +## Replica Updated replica to blessed commit 04fe8b0a1262f07c0cec1fdfa838a37607370a61. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/45091[45091] -* https://dashboard.internetcomputer.org/proposal/43635[43635] -* https://dashboard.internetcomputer.org/proposal/43633[43633] -* https://dashboard.internetcomputer.org/proposal/42783[42783] -* https://dashboard.internetcomputer.org/proposal/42410[42410] -* https://dashboard.internetcomputer.org/proposal/40908[40908] -* https://dashboard.internetcomputer.org/proposal/40647[40647] -* https://dashboard.internetcomputer.org/proposal/40328[40328] -* https://dashboard.internetcomputer.org/proposal/39791[39791] -* https://dashboard.internetcomputer.org/proposal/38541[38541] +* [45091](https://dashboard.internetcomputer.org/proposal/45091) +* [43635](https://dashboard.internetcomputer.org/proposal/43635) +* [43633](https://dashboard.internetcomputer.org/proposal/43633) +* [42783](https://dashboard.internetcomputer.org/proposal/42783) +* [42410](https://dashboard.internetcomputer.org/proposal/42410) +* [40908](https://dashboard.internetcomputer.org/proposal/40908) +* [40647](https://dashboard.internetcomputer.org/proposal/40647) +* [40328](https://dashboard.internetcomputer.org/proposal/40328) +* [39791](https://dashboard.internetcomputer.org/proposal/39791) +* [38541](https://dashboard.internetcomputer.org/proposal/38541) -== Motoko +## Motoko Updated Motoko from 0.6.20 to 0.6.21. -= 0.9.0 +# 0.9.0 -== DFX +## DFX -=== feat!: Remove the wallet proxy and the --no-wallet flag +### feat!: Remove the wallet proxy and the --no-wallet flag Breaking change: Canister commands, except for `dfx canister create`, will make the call directly, rather than via the user's wallet. The `--no-wallet` flag is thus removed from `dfx canister` as its behavior is the default. When working with existing canisters, use the `--wallet` flag in conjunction with `dfx identity get-wallet` in order to restore the old behavior. You will need to upgrade your wallet and each of your existing canisters to work with the new system. To do so, execute the following in each of your dfx projects: -[source, bash] ----- +``` bash dfx wallet upgrade dfx canister --wallet "$(dfx identity get-wallet)" update-settings --all --add-controller "$(dfx identity get-principal)" ----- +``` To upgrade projects that you have deployed to the IC mainnet, execute the following: -[source, bash] ----- +``` bash dfx wallet --network ic upgrade dfx canister --network ic --wallet "$(dfx identity --network ic get-wallet)" update-settings --all --add-controller "$(dfx identity get-principal)" ----- +``` -=== feat: Add --add-controller and --remove-controller flags for "canister update-settings" +### feat: Add --add-controller and --remove-controller flags for "canister update-settings" `dfx canister update-settings` previously only let you overwrite the entire controller list; `--add-controller` and `--remove-controller` instead add or remove from the list. -=== feat: Add --no-withdrawal flag for "canister delete" for when the canister is out of cycles +### feat: Add --no-withdrawal flag for "canister delete" for when the canister is out of cycles `dfx canister delete --no-withdrawal ` can be used to delete a canister without attempting to withdraw cycles. -=== fix: set RUST_MIN_STACK to 8MB for ic-starter (and therefore replica) +### fix: set RUST_MIN_STACK to 8MB for ic-starter (and therefore replica) This matches the value used in production and is meant to exceed the configured 5 MB wasmtime stack. -=== fix: asset uploads will retry failed requests as expected +### fix: asset uploads will retry failed requests as expected Fixed a defect in asset synchronization where no retries would be attempted after the first 30 seconds overall. -== Motoko +## Motoko Updated Motoko from 0.6.11 to 0.6.20. @@ -985,37 +977,36 @@ Updated Motoko from 0.6.11 to 0.6.20. * Stable signatures: frontend, metadata, command-line args * Added heartbeat support -== Cycles wallet +## Cycles wallet -Module hash: 53ec1b030f1891bf8fd3877773b15e66ca040da539412cc763ff4ebcaf4507c5 -https://github.com/dfinity/cycles-wallet/commit/57e53fcb679d1ea33cc713d2c0c24fc5848a9759 +- Module hash: 53ec1b030f1891bf8fd3877773b15e66ca040da539412cc763ff4ebcaf4507c5 +- https://github.com/dfinity/cycles-wallet/commit/57e53fcb679d1ea33cc713d2c0c24fc5848a9759 -== Replica +## Replica Updated replica to blessed commit 75138bbf11e201aac47266f07bee289dc18a082b. This incorporates the following executed proposals: -* https://dashboard.internetcomputer.org/proposal/33828[33828] -* https://dashboard.internetcomputer.org/proposal/31275[31275] -* https://dashboard.internetcomputer.org/proposal/31165[31165] -* https://dashboard.internetcomputer.org/proposal/30392[30392] -* https://dashboard.internetcomputer.org/proposal/30078[30078] -* https://dashboard.internetcomputer.org/proposal/29235[29235] -* https://dashboard.internetcomputer.org/proposal/28784[28784] -* https://dashboard.internetcomputer.org/proposal/27975[27975] -* https://dashboard.internetcomputer.org/proposal/26833[26833] -* https://dashboard.internetcomputer.org/proposal/25343[25343] -* https://dashboard.internetcomputer.org/proposal/23633[23633] +* [33828](https://dashboard.internetcomputer.org/proposal/33828) +* [31275](https://dashboard.internetcomputer.org/proposal/31275) +* [31165](https://dashboard.internetcomputer.org/proposal/31165) +* [30392](https://dashboard.internetcomputer.org/proposal/30392) +* [30078](https://dashboard.internetcomputer.org/proposal/30078) +* [29235](https://dashboard.internetcomputer.org/proposal/29235) +* [28784](https://dashboard.internetcomputer.org/proposal/28784) +* [27975](https://dashboard.internetcomputer.org/proposal/27975) +* [26833](https://dashboard.internetcomputer.org/proposal/26833) +* [25343](https://dashboard.internetcomputer.org/proposal/25343) +* [23633](https://dashboard.internetcomputer.org/proposal/23633) -= 0.8.4 +# 0.8.4 -== DFX +## DFX -=== feat: "rust" canister type +### feat: "rust" canister type You can now declare "rust" canisters in dfx.json. -[source, json] ----- +``` json { "canisters": { "canister_name": { @@ -1025,36 +1016,34 @@ You can now declare "rust" canisters in dfx.json. } } } ----- +``` Don't forget to place a `Cargo.toml` in your project root. -Then dfx will build the rust canister with your rust toolchain. +Then dfx will build the rust canister with your rust toolchain. Please also make sure that you have added the WebAssembly compilation target. -[source, bash] ----- +``` bash rustup target add wasm32-unknown-unknown ----- +``` You can also create new dfx project with a default rust canister. -[source, bash] ----- +``` bash dfx new --type=rust ----- +``` -=== chore: updating dfx new template +### 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 +### 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 +### 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 @@ -1063,62 +1052,62 @@ and can only be performed on a single canister at a time. `dfx canister install --mode=reinstall ` also requires the same confirmation, and no longer works with `--all`. -== Replica +## 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`). -= 0.8.3 +# 0.8.3 -== DFX +## DFX -=== fix: ic-ref linux binary no longer references /nix/store +### fix: ic-ref linux binary no longer references /nix/store This means `dfx start --emulator` has a chance of working if nix is not installed. This has always been broken, even before dfx 0.7.0. -=== fix: replica and ic-starter linux binaries no longer reference /nix/store +### fix: replica and ic-starter linux binaries no longer reference /nix/store This means `dfx start` will work again on linux. This bug was introduced in dfx 0.8.2. -=== feat: replaced --no_artificial_delay option with a sensible default. +### feat: replaced --no_artificial_delay option with a sensible default. The `--no-artificial-delay` option not being the default has been causing a lot of confusion. Now that we have measured in production and already applied a default of 600ms to most subnets deployed out there, we have set the same default for dfx and removed the option. -== Motoko +## Motoko Updated Motoko from 0.6.10 to 0.6.11. * Assertion error messages are now reproducible (#2821) -= 0.8.2 +# 0.8.2 -== DFX +## DFX -=== feat: dfx canister delete can now return cycles to a wallet or dank +### feat: dfx canister delete can now return cycles to a wallet or dank By default `dfx canister delete` will return cycles to the default cycles wallet. Cycles can be returned to a designated canister with `--withdraw-cycles-to-canister` and cycles can be returned to dank at the current identity principal with `--withdraw-cycles-to-dank` and to a designated principal with `--withdraw-cycles-to-dank-principal`. -=== feat: dfx canister create now accepts multiple instances of --controller argument +### feat: dfx canister create now accepts multiple instances of --controller argument It is now possible to create canisters with more than one controller by passing multiple instances of the `--controller parameter to `dfx canister create`. You will need to upgrade your wallet with `dfx wallet upgrade`, or `dfx wallet --network ic upgrade` -=== feat: dfx canister update-settings now accepts multiple instance of --controller argument +### feat: dfx canister update-settings now accepts multiple instance of --controller argument It is now possible to configure a canister to have more than one controller by passing multiple instances of the `--controller parameter to `dfx canister update-settings`. -=== feat: dfx canister info and dfx canister status now display all controllers +### feat: dfx canister info and dfx canister status now display all controllers -=== feat!: dfx canister create --controller named parameter +### feat!: dfx canister create --controller named parameter Breaking change: The controller parameter for `dfx canister create` is now passed as a named parameter, rather than optionally following the canister name. @@ -1126,24 +1115,24 @@ rather than optionally following the canister name. Old: dfx canister create [canister name] [controller] New: dfx canister create --controller [canister name] -=== fix: dfx now respects $DFX_CONFIG_ROOT when looking for legacy credentials +### fix: dfx now respects $DFX_CONFIG_ROOT when looking for legacy credentials Previously this would always look in `$HOME/.dfinity/identity/creds.pem`. -=== fix: changed dfx canister (create|update-settings) --memory-allocation limit to 12 GiB +### fix: changed dfx canister (create|update-settings) --memory-allocation limit to 12 GiB Updated the maximum value for the --memory-allocation value to be 12 GiB (12,884,901,888 bytes) -== Cycles Wallet +## Cycles Wallet - Module hash: 9183a38dd2eb1a4295f360990f87e67aa006f225910ab14880748e091248e086 - https://github.com/dfinity/cycles-wallet/commit/9ef38bb7cd0fe17cda749bf8e9bbec5723da0e95 -=== Added support for multiple controllers +### Added support for multiple controllers You will need to upgrade your wallet with `dfx wallet upgrade`, or `dfx wallet --network ic upgrade` -== Replica +## Replica The included replica now supports public spec 0.18.0 @@ -1156,7 +1145,7 @@ fail. ** If you run `dfx start` without `--background`, you can call `dfx ping --wait-healthy` to wait until the replica is healthy. -== Motoko +## Motoko Updated Motoko from 0.6.7 to 0.6.10 @@ -1164,16 +1153,15 @@ Updated Motoko from 0.6.7 to 0.6.10 * Introduce primitives for `Int` ⇔ `Float` conversions (#2733) * Fix crashing bug for formatting huge floats (#2737) -= 0.8.1 +# 0.8.1 -== DFX +## DFX -=== feat: dfx generate types command +### feat: dfx generate types command -[source, bash] ----- +``` bash dfx generate ----- +``` This new command will generate type declarations for canisters in dfx.json. @@ -1205,76 +1193,74 @@ mo declarations output * .mo - candid mo binding output -=== feat: dfx now supports the anonymous identity +### feat: dfx now supports the anonymous identity Use it with either of these forms: -[source, bash] ----- +``` bash dfx identity use anonymous dfx --identity anonymous ... ----- +``` -=== feat: import default identities +### feat: import default identities Default identities are the pem files generated by `dfx identity new ...` which contain Ed25519 private keys. They are located at `~/.config/dfx/identity/xxx/identity.pem`. Now, you can copy such pem file to another computer and import it there. -[source, bash] ----- +``` bash dfx identity new alice cp ~/.config/dfx/identity/xxx/identity.pem alice.pem # copy the pem file to another computer, then dfx identity import alice alice.pem ----- +``` Before, people can manually copy the pem files to the target directory to "import". Such workaround still works. We suggest to use the `import` subcommand since it also validate the private key. -=== feat: Can now provide a nonstandard wallet module with DFX_WALLET_WASM environment variable +### feat: Can now provide a nonstandard wallet module with DFX_WALLET_WASM environment variable Define DFX_WALLET_WASM in the environment to use a different wasm module when creating or upgrading the wallet. -== Asset Canister +## Asset Canister -=== fix: trust full asset SHA-256 hashes provided by the caller +### fix: trust full asset SHA-256 hashes provided by the caller When the caller provides SHA-256 hashes (which dfx does), the asset canister will no longer recompute these hashes when committing the changes. These recomputations were causing canisters to run out of cycles, or to attempt to exceed the maximum cycle limit per update. -= 0.8.0 +# 0.8.0 The 0.8.0 release includes updates and fixes that are primarily internal to improve existing features and functions rather than user-visible. -== DFX +## DFX -=== fix: dfx identity set-wallet no longer requires --force when used with --network ic +### fix: dfx identity set-wallet no longer requires --force when used with --network ic This was intended to skip verification of the wallet canister on the IC network, but ended up only writing to the wallets.json file if --force was passed. -=== chore: updating dependencies +### chore: updating dependencies * Support for the latest version of the {IC} specification and replica. * Updating to latest versions of Motoko, Candid, and agent-rs -=== feat: Type Inference Update +### feat: Type Inference Update -* Changes to `+dfx new+` project template and JavaScript codegen to support type inference in IDE's +* Changes to `dfx new` project template and JavaScript codegen to support type inference in IDE's * Adding webpack dev server to project template * Migration path documented at https://sdk.dfinity.org/docs/release-notes/0.8.0-rn.html -= 0.7.7 +# 0.7.7 Breaking changes to frontend code generation, documented in 0.8.0 -== DFX +## DFX -=== feat: deploy and canister install will now only upgrade a canister if the wasm actually changed +### feat: deploy and canister install will now only upgrade a canister if the wasm actually changed dfx deploy and dfx canister install now compare the hash of the already-installed module with the hash of the built canister's wasm output. If they are the same, they leave the canister @@ -1282,51 +1268,53 @@ in place rather than upgrade it. They will still synchronize assets to an asset of the result of this comparison. -= 0.7.6 +# 0.7.6 -== icx-proxy +## icx-proxy The streaming callback mechanism now requires the following record structure for the token: - type StreamingCallbackToken = record { - key: text; - content_encoding: text; - index: nat; - sha256: opt blob; - }; +``` +type StreamingCallbackToken = record { + key: text; + content_encoding: text; + index: nat; + sha256: opt blob; +}; +``` Previously, the token could be a record with any set of fields. -= 0.7.2 +# 0.7.2 -== DFX +## DFX -=== fix: set default cycle balance to 3T +### fix: set default cycle balance to 3T Change the default cycle balance of a canister from 10T cycles to 3T cycles. -== Cycles Wallet +## Cycles Wallet - Module hash: 1404b28b1c66491689b59e184a9de3c2be0dbdd75d952f29113b516742b7f898 - https://github.com/dfinity/cycles-wallet/commit/e902708853ab621e52cb68342866d36e437a694b -=== fix: It is no longer possible to remove the last controller. +### fix: It is no longer possible to remove the last controller. Fixed an issue where the controller can remove itself from the list of controllers even if it's the only one, leaving the wallet uncontrolled. Added defensive checks to the wallet's remove_controller and deauthorize methods. -= 0.7.1 +# 0.7.1 -== DFX +## DFX -=== feat: sign request_status for update call +### feat: sign request_status for update call When using `dfx canister sign` to generate a update message, a corresponding request_status message is also signed and append to the json as `signed_request_status`. Then after sending the update message, the user can check the request_status using -`dfx canister send message.json --status`. +`dfx canister send message.json --status`. -=== fix: wallet will not proxy dfx canister call by default +### fix: wallet will not proxy dfx canister call by default Previously, `dfx canister call` would proxy queries and update calls via the wallet canister by default. (There was the `--no-wallet` flag to bypass the proxy and perform the calls as the selected identity.) @@ -1335,50 +1323,50 @@ by default and calls would take a while to resolve. This fix makes it so that `d proxies via the wallet by default. To proxy calls via the wallet, you can do `dfx canister --wallet= call`. -=== feat: add --no-artificial-delay to dfx replica and start +### feat: add --no-artificial-delay to dfx replica and start This change adds the `--no-artificial-delay` flag to `dfx start` and `dfx replica`. The replica shipped with dfx has always had an artificial consensus delay (introduced to simulate a delay users might see in a networked environment.) With this new flag, that delay can be lessened. However, you might see increased CPU utilization by the replica process. -=== feat: add deposit cycles and uninstall code +### feat: add deposit cycles and uninstall code This change introduces the `deposit_cycles` and `uninstall_code` management canister methods as dedicated `dfx canister` subcommands. -=== fix: allow consistent use of canisters ids in canister command +### fix: allow consistent use of canisters ids in canister command This change updates the dfx commands so that they will accept either a canister name (sourced from your local project) or a valid canister id. -= 0.7.0 +# 0.7.0 -== DFX +## DFX -=== feat: add output type to request-status +### feat: add output type to request-status This change allows you to specify the format the return result for `dfx canister request-status`. -=== fix: deleting a canister on a network removes entries for other networks +### fix: deleting a canister on a network removes entries for other networks This change fixes a bug where deleting a canister on a network removed all other entries for the canister in the canister_ids.json file. -=== feat: point built-in `ic` network provider at mainnet +### feat: point built-in `ic` network provider at mainnet `--network ic` now points to the mainnet IC (as Sodium has been deprecated.) -=== feat: add candid UI canister +### feat: add candid UI canister The dedicated candid UI canister is installed on a local network when doing a `dfx canister install` or `dfx deploy`. -=== fix: Address already in use (os error 48) when issuing dfx start +### fix: Address already in use (os error 48) when issuing dfx start This fixes an error which occurred when starting a replica right after stopping it. -=== feat: ledger subcommands +### feat: ledger subcommands dfx now supports a dedicated `dfx ledger` subcommand. This allows you to interact with the ledger canister installed on the Internet Computer. Example commands include `dfx ledger account-id` which @@ -1386,7 +1374,7 @@ prints the Account Identifier associated with your selected identity, `dfx ledge allows you to transfer ICP from your ledger account to another, and `dfx ledger create-canister` which allows you to create a canister from ICP. -=== feat: update to 0.17.0 of the Interface Spec +### feat: update to 0.17.0 of the Interface Spec This is a breaking change to support 0.17.0 of the Interface Spec. Compute & memory allocation values are set when creating a canister. An optional controller can also be specified when creating a canister. @@ -1395,109 +1383,109 @@ allows the controller to update the controller, the compute allocation, and the canister. The freezing threshold value isn't exposed via dfx cli yet, but it may still be modified by calling the management canister via `dfx canister call aaaaa-aa update-settings` -=== feat: add wallet subcommands +### feat: add wallet subcommands dfx now supports a dedicated `dfx wallet` subcommand. This allows you to interact with the cycles wallet associated with your selected identity. For example, `dfx wallet balance` to get the cycle balance, `dfx wallet list-addresses` to display the associated controllers & custodians, and `dfx wallet send ` to send cycles to another wallet. -== Cycles Wallet +## Cycles Wallet - Module Hash: a609400f2576d1d6df72ce868b359fd08e1d68e58454ef17db2361d2f1c242a1 - https://github.com/dfinity/cycles-wallet/commit/06bb256ca0738640be51cf84caaced7ea02ca29d -=== feat: Use Internet Identity Service. +### feat: Use Internet Identity Service. -= 0.7.0-beta.5 +# 0.7.0-beta.5 -== Cycles Wallet +## Cycles Wallet - Module Hash: 3d5b221387875574a9fd75b3165403cf1b301650a602310e9e4229d2f6766dcc - https://github.com/dfinity/cycles-wallet/commit/c3cbfc501564da89e669a2d9de810d32240baf5f -=== feat: Updated to Public Interface 0.17.0 +### feat: Updated to Public Interface 0.17.0 -=== feat: The wallet_create_canister method now takes a single record argument, which includes canister settings. +### feat: The wallet_create_canister method now takes a single record argument, which includes canister settings. -=== fix: Return correct content type and encoding for non-gz files. +### fix: Return correct content type and encoding for non-gz files. -=== fix: Updated frontend for changes to canister creation interface. +### fix: Updated frontend for changes to canister creation interface. -= 0.7.0-beta.3 +# 0.7.0-beta.3 -== DFX +## DFX -=== fix: assets with an unrecognized file extension will use content-type "application/octet-stream" +### fix: assets with an unrecognized file extension will use content-type "application/octet-stream" -= 0.7.0-beta.2 +# 0.7.0-beta.2 -== DFX +## DFX -=== feat: synchronize assets rather than uploading even assets that did not change +### feat: synchronize assets rather than uploading even assets that did not change DFX will now also delete assets from the container that do not exist in the project. This means if you stored assets in the container, and they are not in the project, dfx deploy or dfx install will delete them. -== Asset Canister +## Asset Canister -=== Breaking change: change to store() method signature +### Breaking change: change to store() method signature - now takes arguments as a single record parameter - must now specify content type and content encoding, and may specify the sha256 -= 0.7.0-beta.1 +# 0.7.0-beta.1 -== DFX +## DFX -=== fix: now deletes from the asset canister assets that no longer exist in the project +### fix: now deletes from the asset canister assets that no longer exist in the project -=== feat: get certified canister info from read state #1514 +### feat: get certified canister info from read state #1514 Added `dfx canister info` command to get certified canister information. Currently this information is limited to the controller of the canister and the SHA256 hash of its WASM module. If there is no WASM module installed, the hash will be None. -== Asset Canister +## Asset Canister -=== Breaking change: change to list() method signature +### Breaking change: change to list() method signature - now takes a parameter, which is an empty record - now returns an array of records -=== Breaking change: removed the keys() method +### Breaking change: removed the keys() method - use list() instead -= 0.7.0-beta.0 +# 0.7.0-beta.0 -== DFX +## DFX -=== feat: webserver can now serve large assets +### feat: webserver can now serve large assets -= 0.6.26 +# 0.6.26 -== DFX +## DFX -=== feat: add --no-wallet flag and --wallet option to allow Users to bypass Wallet or specify a Wallet to use for calls (#1476) +### feat: add --no-wallet flag and --wallet option to allow Users to bypass Wallet or specify a Wallet to use for calls (#1476) Added `--no-wallet` flag to `dfx canister` and `dfx deploy`. This allows users to call canister management functionality with their Identity as the Sender (bypassing their Wallet canister.) Added `--wallet` option to `dfx canister` and `dfx deploy`. This allows users to specify a wallet canister id to use as the Sender for calls. `--wallet` and `--no-wallet` conflict with each other. Omitting both will invoke the selected Identity's wallet canister to perform calls. -=== feat: add canister subcommands `sign` and `send` +### feat: add canister subcommands `sign` and `send` Users can use `dfx canister sign ...` to generated a signed canister call in a json file. Then `dfx canister send [message.json]` to the network. Users can sign the message on an air-gapped computer which is secure to host private keys. -==== Note +#### Note * `sign` and `send` currently don't proxy through wallet canister. Users should use the subcommands with `dfx canister --no-wallet sign ...`. * The `sign` option `--expire-after` will set the `ingress_expiry` to a future timestamp which is current plus the duration. Then users can send the message during a 5 minutes time window ending in that `ingress_expiry` timestamp. Sending the message earlier or later than the time window will both result in a replica error. -=== feat: implement the HTTP Request proposal in dfx' bootstrap webserver. + +### feat: implement the HTTP Request proposal in dfx' bootstrap webserver. + And add support for http requests in the base storage canister (with a default to `/index.html`). This does not support other encodings than `identity` for now (and doesn't even return any headers). This support will be added to the upgraded asset storage canister built in #1482. @@ -1508,21 +1496,20 @@ This commit also upgrades tokio and reqwest in order to work correctly. There ar Renamed the `project_name` in our own generated assets to `canister_name`, for things that are generated during canister build (and not project generation). -=== feat: add support for ECDSA on secp256k1 +### feat: add support for ECDSA on secp256k1 You can now a generate private key via OpenSSL or a simlar tool, import it into dfx, and use it to sign an ingress message. -[source, bash] ----- +``` bash openssl ecparam -name secp256k1 -genkey -out identity.pem dfx identity import identity.pem dfx identity use dfx canister call ... ----- +``` -== Asset Canister +## Asset Canister -=== feat: The asset canister can now store assets that exceed the message ingress limit (2 MB) +### feat: The asset canister can now store assets that exceed the message ingress limit (2 MB) * Please note that neither the JS agent nor the HTTP server have been updated yet to server such large assets. * The existing interface is left in place for backwards-compatibility, but deprecated: @@ -1530,23 +1517,23 @@ dfx canister call ... ** store(): use create_batch(), create_chunk(), and commit_batch() instead ** list(): use keys() instead -= 0.6.25 +# 0.6.25 -== DFX +## DFX - feat: dfx now provides CANISTER_ID_ environment variables for all canisters to "npm build" when building the frontend. -== Agents +## Agents -=== Rust Agent +### Rust Agent - feat: AgentError due to request::Error will now include the reqwest error message in addition to "Could not reach the server" - feat: Add secp256k1 support (dfx support to follow) -= 0.6.24 +# 0.6.24 -== DFX +## DFX - feat: add option to specify initial cycles for newly created canisters (#1433) @@ -1554,42 +1541,38 @@ Added option to `dfx canister create` and `dfx deploy` commands: `--with-cycles This allows the user to specify the initial cycle balance of a canister created by their wallet. This option is a no-op for the Sodium network. -[source, bash] ----- +``` bash dfx canister create --with-cycles 8000000000 some_canister dfx deploy --with-cycles 8000000000 ----- +``` Help string: -[source, bash] ----- +``` Specifies the initial cycle balance to deposit into the newly created canister. The specified amount needs to take the canister create fee into account. This amount is deducted from the wallet's cycle balance ----- +``` - feat: install `dfx` by version or tag (#1426) This feature adds a new dfx command `toolchain` which have intuitive subcommands. The toolchain specifiers can be a complete version number, major minor version, or a tag name. -[source, bash] ----- +``` bash dfx toolchain install 0.6.24 # complete version dfx toolchain install 0.6 # major minor dfx toolchain install latest # tag name dfx toolchain default latest dfx toolchain list dfx toolchain uninstall latest ----- +``` - fix: onboarding related fixups (#1420) Now that the Mercury Alpha application subnetwork is up and we are getting ready to onboard devs, the dfx error message for wallet creation has changed: For example, -[source, bash] ----- +``` bash dfx canister --network=alpha create hello Creating canister "hello"... Creating the canister using the wallet canister... @@ -1598,15 +1581,14 @@ Unable to create a wallet canister on alpha: The Replica returned an error: code 3, message: "Sender not authorized to use method." Wallet canisters on alpha may only be created by an administrator. Please submit your Principal ("dfx identity get-principal") in the intake form to have one created for you. ----- +``` - feat: add deploy wallet subcommand to identity (#1414) This feature adds the deploy-wallet subcommand to the dfx identity. The User provides the ID of the canister onto which the wallet WASM is deployed. -[source, bash] ----- +``` bash dfx identity deploy-wallet --help dfx-identity-deploy-wallet Installs the wallet WASM to the provided canister id @@ -1620,11 +1602,11 @@ ARGS: FLAGS: -h, --help Prints help information -V, --version Prints version information ----- +``` -= 0.6.22 +# 0.6.22 -== DFX +## DFX - feat: dfx call random value when argument is not provided (#1376) @@ -1632,18 +1614,18 @@ FLAGS: - fix: address panic in dfx replica command (#1338) - fix: dfx new webpack.config.js does not encourage running 'js' through ts-… (#1341) -== Sample apps +## Sample apps + +- There have been updates, improvements, and new sample apps added to the [examples](https://github.com/dfinity/examples/tree/master/motoko) repository. + + All of Motoko sample apps in the [examples](https://github.com/dfinity/examples/tree/master/motoko) repository have been updated to work with the latest release of the SDK. -- There have been updates, improvements, and new sample apps added to thelink:https://github.com/dfinity/examples/tree/master/motoko[examples] repository. -+ -All of Motoko sample apps in the link:https://github.com/dfinity/examples/tree/master/motoko[examples] repository have been updated to work with the latest release of the SDK. -+ -There are new sample apps to illustrate using arrays (link:https://github.com/dfinity/examples/tree/master/motoko/quicksort[Quicksort]) and building create/read/update/delete (CRUD) operations for a web application link:https://github.com/dfinity/examples/tree/master/motoko/superheroes[Superheroes]. + There are new sample apps to illustrate using arrays ([Quicksort](https://github.com/dfinity/examples/tree/master/motoko/quicksort)) and building create/read/update/delete (CRUD) operations for a web application [Superheroes](https://github.com/dfinity/examples/tree/master/motoko/superheroes). -- The link:https://github.com/dfinity/linkedup:[LinkedUp] sample application has been updated to work with the latest release of Motoko and the SDK. +- The [LinkedUp](https://github.com/dfinity/linkedup) sample application has been updated to work with the latest release of Motoko and the SDK. -== Motoko +## Motoko -== Agents +## Agents -== Canister Development Kit (CDK) +## Canister Development Kit (CDK) From b540cfef6e20544280a4f69123338788151f35e3 Mon Sep 17 00:00:00 2001 From: Marcin Nowak-Liebiediew Date: Wed, 3 Aug 2022 21:25:02 +0200 Subject: [PATCH 11/11] chore: Release 0.11.1 (#2406) Signed-off-by: Marcin Nowak-Liebiediew --- Cargo.lock | 2 +- public/manifest.json | 3 ++- src/dfx/Cargo.toml | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 414647e749..bdea261367 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1065,7 +1065,7 @@ dependencies = [ [[package]] name = "dfx" -version = "0.11.1-beta.3" +version = "0.11.1" dependencies = [ "actix", "actix-cors", diff --git a/public/manifest.json b/public/manifest.json index 2deb40de1a..46191b0199 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -61,6 +61,7 @@ "0.11.1-beta.0", "0.11.1-beta.1", "0.11.1-beta.2", - "0.11.1-beta.3" + "0.11.1-beta.3", + "0.11.1" ] } diff --git a/src/dfx/Cargo.toml b/src/dfx/Cargo.toml index 6e8c9c55ad..afec421943 100644 --- a/src/dfx/Cargo.toml +++ b/src/dfx/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "dfx" -version = "0.11.1-beta.3" +version = "0.11.1" authors = ["DFINITY Team"] edition = "2018" build = "assets/build.rs"