From b6be97314ff679a0762f50c2f7c81260f869df84 Mon Sep 17 00:00:00 2001 From: Eric Swanson <64809312+ericswanson-dfinity@users.noreply.github.com> Date: Wed, 30 Aug 2023 10:20:03 -0700 Subject: [PATCH 1/7] fix: dfx canister id no longer warns about plaintext passwords on mainnet (#3340) `dfx canister id` doesn't use the identity, but displays a warning if the selected identity is stored in plaintext. Motivation: to make it easier for a new feature, 'dfx canister url', to also not display this warning. --- e2e/tests-dfx/id.bash | 8 ++++++ src/dfx/src/commands/canister/id.rs | 17 ++++++++++- src/dfx/src/commands/canister/mod.rs | 42 +++++++++++++++------------- 3 files changed, 47 insertions(+), 20 deletions(-) diff --git a/e2e/tests-dfx/id.bash b/e2e/tests-dfx/id.bash index 5ae571ddc8..f019a3996a 100644 --- a/e2e/tests-dfx/id.bash +++ b/e2e/tests-dfx/id.bash @@ -23,6 +23,14 @@ teardown() { assert_match "$(jq -r .e2e_project_backend.local < .dfx/local/canister_ids.json)" } +@test "id subcommand does not display warning about plaintext keys" { + install_asset id + dfx identity get-principal + echo "{}" | jq '.e2e_project_backend.ic = "bd3sg-teaaa-aaaaa-qaaba-cai"' >canister_ids.json + assert_command dfx canister id e2e_project_backend --ic + assert_eq "bd3sg-teaaa-aaaaa-qaaba-cai" +} + @test "id subcommand works from a subdirectory of the project - ephemeral id" { install_asset id dfx_start diff --git a/src/dfx/src/commands/canister/id.rs b/src/dfx/src/commands/canister/id.rs index 28139d14f9..314c7143d3 100644 --- a/src/dfx/src/commands/canister/id.rs +++ b/src/dfx/src/commands/canister/id.rs @@ -1,19 +1,34 @@ use crate::lib::environment::Environment; use crate::lib::error::DfxResult; +use crate::lib::network::network_opt::NetworkOpt; use candid::Principal; use clap::Parser; +use dfx_core::config::model::canister_id_store::CanisterIdStore; +use dfx_core::network::provider::{create_network_descriptor, LocalBindDetermination}; /// Prints the identifier of a canister. #[derive(Parser)] pub struct CanisterIdOpts { /// Specifies the name of the canister. canister: String, + + #[command(flatten)] + network: NetworkOpt, } pub async fn exec(env: &dyn Environment, opts: CanisterIdOpts) -> DfxResult { env.get_config_or_anyhow()?; + let network_descriptor = create_network_descriptor( + env.get_config(), + env.get_networks_config(), + opts.network.to_network_name(), + None, + LocalBindDetermination::AsConfigured, + )?; + let canister_id_store = + CanisterIdStore::new(env.get_logger(), &network_descriptor, env.get_config())?; + let canister_name = opts.canister.as_str(); - let canister_id_store = env.get_canister_id_store()?; let canister_id = Principal::from_text(canister_name).or_else(|_| canister_id_store.get(canister_name))?; println!("{}", Principal::to_text(&canister_id)); diff --git a/src/dfx/src/commands/canister/mod.rs b/src/dfx/src/commands/canister/mod.rs index b93c98d753..bad25894c6 100644 --- a/src/dfx/src/commands/canister/mod.rs +++ b/src/dfx/src/commands/canister/mod.rs @@ -61,31 +61,35 @@ pub enum SubCommand { } pub fn exec(env: &dyn Environment, opts: CanisterOpts) -> DfxResult { - let agent_env = create_agent_environment(env, opts.network.to_network_name())?; + let agent_env; + let env = if matches!(&opts.subcmd, SubCommand::Id(_)) { + env + } else { + agent_env = create_agent_environment(env, opts.network.to_network_name())?; + &agent_env + }; let runtime = Runtime::new().expect("Unable to create a runtime"); runtime.block_on(async { let call_sender = CallSender::from(&opts.wallet) .map_err(|e| anyhow!("Failed to determine call sender: {}", e))?; match opts.subcmd { - SubCommand::Call(v) => call::exec(&agent_env, v, &call_sender).await, - SubCommand::Create(v) => create::exec(&agent_env, v, &call_sender).await, - SubCommand::Delete(v) => delete::exec(&agent_env, v, &call_sender).await, - SubCommand::DepositCycles(v) => deposit_cycles::exec(&agent_env, v, &call_sender).await, - SubCommand::Id(v) => id::exec(&agent_env, v).await, - SubCommand::Install(v) => install::exec(&agent_env, v, &call_sender).await, - SubCommand::Info(v) => info::exec(&agent_env, v).await, - SubCommand::Metadata(v) => metadata::exec(&agent_env, v).await, - SubCommand::RequestStatus(v) => request_status::exec(&agent_env, v).await, - SubCommand::Send(v) => send::exec(&agent_env, v, &call_sender).await, - SubCommand::Sign(v) => sign::exec(&agent_env, v, &call_sender).await, - SubCommand::Start(v) => start::exec(&agent_env, v, &call_sender).await, - SubCommand::Status(v) => status::exec(&agent_env, v, &call_sender).await, - SubCommand::Stop(v) => stop::exec(&agent_env, v, &call_sender).await, - SubCommand::UninstallCode(v) => uninstall_code::exec(&agent_env, v, &call_sender).await, - SubCommand::UpdateSettings(v) => { - update_settings::exec(&agent_env, v, &call_sender).await - } + SubCommand::Call(v) => call::exec(env, v, &call_sender).await, + SubCommand::Create(v) => create::exec(env, v, &call_sender).await, + SubCommand::Delete(v) => delete::exec(env, v, &call_sender).await, + SubCommand::DepositCycles(v) => deposit_cycles::exec(env, v, &call_sender).await, + SubCommand::Id(v) => id::exec(env, v).await, + SubCommand::Install(v) => install::exec(env, v, &call_sender).await, + SubCommand::Info(v) => info::exec(env, v).await, + SubCommand::Metadata(v) => metadata::exec(env, v).await, + SubCommand::RequestStatus(v) => request_status::exec(env, v).await, + SubCommand::Send(v) => send::exec(env, v, &call_sender).await, + SubCommand::Sign(v) => sign::exec(env, v, &call_sender).await, + SubCommand::Start(v) => start::exec(env, v, &call_sender).await, + SubCommand::Status(v) => status::exec(env, v, &call_sender).await, + SubCommand::Stop(v) => stop::exec(env, v, &call_sender).await, + SubCommand::UninstallCode(v) => uninstall_code::exec(env, v, &call_sender).await, + SubCommand::UpdateSettings(v) => update_settings::exec(env, v, &call_sender).await, } }) } From c984b259717031fea24c4e8a4a13348159ecd5d5 Mon Sep 17 00:00:00 2001 From: Eric Swanson <64809312+ericswanson-dfinity@users.noreply.github.com> Date: Tue, 5 Sep 2023 14:42:17 -0700 Subject: [PATCH 2/7] chore: promote dfx 0.14.4 (#3349) --- public/manifest.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/public/manifest.json b/public/manifest.json index 3d6cdcdc0d..1816a4231c 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -1,6 +1,6 @@ { "tags": { - "latest": "0.14.3" + "latest": "0.14.4" }, "versions": [ "0.5.0", @@ -56,6 +56,7 @@ "0.13.1", "0.14.1", "0.14.2", - "0.14.3" + "0.14.3", + "0.14.4" ] } From 20d7f187da4151859e6beef758a0dff7949153af Mon Sep 17 00:00:00 2001 From: DFINITY bot <58022693+dfinity-bot@users.noreply.github.com> Date: Thu, 7 Sep 2023 22:32:26 +0200 Subject: [PATCH 3/7] chore: update replica version to cabe2ae3 (#3352) Updated replica to elected commit cabe2ae3ca115b1a3f24d75814d4f8e317b2964d. This incorporates the following executed proposals: - [124331](https://dashboard.internetcomputer.org/proposal/124331) - [124330](https://dashboard.internetcomputer.org/proposal/124330) - [124272](https://dashboard.internetcomputer.org/proposal/124272) --- CHANGELOG.md | 5 +- nix/sources.json | 114 +++++++++++++------------- src/dfx/assets/dfx-asset-sources.toml | 74 ++++++++--------- 3 files changed, 98 insertions(+), 95 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c1e9125021..7d7168c4f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -167,9 +167,12 @@ Updated Motoko to [0.9.7](https://github.com/dfinity/motoko/releases/tag/0.9.7) ### Replica -Updated replica to elected commit 3bcccef07408921fe849c92dd2437adc157ef9c3. +Updated replica to elected commit cabe2ae3ca115b1a3f24d75814d4f8e317b2964d. This incorporates the following executed proposals: +- [124331](https://dashboard.internetcomputer.org/proposal/124331) +- [124330](https://dashboard.internetcomputer.org/proposal/124330) +- [124272](https://dashboard.internetcomputer.org/proposal/124272) - [124021](https://dashboard.internetcomputer.org/proposal/124021) - [123977](https://dashboard.internetcomputer.org/proposal/123977) - [123976](https://dashboard.internetcomputer.org/proposal/123976) diff --git a/nix/sources.json b/nix/sources.json index fdb1c5acc1..0c6becdec1 100644 --- a/nix/sources.json +++ b/nix/sources.json @@ -6,62 +6,62 @@ "homepage": "https://rustsec.org", "owner": "RustSec", "repo": "advisory-db", - "rev": "5373b7ebb0b56b09639fd1ae7957de4e3e099036", - "sha256": "1v68mxzy1sds5nr7acwivc5gzgdyzmi2rg67d8r8pjjbc2vj6n3x", + "rev": "370cdc73f5332995b61e2dd281f170b41df44319", + "sha256": "17rk04rxfqiqqsz7aw2f4abfm2wls70rgy22smm7mhm1di7lba6a", "type": "tarball", - "url": "https://github.com/RustSec/advisory-db/archive/5373b7ebb0b56b09639fd1ae7957de4e3e099036.tar.gz", + "url": "https://github.com/RustSec/advisory-db/archive/370cdc73f5332995b61e2dd281f170b41df44319.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "canister_sandbox-x86_64-darwin": { "builtin": false, "description": "The canister_sandbox binary. It must be updated together with the replica binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "1q7p3v94n18wx9bkxgizcbznwg2fjzhyf5j1b2041a8gwirxqnra", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0fhzrw051y8ac9qsc2n2g3bihfk3vkynrb3p6rysmp3mci8q5vm7", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/canister_sandbox.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/canister_sandbox.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/canister_sandbox.gz" }, "canister_sandbox-x86_64-linux": { "builtin": false, "description": "The canister_sandbox binary. It must be updated together with the replica binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0pz4jhhizrjhank31fr0xqym5q10b6lk8x0p4xyz625mn2zh31j0", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "1aym92nlmi4yj18ww27jzkw7d3zpjd8g1dbkgj9dmjwz8m861j5x", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/canister_sandbox.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/canister_sandbox.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/canister_sandbox.gz" }, "ic-admin-x86_64-darwin": { "builtin": false, "description": "The ic-admin binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "01kq894x3925496zp0yrs6vw51li5ycy1jv8mdk3lmi47h46pgx6", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0ld705bg4xn82rn6pxhyijqkbkwdx9ylg2l8rwniiaaz19kdyfwp", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-admin.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-admin.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/ic-admin.gz" }, "ic-admin-x86_64-linux": { "builtin": false, "description": "The ic-admin binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "19qhvmz9c1hrwapwc15i7gkyz467rchmm8j1r0vqwwm4z2najcbh", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "10qzyza0sp6lijlvkjphambmky8131avjfvsjsa16iqg0lla4fsz", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-admin.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-admin.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/ic-admin.gz" }, "ic-btc-adapter-x86_64-darwin": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "1qaylm18hd9yf1qgb49i9a5508819r5isdpmm71gvhws3j1zghjx", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "04brndn2f26kkc2sqwc70kv6bprmgs0hcjxg6v3xgbby5d6ym20i", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-btc-adapter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-btc-adapter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/ic-btc-adapter.gz" }, "ic-btc-adapter-x86_64-linux": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "10l0ix147466i91v102p16swr3ggi0n10jng5wrn0j6yp7h2kcqg", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "1hs03x9vxq00skwd6va604wh994wbc599j6h1yg5ridvivd4x795", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-btc-adapter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-btc-adapter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/ic-btc-adapter.gz" }, "ic-btc-canister": { @@ -74,36 +74,36 @@ }, "ic-https-outcalls-adapter-x86_64-darwin": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0wl7s6yjrvc5n7wd225h6fxwqdvgg5mj81aqa8a7hpacqr3pzarr", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "071gln7fwj558xxg0nk1gbkc3py5wych82qw8gm083j4wjhc3lnz", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-https-outcalls-adapter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-https-outcalls-adapter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/ic-https-outcalls-adapter.gz" }, "ic-https-outcalls-adapter-x86_64-linux": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0izzrfmssmgcwrwb9hn3brsw3zjgh25k33glgmrwr435013740q6", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0szk9cy030f99722sry5lpk0lk3cb05aygmsp2w1dx8y2jy1f801", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-https-outcalls-adapter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-https-outcalls-adapter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/ic-https-outcalls-adapter.gz" }, "ic-nns-init-x86_64-darwin": { "builtin": false, "description": "The ic-nns-init binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0l37ns28s7qpg0rhb82nlvqr4r8y9nnv4qgd9pdfd2nd5v4dx5y4", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0fwbxw8sxpn6vl9090s880hmwwzqqh4lffglkik0hmgk9g0kgnlq", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-nns-init.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-nns-init.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/ic-nns-init.gz" }, "ic-nns-init-x86_64-linux": { "builtin": false, "description": "The ic-nns-init binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "1k4c6l47ykjxbm01g4qly2igw8i2jfsx41pifr6jq956a50w3arr", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "11n1fpdsq4f06ws248mx0kjyb5hqgdd043df61bpm8z9fwvlz8gg", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-nns-init.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-nns-init.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/ic-nns-init.gz" }, "ic-ref-x86_64-darwin": { @@ -126,18 +126,18 @@ }, "ic-starter-x86_64-darwin": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0rpk9in8bxvhj1sjxjgnaqczqdyk56qid1jw33kdzvcd11ra229b", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0mg6gxmlqzpvz8w26ay281dh7pcldnmi7v7p1n8cbwapnj6q5igj", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-starter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-starter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/ic-starter.gz" }, "ic-starter-x86_64-linux": { "builtin": false, - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "1cd2zphmlm0ybkp4f37n33iy34ykbkk89qnb55i8zdz0q3nkhchi", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0r43igqm4xbgwrfxzpy1hfgzm4vh9bz99grgz7hwx7q6z1mmf6wx", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-starter.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-starter.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/ic-starter.gz" }, "icx-proxy-x86_64-darwin": { @@ -187,55 +187,55 @@ "replica-x86_64-darwin": { "builtin": false, "description": "The replica binary. It must be updated together with the canister_sandbox binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0j8czmsan1z7z9w81rj2c1absnwdhyyxhd978d2irswdyvg91asw", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "05glmd38bb78lvmlyvwikxwyjlqxcnjrpsjkghf2mxsqndmsramn", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/replica.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/replica.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/replica.gz" }, "replica-x86_64-linux": { "builtin": false, "description": "The replica binary. It must be updated together with the canister_sandbox binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0abz0llvp1bny0f386zchqdl5w6rnsdpg9dzfszghj00zg78qrps", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "1g5xfs2mfvca0havr8c1cmki6fpqq5ajsqacly0dz44pj25xkvgx", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/replica.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/replica.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/replica.gz" }, "sandbox_launcher-x86_64-darwin": { "builtin": false, "description": "The sandbox_launcher binary. It must be updated together with the replica binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0cswnpipbhlw5z3gbxgcxhwylakjm0r6cpqrd420wj7m7zl9h99a", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0lavk9j6hydas4vs5yay6949z64r93j04sjjgdph7f8llavp8y3k", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/sandbox_launcher.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/sandbox_launcher.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/sandbox_launcher.gz" }, "sandbox_launcher-x86_64-linux": { "builtin": false, "description": "The sandbox_launcher binary. It must be updated together with the replica binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "04rc0csp2igqd3k0mfapavi9mqfy7j3lk82w27di0q5v6lry16ls", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "1pqfcyakgd14gj0n125j5ldayg2b6z1x3as0pww12wfdadar6qxw", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/sandbox_launcher.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/sandbox_launcher.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/sandbox_launcher.gz" }, "sns-x86_64-darwin": { "builtin": false, "description": "The sns binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "0951fam21xrhhsrldl57zcqcw7d9vdlcgnbpv3wyhxvwiqja08q7", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "00yxyj52yya5pczxw37x86rsynd5jb95glfh26l8n38rg5fih1q1", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/sns.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/sns.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-darwin/sns.gz" }, "sns-x86_64-linux": { "builtin": false, "description": "The sns binary.", - "rev": "3bcccef07408921fe849c92dd2437adc157ef9c3", - "sha256": "1qlnbzaw1fjpra913frdirfcfcs3fg08zn4s0m9lml2nbgcnv57w", + "rev": "cabe2ae3ca115b1a3f24d75814d4f8e317b2964d", + "sha256": "0l7ibq8px4bqzrj224xy56b9l6rp3rbmfwgd47izmpaa6lg9s1ps", "type": "file", - "url": "https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/sns.gz", + "url": "https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/sns.gz", "url_template": "https://download.dfinity.systems/ic//openssl-static-binaries/x86_64-linux/sns.gz" } } diff --git a/src/dfx/assets/dfx-asset-sources.toml b/src/dfx/assets/dfx-asset-sources.toml index a38c913e58..e012e60732 100644 --- a/src/dfx/assets/dfx-asset-sources.toml +++ b/src/dfx/assets/dfx-asset-sources.toml @@ -1,5 +1,5 @@ # generated by write-dfx-asset-sources.sh -replica-rev = '3bcccef07408921fe849c92dd2437adc157ef9c3' +replica-rev = 'cabe2ae3ca115b1a3f24d75814d4f8e317b2964d' [x86_64-darwin.ic-ref] url = 'https://download.dfinity.systems/ic-ref/ic-ref-0.0.1-a9f73dba-x86_64-darwin.tar.gz' @@ -10,24 +10,24 @@ url = 'https://github.com/dfinity/icx-proxy/releases/download/rev-c312760/binari sha256 = '5783bba5021cf43149bc118789cea29f6462fd97dd78bdb776f8782ea7813d27' [x86_64-darwin.ic-admin] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-admin.gz' -sha256 = 'a6bf6b083c24563a66ab68cbe0992f9186c2b7d1d983fb4d2245a4d149427806' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-admin.gz' +sha256 = '973bdf660a5fa9182dcf888a477dea8dcf35b18c1ef66b6c16c876f25601a751' [x86_64-darwin.ic-btc-adapter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-btc-adapter.gz' -sha256 = '5dc2f7831c9ac3fdc2a9f5361d4b4e0121508a4a3191f570703e358842a55ee1' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-btc-adapter.gz' +sha256 = '1188ea4d2b7eadd7c736af4b06817e35df65f6048771ac059bd308276cb37911' [x86_64-darwin.ic-https-outcalls-adapter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-https-outcalls-adapter.gz' -sha256 = '39ab7f47c64c5d7814525805246b796f37ccbb33b008d1f8b185ed2cbdd18772' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-https-outcalls-adapter.gz' +sha256 = 'dfd2c1a0e4440e04ea431c0b0499e7c5dfc1e67a615af07a47a548ee8ea52f1c' [x86_64-darwin.ic-nns-init] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-nns-init.gz' -sha256 = 'c497dec82ecd8ae6da4ded61b2ad4d1e6592f1a656a0053378171f8d84b66750' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-nns-init.gz' +sha256 = '98da37c14bf35508669cf4394709c4f8735e214048830412ddc6deae11ef8b3b' [x86_64-darwin.ic-starter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/ic-starter.gz' -sha256 = '2b09a172088deddfe6185c8616b129d337fc1956f6c92e759070f7856c4cf366' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/ic-starter.gz' +sha256 = 'f2c5828db457f1c5900df7ec13ab6d94dd035b40c22b2338fafb7e4c6b7fe655' [x86_64-darwin.motoko] url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Darwin-x86_64-0.9.7.tar.gz' @@ -35,21 +35,21 @@ sha256 = 'e0892c56fb937e28384ef7a2e53205becc869b6834d1cbc579c29c36d8622e46' # The replica and canister_sandbox binaries must have the same revision. [x86_64-darwin.replica] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/replica.gz' -sha256 = '5cab90def68deb1c45432735d8bd878d5bbd546042e68078fae707ab74fd0c49' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/replica.gz' +sha256 = 'b6aaac6bb358f72a1c7c53ea9ba5651d53e9799f916f4feba6e8ac8546abf415' # The replica and canister_sandbox binaries must have the same revision. [x86_64-darwin.canister_sandbox] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/canister_sandbox.gz' -sha256 = '2a5bdc73e40fa94080584116e7e1974e3c6eff623fbe3e57ea1c054bd21ef7e0' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/canister_sandbox.gz' +sha256 = 'a7ee82516475dcaa7d3677ac6cfddc633a18d778c20aa671620af95000cf1f3a' [x86_64-darwin.sandbox_launcher] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/sandbox_launcher.gz' -sha256 = '2a2598e83ff5480e0469195f6632a8722aea39ececf5f5c62f9cc275e3b55c33' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/sandbox_launcher.gz' +sha256 = '737874b7a214b9036f7b526a02e44899989f48325ef9a237d1aa7968649a5b51' [x86_64-darwin.sns] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-darwin/sns.gz' -sha256 = '0723a0248e7c77e8f9d877d9c768dba91dce30fba7d046b38630f720aa72a124' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-darwin/sns.gz' +sha256 = '0107185d79190d8ba811d0d157d292a559afb341fd0cde3fbb45792f8af4dd03' [x86_64-darwin.motoko-base] url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-base-library.tar.gz' @@ -68,24 +68,24 @@ url = 'https://github.com/dfinity/icx-proxy/releases/download/rev-c312760/binari sha256 = '7a5612a1fb7512d22dcd37627a9d626fbc282b172665a832fe2cc2b243789fa1' [x86_64-linux.ic-admin] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-admin.gz' -sha256 = '7031a9acf8a4728e37c841a25a21cbc790efe73bb104c6afe21906967edd10a7' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-admin.gz' +sha256 = '5f3ba228050f471394967a3bb9551801f9595755f0cab9a98cd45c0dd4f71f83' [x86_64-linux.ic-btc-adapter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-btc-adapter.gz' -sha256 = '0fb329e0b9de4860332fcf4a102c88ef8dccb5095780b0438ac69043428f8082' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-btc-adapter.gz' +sha256 = '259d4eda8ebbc55c9e0fd0c8940a5b9ca4043901466dd3f8d400e0be531f40c3' [x86_64-linux.ic-https-outcalls-adapter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-https-outcalls-adapter.gz' -sha256 = '06037246006590cc737df48d318b804ffec1755ec3c2b478e6ec55adabcbff47' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-https-outcalls-adapter.gz' +sha256 = '012017bc141ef516b8b8ba3eaf0a586c4c0ae6a5c5672dc449c981013c4bf36b' [x86_64-linux.ic-nns-init] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-nns-init.gz' -sha256 = '39abc14151a6242c4d76f106d2b5932222fea2f0149317405d5d4e7f08358ccc' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-nns-init.gz' +sha256 = 'efa14f3777e9a37a5730ae0d025a7b1896e5e504bd22223437c011acdb75c186' [x86_64-linux.ic-starter] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/ic-starter.gz' -sha256 = '113238edc0e0b78f6229cbe284e65cd393e1e318f60c47ee5c1e545ae1fda2b1' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/ic-starter.gz' +sha256 = '9d1b576bf8069fcee1f92fbf94fe4a7093fa9f83c1dfdf5de66f7552f18b8364' [x86_64-linux.motoko] url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Linux-x86_64-0.9.7.tar.gz' @@ -93,21 +93,21 @@ sha256 = 'aad447afca5897d35762f69831ca147d50024aa7f274d93649a5116846e768b7' # The replica and canister_sandbox binaries must have the same revision. [x86_64-linux.replica] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/replica.gz' -sha256 = 'fa668ccefb0048f8be76bfa5779bb6d9f0421b86ec1b341cf07685bb29057f29' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/replica.gz' +sha256 = 'fdedd98b909790df80a74c612d55c1f83a13676581a1bc15048a6d578576bdbc' # The replica and canister_sandbox binaries must have the same revision. [x86_64-linux.canister_sandbox] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/canister_sandbox.gz' -sha256 = '408601bfb0b508f37d27177434a95920e0523dee20bb30a65550e61f2194e45f' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/canister_sandbox.gz' +sha256 = 'bdc86050459fcbda927c73b5f05093f78f76f8fcf208ce51909ec44aad48d5ab' [x86_64-linux.sandbox_launcher] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/sandbox_launcher.gz' -sha256 = '9a9ae03335bb6010db115ca049873cdee19ae25657b90ae668f8457135032c13' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/sandbox_launcher.gz' +sha256 = 'bc63935553cd711138bf40abd1c3374b3caf1a2db28860817c24b43795670edf' [x86_64-linux.sns] -url = 'https://download.dfinity.systems/ic/3bcccef07408921fe849c92dd2437adc157ef9c3/openssl-static-binaries/x86_64-linux/sns.gz' -sha256 = 'fc946dd95b56d04a53059ad88fc0734333c75c8e2dbb1192ca57bac0d55f96e2' +url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b2964d/openssl-static-binaries/x86_64-linux/sns.gz' +sha256 = 'fa069d1e354addfae321ed7157571e371b9a9629be132164fe78917e115ef150' [x86_64-linux.motoko-base] url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-base-library.tar.gz' From 2e12ac6ae4eeadef4bcd1479dd1db5801f18833b Mon Sep 17 00:00:00 2001 From: Eric Swanson <64809312+ericswanson-dfinity@users.noreply.github.com> Date: Thu, 7 Sep 2023 14:56:37 -0700 Subject: [PATCH 4/7] fix: allow open PRs that update replica vs different base branches (#3354) Make it possible to open PRs to update the replica against different base branches. For example, to update both the master branch and a release branch to a given replica version. Previous behavior would be for the workflow to fail when trying to push a branch that already exists. Sample workflow: https://github.com/dfinity/sdk/actions/runs/6114047174 Sample result PR: https://github.com/dfinity/sdk/pull/3355 Compare vs this PR, which did not incorporate the base branch name and would have conflicted: https://github.com/dfinity/sdk/pull/3352 --- .github/workflows/update-replica-version.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/update-replica-version.yml b/.github/workflows/update-replica-version.yml index a74f3d3f0e..72ed5189bd 100644 --- a/.github/workflows/update-replica-version.yml +++ b/.github/workflows/update-replica-version.yml @@ -68,10 +68,10 @@ jobs: git config committer.name "GitHub Actions Bot" git config user.email "${{ github.event.sender.id }}+${{ github.event.sender.login }}@users.noreply.github.com" git config user.name "${{ github.event.sender.login }}" - git checkout -b chore-update-replica-${{ env.REPLICA_VERSION }} + git checkout -b chore-update-replica-${{ env.REPLICA_VERSION }}-${{ github.event.inputs.sdkBranch }} git add . git commit -m "chore: update replica version to ${{ env.REPLICA_VERSION }}" - git push origin chore-update-replica-${{ env.REPLICA_VERSION }} + git push origin chore-update-replica-${{ env.REPLICA_VERSION }}-${{ github.event.inputs.sdkBranch }} - name: create Pull Request, with CHANGELOG.md entry suggestion uses: actions/github-script@v6 @@ -113,10 +113,10 @@ jobs: title: `chore: update replica version to ${new_replica_sha__short}`, owner, repo, - head: 'chore-update-replica-${{ env.REPLICA_VERSION }}', + head: 'chore-update-replica-${{ env.REPLICA_VERSION }}-${{ github.event.inputs.sdkBranch }}', base: '${{ github.event.inputs.sdkBranch }}', body: [ - `## Suggested [CHANGELOG.md](https://github.com/${owner}/${repo}/edit/chore-update-replica-${{ env.REPLICA_VERSION }}/CHANGELOG.md) changes`, + `## Suggested [CHANGELOG.md](https://github.com/${owner}/${repo}/edit/chore-update-replica-${{ env.REPLICA_VERSION }}-${{ github.event.inputs.sdkBranch }}/CHANGELOG.md) changes`, '```', '## Dependencies', '', From 50bbf3b27e83c87fbadf2e47c3cc1625782de719 Mon Sep 17 00:00:00 2001 From: DFINITY bot <58022693+dfinity-bot@users.noreply.github.com> Date: Fri, 8 Sep 2023 18:41:38 +0200 Subject: [PATCH 5/7] build: niv advisory-db: update 370cdc73 -> 0fcce3f7 (#3359) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Changelog for advisory-db: Branch: main Commits: [RustSec/advisory-db@370cdc73...0fcce3f7](https://github.com/RustSec/advisory-db/compare/370cdc73f5332995b61e2dd281f170b41df44319...0fcce3f7cbbc76da50ab0d778399bf85dc141834) * [`0fcce3f7`](https://github.com/rustsec/advisory-db/commit/0fcce3f7cbbc76da50ab0d778399bf85dc141834) Bump rustsec-admin to 0.8.7 ([RustSec/advisory-db⁠#1772](http://r.duckduckgo.com/l/?uddg=https://github.com/RustSec/advisory-db/issues/1772)) --- nix/sources.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nix/sources.json b/nix/sources.json index 0c6becdec1..0857c04555 100644 --- a/nix/sources.json +++ b/nix/sources.json @@ -6,10 +6,10 @@ "homepage": "https://rustsec.org", "owner": "RustSec", "repo": "advisory-db", - "rev": "370cdc73f5332995b61e2dd281f170b41df44319", - "sha256": "17rk04rxfqiqqsz7aw2f4abfm2wls70rgy22smm7mhm1di7lba6a", + "rev": "0fcce3f7cbbc76da50ab0d778399bf85dc141834", + "sha256": "1mpmxdhdyh2cjgdwppk0spj252hw02xisc3gs43hxim6yd7565gi", "type": "tarball", - "url": "https://github.com/RustSec/advisory-db/archive/370cdc73f5332995b61e2dd281f170b41df44319.tar.gz", + "url": "https://github.com/RustSec/advisory-db/archive/0fcce3f7cbbc76da50ab0d778399bf85dc141834.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "canister_sandbox-x86_64-darwin": { From 66085c48ba68135d78fe84918578b5a8fe2763f7 Mon Sep 17 00:00:00 2001 From: mraszyk <31483726+mraszyk@users.noreply.github.com> Date: Fri, 8 Sep 2023 23:05:38 +0200 Subject: [PATCH 6/7] feat: Unknown lookup status of a path in certificate yields error (#3278) Absence proofs have been recently enabled on the IC (see [MR](https://github.com/dfinity/ic/commit/2ac0fe91cd737977bf039c55502a31b363884c69)) and thus the IC is going to produce certificate whose lookup returns Absent for paths whose values are missing in the state tree. This PR reflects this change. --- CHANGELOG.md | 4 ++++ src/dfx/src/lib/state_tree/canister_info.rs | 7 ++----- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7d7168c4f6..4b9bffcec4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ # UNRELEASED +### feat: Updated handling of missing values in state tree certificates + +The `Unknown` lookup of a path in a certificate results in an `AgentError` (the IC returns `Absent` for non-existing paths). + ### fix: dfx deploy urls printed for asset canisters ### chore: --emulator parameter is deprecated and will be discontinued soon diff --git a/src/dfx/src/lib/state_tree/canister_info.rs b/src/dfx/src/lib/state_tree/canister_info.rs index 7b01527bb9..f84b49c737 100644 --- a/src/dfx/src/lib/state_tree/canister_info.rs +++ b/src/dfx/src/lib/state_tree/canister_info.rs @@ -12,7 +12,7 @@ pub async fn read_state_tree_canister_controllers( .read_state_canister_info(canister_id, "controllers") .await { - Err(AgentError::LookupPathUnknown(_) | AgentError::LookupPathAbsent(_)) => { + Err(AgentError::LookupPathAbsent(_)) => { return Ok(None); } r => r.with_context(|| format!("Failed to read controllers of canister {canister_id}."))?, @@ -57,10 +57,7 @@ pub async fn read_state_tree_canister_module_hash( .await { Ok(blob) => Some(blob), - // If the canister is empty, this path does not exist. - // The replica doesn't support negative lookups, therefore if the canister - // is empty, the replica will return lookup_path([], Pruned _) = Unknown - Err(AgentError::LookupPathUnknown(_)) | Err(AgentError::LookupPathAbsent(_)) => None, + Err(AgentError::LookupPathAbsent(_)) => None, Err(x) => bail!(x), }; From 5cdedd3b6909b1ec6483549abf32cdfa95f22137 Mon Sep 17 00:00:00 2001 From: DFINITY bot <58022693+dfinity-bot@users.noreply.github.com> Date: Sat, 9 Sep 2023 00:40:45 +0200 Subject: [PATCH 7/7] chore: update Motoko version to 0.9.8 (#3357) ## Suggested [CHANGELOG.md](https://github.com/dfinity/sdk/edit/chore-update-motoko-0.9.8/CHANGELOG.md) changes ``` ## Dependencies ### Motoko Updated Motoko to [0.9.8](https://github.com/dfinity/motoko/releases/tag/0.9.8) --- nix/sources.json | 18 +++++++++--------- src/dfx/assets/dfx-asset-sources.toml | 16 ++++++++-------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/nix/sources.json b/nix/sources.json index 0857c04555..c97f57826a 100644 --- a/nix/sources.json +++ b/nix/sources.json @@ -162,27 +162,27 @@ "builtin": false, "description": "The Motoko base library", "owner": "dfinity", - "sha256": "04awra5kjj9fwf3pcjr5r821ki5ajjn70ggw4in26psdi7czsziv", + "sha256": "18qp0d8mr6hcnbym81a4hgvj036vm0qdbjb833w1rqqhibv1083s", "type": "tarball", - "url": "https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-base-library.tar.gz", + "url": "https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-base-library.tar.gz", "url_template": "https://github.com/dfinity/motoko/releases/download//motoko-base-library.tar.gz", - "version": "0.9.7" + "version": "0.9.8" }, "motoko-x86_64-darwin": { "builtin": false, - "sha256": "0iifcbc3d762g72wpl9ld2dqdk5y0lrfb8pp9qw2hzlkzdb2r2g0", + "sha256": "153lnpkdna9dv76zvmy44farsy8r4ixv4yi8bf5qnkr9dmkmrdr7", "type": "file", - "url": "https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Darwin-x86_64-0.9.7.tar.gz", + "url": "https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-Darwin-x86_64-0.9.8.tar.gz", "url_template": "https://github.com/dfinity/motoko/releases/download//motoko-Darwin-x86_64-.tar.gz", - "version": "0.9.7" + "version": "0.9.8" }, "motoko-x86_64-linux": { "builtin": false, - "sha256": "1dv8wx36h4d594vdjx7jlx504l3x2k53367nc9bx75sqraplgm5a", + "sha256": "11yaciq3fq6fckqrw9gh5wb23cz5wxk9fij0z107nsiys9z46g2i", "type": "file", - "url": "https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Linux-x86_64-0.9.7.tar.gz", + "url": "https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-Linux-x86_64-0.9.8.tar.gz", "url_template": "https://github.com/dfinity/motoko/releases/download//motoko-Linux-x86_64-.tar.gz", - "version": "0.9.7" + "version": "0.9.8" }, "replica-x86_64-darwin": { "builtin": false, diff --git a/src/dfx/assets/dfx-asset-sources.toml b/src/dfx/assets/dfx-asset-sources.toml index e012e60732..1b4fce71df 100644 --- a/src/dfx/assets/dfx-asset-sources.toml +++ b/src/dfx/assets/dfx-asset-sources.toml @@ -30,8 +30,8 @@ url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b29 sha256 = 'f2c5828db457f1c5900df7ec13ab6d94dd035b40c22b2338fafb7e4c6b7fe655' [x86_64-darwin.motoko] -url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Darwin-x86_64-0.9.7.tar.gz' -sha256 = 'e0892c56fb937e28384ef7a2e53205becc869b6834d1cbc579c29c36d8622e46' +url = 'https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-Darwin-x86_64-0.9.8.tar.gz' +sha256 = '27b75c676d294f8b8b5b287ab27b2419799d9523c4d7fdcdd92d29dbe6b57494' # The replica and canister_sandbox binaries must have the same revision. [x86_64-darwin.replica] @@ -52,8 +52,8 @@ url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b29 sha256 = '0107185d79190d8ba811d0d157d292a559afb341fd0cde3fbb45792f8af4dd03' [x86_64-darwin.motoko-base] -url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-base-library.tar.gz' -sha256 = '073f8ddcc39f89b0765e3b69f3ac0a1975b09975bf869b8147ad3ced61d779a3' +url = 'https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-base-library.tar.gz' +sha256 = 'cd8213878fc1663e5c343eeee9f72d10e31e0ea40ae3d1ac24936deb9ca617f4' [x86_64-darwin.ic-btc-canister] url = 'https://github.com/dfinity/bitcoin-canister/releases/download/release%2F2023-03-31/ic-btc-canister.wasm.gz' @@ -88,8 +88,8 @@ url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b29 sha256 = '9d1b576bf8069fcee1f92fbf94fe4a7093fa9f83c1dfdf5de66f7552f18b8364' [x86_64-linux.motoko] -url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-Linux-x86_64-0.9.7.tar.gz' -sha256 = 'aad447afca5897d35762f69831ca147d50024aa7f274d93649a5116846e768b7' +url = 'https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-Linux-x86_64-0.9.8.tar.gz' +sha256 = '513c437ed23e6a7b40f840469766e7e5b321162ff0259ef164ce60377064ca87' # The replica and canister_sandbox binaries must have the same revision. [x86_64-linux.replica] @@ -110,8 +110,8 @@ url = 'https://download.dfinity.systems/ic/cabe2ae3ca115b1a3f24d75814d4f8e317b29 sha256 = 'fa069d1e354addfae321ed7157571e371b9a9629be132164fe78917e115ef150' [x86_64-linux.motoko-base] -url = 'https://github.com/dfinity/motoko/releases/download/0.9.7/motoko-base-library.tar.gz' -sha256 = '073f8ddcc39f89b0765e3b69f3ac0a1975b09975bf869b8147ad3ced61d779a3' +url = 'https://github.com/dfinity/motoko/releases/download/0.9.8/motoko-base-library.tar.gz' +sha256 = 'cd8213878fc1663e5c343eeee9f72d10e31e0ea40ae3d1ac24936deb9ca617f4' [x86_64-linux.ic-btc-canister] url = 'https://github.com/dfinity/bitcoin-canister/releases/download/release%2F2023-03-31/ic-btc-canister.wasm.gz'