From 1a1cbeb401eca8da0a3adc84f2c55183b265ae7a Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Wed, 4 Sep 2024 19:16:21 +0200 Subject: [PATCH 01/35] Added json_serde. --- rust/basic_ethereum/Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/rust/basic_ethereum/Cargo.toml b/rust/basic_ethereum/Cargo.toml index f9c3b3d97..6f4fb1432 100644 --- a/rust/basic_ethereum/Cargo.toml +++ b/rust/basic_ethereum/Cargo.toml @@ -21,5 +21,6 @@ ic-crypto-extended-bip32 = { git = "https://github.com/dfinity/ic", tag = "relea ic-crypto-sha3 = { git = "https://github.com/dfinity/ic", tag = "release-2024-06-26_23-01-base", package = "ic-crypto-sha3" } ic-ethereum-types = { git = "https://github.com/dfinity/ic", tag = "release-2024-06-26_23-01-base", package = "ic-ethereum-types" } serde = "1.0" +serde_json = "1.0" serde_bytes = "0.11.15" num-traits = "0.2.19" \ No newline at end of file From 7e124288e38a86fba970db8289dac17e4bd5e912 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Wed, 4 Sep 2024 19:16:38 +0200 Subject: [PATCH 02/35] Added a `get_balance` endpoint. --- rust/basic_ethereum/basic_ethereum.did | 3 ++ rust/basic_ethereum/src/lib.rs | 42 +++++++++++++++++++++++++- 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/rust/basic_ethereum/basic_ethereum.did b/rust/basic_ethereum/basic_ethereum.did index 723e6d14f..c704e4174 100644 --- a/rust/basic_ethereum/basic_ethereum.did +++ b/rust/basic_ethereum/basic_ethereum.did @@ -42,6 +42,9 @@ service : (opt InitArg) -> { // If the owner is not set, it defaults to the caller's principal. ethereum_address : (owner: opt principal) -> (text); + // Returns the balance of the given Ethereum address. + get_balance : (address: text) -> (Wei); + // Returns the transaction count for the Ethereum address derived for the given principal. // // If the owner is not set, it defaults to the caller's principal. diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 49695fa57..66202e6c7 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -9,12 +9,13 @@ use alloy_primitives::{hex, Signature, TxKind, U256}; use candid::{CandidType, Deserialize, Nat, Principal}; use evm_rpc_canister_types::{ BlockTag, EvmRpcCanister, GetTransactionCountArgs, GetTransactionCountResult, - MultiGetTransactionCountResult, + MultiGetTransactionCountResult, EthSepoliaService, RpcService, RequestResult }; use ic_cdk::api::management_canister::ecdsa::{EcdsaCurve, EcdsaKeyId}; use ic_cdk::{init, update}; use ic_ethereum_types::Address; use std::str::FromStr; +use std::u64; pub const EVM_RPC_CANISTER_ID: Principal = Principal::from_slice(b"\x00\x00\x00\x00\x02\x30\x00\xCC\x01\x01"); // 7hfb6-caaaa-aaaar-qadga-cai @@ -35,6 +36,45 @@ pub async fn ethereum_address(owner: Option) -> String { wallet.ethereum_address().to_string() } +#[derive(Debug, Deserialize)] +struct Balance { + result: String, +} + +#[update] +pub async fn get_balance(address: String) -> Nat { + let _caller = validate_caller_not_anonymous(); + let chain_id = read_state(|s| s.ethereum_network().chain_id()); + let json = format!(r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": {} }}"#, address, chain_id); + let (response,) = EVM_RPC.request(RpcService::EthSepolia(EthSepoliaService::PublicNode), json, 500u64, 1_000_000_000u128) + .await + .unwrap_or_else(|e| { + panic!( + "failed to get the balance of address {:?}, error: {:?}", + address, e + ) + }); + match response { + RequestResult::Ok(balance_result) => { + let balance_result : Result = serde_json::from_str(&balance_result); + let balance_string = balance_result + .unwrap_or_else(|e| { + panic!( + "failed to get parse get_balance, error: {:?}", + e + ) + }); + if balance_string.result.len() % 2 == 0 { + u64::from_str_radix(&balance_string.result[2..], 16).unwrap().into() + } else { + u64::from_str_radix(&format!("0{}", &balance_string.result[2..]), 16).unwrap().into() + } + }, + RequestResult::Err(_) => panic!("Say something here.") + } + +} + #[update] pub async fn transaction_count(owner: Option, block: Option) -> Nat { let caller = validate_caller_not_anonymous(); From f677c40fca458a110fc96fd2ee27520c695f0be4 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Thu, 5 Sep 2024 10:40:02 +0200 Subject: [PATCH 03/35] CChanges to make clippy happy. --- rust/basic_ethereum/Cargo.lock | 1 + rust/basic_ethereum/src/lib.rs | 39 ++++++++++++++++++++-------------- 2 files changed, 24 insertions(+), 16 deletions(-) diff --git a/rust/basic_ethereum/Cargo.lock b/rust/basic_ethereum/Cargo.lock index 7cc70636f..bcbdd30d8 100644 --- a/rust/basic_ethereum/Cargo.lock +++ b/rust/basic_ethereum/Cargo.lock @@ -348,6 +348,7 @@ dependencies = [ "num-traits", "serde", "serde_bytes", + "serde_json", ] [[package]] diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 66202e6c7..106bf3ef4 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -8,8 +8,8 @@ use alloy_consensus::{SignableTransaction, TxEip1559, TxEnvelope}; use alloy_primitives::{hex, Signature, TxKind, U256}; use candid::{CandidType, Deserialize, Nat, Principal}; use evm_rpc_canister_types::{ - BlockTag, EvmRpcCanister, GetTransactionCountArgs, GetTransactionCountResult, - MultiGetTransactionCountResult, EthSepoliaService, RpcService, RequestResult + BlockTag, EthSepoliaService, EvmRpcCanister, GetTransactionCountArgs, + GetTransactionCountResult, MultiGetTransactionCountResult, RequestResult, RpcService, }; use ic_cdk::api::management_canister::ecdsa::{EcdsaCurve, EcdsaKeyId}; use ic_cdk::{init, update}; @@ -45,8 +45,17 @@ struct Balance { pub async fn get_balance(address: String) -> Nat { let _caller = validate_caller_not_anonymous(); let chain_id = read_state(|s| s.ethereum_network().chain_id()); - let json = format!(r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": {} }}"#, address, chain_id); - let (response,) = EVM_RPC.request(RpcService::EthSepolia(EthSepoliaService::PublicNode), json, 500u64, 1_000_000_000u128) + let json = format!( + r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": {} }}"#, + address, chain_id + ); + let (response,) = EVM_RPC + .request( + RpcService::EthSepolia(EthSepoliaService::PublicNode), + json, + 500u64, + 1_000_000_000u128, + ) .await .unwrap_or_else(|e| { panic!( @@ -56,23 +65,21 @@ pub async fn get_balance(address: String) -> Nat { }); match response { RequestResult::Ok(balance_result) => { - let balance_result : Result = serde_json::from_str(&balance_result); + let balance_result: Result = serde_json::from_str(&balance_result); let balance_string = balance_result - .unwrap_or_else(|e| { - panic!( - "failed to get parse get_balance, error: {:?}", - e - ) - }); + .unwrap_or_else(|e| panic!("failed to get parse get_balance, error: {:?}", e)); if balance_string.result.len() % 2 == 0 { - u64::from_str_radix(&balance_string.result[2..], 16).unwrap().into() + u64::from_str_radix(&balance_string.result[2..], 16) + .unwrap() + .into() } else { - u64::from_str_radix(&format!("0{}", &balance_string.result[2..]), 16).unwrap().into() + u64::from_str_radix(&format!("0{}", &balance_string.result[2..]), 16) + .unwrap() + .into() } - }, - RequestResult::Err(_) => panic!("Say something here.") + } + RequestResult::Err(_) => panic!("Say something here."), } - } #[update] From 12d0cecb9fc42db9748e9dab600c18bfa65447bf Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Thu, 5 Sep 2024 10:45:07 +0200 Subject: [PATCH 04/35] AAdded an error message. --- rust/basic_ethereum/src/lib.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 106bf3ef4..47600f901 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -59,7 +59,7 @@ pub async fn get_balance(address: String) -> Nat { .await .unwrap_or_else(|e| { panic!( - "failed to get the balance of address {:?}, error: {:?}", + "Failed to get the balance of address {:?}, error: {:?}", address, e ) }); @@ -67,7 +67,7 @@ pub async fn get_balance(address: String) -> Nat { RequestResult::Ok(balance_result) => { let balance_result: Result = serde_json::from_str(&balance_result); let balance_string = balance_result - .unwrap_or_else(|e| panic!("failed to get parse get_balance, error: {:?}", e)); + .unwrap_or_else(|e| panic!("Failed to get parse get_balance, error: {:?}", e)); if balance_string.result.len() % 2 == 0 { u64::from_str_radix(&balance_string.result[2..], 16) .unwrap() @@ -78,7 +78,7 @@ pub async fn get_balance(address: String) -> Nat { .into() } } - RequestResult::Err(_) => panic!("Say something here."), + RequestResult::Err(e) => panic!("Received an error response: {:?}", e), } } From 5ab30ca3c06e37674d04c95e3a64a9677558105b Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Thu, 5 Sep 2024 10:48:05 +0200 Subject: [PATCH 05/35] FFixed another error message. --- rust/basic_ethereum/src/lib.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 47600f901..e02d90cdc 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -66,8 +66,9 @@ pub async fn get_balance(address: String) -> Nat { match response { RequestResult::Ok(balance_result) => { let balance_result: Result = serde_json::from_str(&balance_result); - let balance_string = balance_result - .unwrap_or_else(|e| panic!("Failed to get parse get_balance, error: {:?}", e)); + let balance_string = balance_result.unwrap_or_else(|e| { + panic!("Failed to decode the eth_getBalance response: {:?}", e) + }); if balance_string.result.len() % 2 == 0 { u64::from_str_radix(&balance_string.result[2..], 16) .unwrap() From a0fbe753b5b6047f5c65f71210620fb5717ed26e Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Thu, 5 Sep 2024 13:51:15 +0200 Subject: [PATCH 06/35] Improved the get_balance implementation. --- rust/basic_ethereum/src/lib.rs | 45 ++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 21 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index e02d90cdc..6299f7af4 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -15,7 +15,6 @@ use ic_cdk::api::management_canister::ecdsa::{EcdsaCurve, EcdsaKeyId}; use ic_cdk::{init, update}; use ic_ethereum_types::Address; use std::str::FromStr; -use std::u64; pub const EVM_RPC_CANISTER_ID: Principal = Principal::from_slice(b"\x00\x00\x00\x00\x02\x30\x00\xCC\x01\x01"); // 7hfb6-caaaa-aaaar-qadga-cai @@ -37,8 +36,17 @@ pub async fn ethereum_address(owner: Option) -> String { } #[derive(Debug, Deserialize)] -struct Balance { - result: String, +#[allow(dead_code)] +struct JsonRpcResult { + result: Option, + error: Option, +} + +#[derive(Debug, Deserialize)] +#[allow(dead_code)] +struct JsonRpcError { + code: isize, + message: String, } #[update] @@ -57,27 +65,22 @@ pub async fn get_balance(address: String) -> Nat { 1_000_000_000u128, ) .await - .unwrap_or_else(|e| { - panic!( - "Failed to get the balance of address {:?}, error: {:?}", - address, e - ) - }); + .expect("RPC call failed"); + match response { RequestResult::Ok(balance_result) => { - let balance_result: Result = serde_json::from_str(&balance_result); - let balance_string = balance_result.unwrap_or_else(|e| { - panic!("Failed to decode the eth_getBalance response: {:?}", e) - }); - if balance_string.result.len() % 2 == 0 { - u64::from_str_radix(&balance_string.result[2..], 16) - .unwrap() - .into() + let json_rpc_result: JsonRpcResult = + serde_json::from_str(&balance_result).expect("JSON is not well-formatted"); + // The response to a successful `eth_getBalance` call has the format + // { "id": "[CHAIN ID]", "jsonrpc": "2.0", "result": "[BALANCE IN HEX]" } + let hex_balance = json_rpc_result.result.expect("No balance received"); + + let hex_balance = if hex_balance.len() % 2 != 0 { + format!("0{}", &hex_balance[2..]) } else { - u64::from_str_radix(&format!("0{}", &balance_string.result[2..]), 16) - .unwrap() - .into() - } + hex_balance[2..].to_string() + }; + Nat::from_str(&U256::from_str_radix(&hex_balance, 16).unwrap().to_string()).unwrap() } RequestResult::Err(e) => panic!("Received an error response: {:?}", e), } From 35f4e12a6057d6806d7edf5b71a99fec312b9856 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 14:13:48 +0200 Subject: [PATCH 07/35] Improvements to the get_balance endpoint. --- rust/basic_ethereum/Cargo.lock | 35 ++++++++++++++++++++++++++++++++++ rust/basic_ethereum/Cargo.toml | 3 ++- rust/basic_ethereum/src/lib.rs | 33 +++++++++++++++++++++----------- 3 files changed, 59 insertions(+), 12 deletions(-) diff --git a/rust/basic_ethereum/Cargo.lock b/rust/basic_ethereum/Cargo.lock index bcbdd30d8..568c2be1a 100644 --- a/rust/basic_ethereum/Cargo.lock +++ b/rust/basic_ethereum/Cargo.lock @@ -345,6 +345,7 @@ dependencies = [ "ic-crypto-extended-bip32", "ic-crypto-sha3", "ic-ethereum-types", + "num", "num-traits", "serde", "serde_bytes", @@ -2079,6 +2080,20 @@ version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" +[[package]] +name = "num" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35bd024e8b2ff75562e5f34e7f4905839deb4b22955ef5e73d2fea1b9813cb23" +dependencies = [ + "num-bigint", + "num-complex", + "num-integer", + "num-iter", + "num-rational", + "num-traits", +] + [[package]] name = "num-bigint" version = "0.4.6" @@ -2107,6 +2122,15 @@ dependencies = [ "smallvec", ] +[[package]] +name = "num-complex" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495" +dependencies = [ + "num-traits", +] + [[package]] name = "num-conv" version = "0.1.0" @@ -2133,6 +2157,17 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-rational" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824" +dependencies = [ + "num-bigint", + "num-integer", + "num-traits", +] + [[package]] name = "num-traits" version = "0.2.19" diff --git a/rust/basic_ethereum/Cargo.toml b/rust/basic_ethereum/Cargo.toml index 6f4fb1432..86db41dbc 100644 --- a/rust/basic_ethereum/Cargo.toml +++ b/rust/basic_ethereum/Cargo.toml @@ -23,4 +23,5 @@ ic-ethereum-types = { git = "https://github.com/dfinity/ic", tag = "release-2024 serde = "1.0" serde_json = "1.0" serde_bytes = "0.11.15" -num-traits = "0.2.19" \ No newline at end of file +num-traits = "0.2.19" +num = "0.4.3" \ No newline at end of file diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 6299f7af4..20a9a10c8 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -8,14 +8,18 @@ use alloy_consensus::{SignableTransaction, TxEip1559, TxEnvelope}; use alloy_primitives::{hex, Signature, TxKind, U256}; use candid::{CandidType, Deserialize, Nat, Principal}; use evm_rpc_canister_types::{ - BlockTag, EthSepoliaService, EvmRpcCanister, GetTransactionCountArgs, + BlockTag, EthMainnetService, EthSepoliaService, EvmRpcCanister, GetTransactionCountArgs, GetTransactionCountResult, MultiGetTransactionCountResult, RequestResult, RpcService, }; use ic_cdk::api::management_canister::ecdsa::{EcdsaCurve, EcdsaKeyId}; use ic_cdk::{init, update}; use ic_ethereum_types::Address; +use num::{BigUint, Num}; use std::str::FromStr; +pub const ETH_MAINNET_CHAIN_ID: u64 = 1; +pub const ETH_SEPOLIA_CHAIN_ID: u64 = 11155111; + pub const EVM_RPC_CANISTER_ID: Principal = Principal::from_slice(b"\x00\x00\x00\x00\x02\x30\x00\xCC\x01\x01"); // 7hfb6-caaaa-aaaar-qadga-cai pub const EVM_RPC: EvmRpcCanister = EvmRpcCanister(EVM_RPC_CANISTER_ID); @@ -52,18 +56,24 @@ struct JsonRpcError { #[update] pub async fn get_balance(address: String) -> Nat { let _caller = validate_caller_not_anonymous(); - let chain_id = read_state(|s| s.ethereum_network().chain_id()); let json = format!( - r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": {} }}"#, - address, chain_id + r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": 1 }}"#, + address ); + + let max_response_size_bytes = 500_u64; + let num_cycles = 1_000_000_000u128; + + let chain_id = read_state(|s| s.ethereum_network().chain_id()); + + let rpc_service = match chain_id { + ETH_MAINNET_CHAIN_ID => RpcService::EthMainnet(EthMainnetService::PublicNode), + ETH_SEPOLIA_CHAIN_ID => RpcService::EthSepolia(EthSepoliaService::PublicNode), + _ => panic!("Unsupported chain ID in get_balance call."), + }; + let (response,) = EVM_RPC - .request( - RpcService::EthSepolia(EthSepoliaService::PublicNode), - json, - 500u64, - 1_000_000_000u128, - ) + .request(rpc_service, json, max_response_size_bytes, num_cycles) .await .expect("RPC call failed"); @@ -75,12 +85,13 @@ pub async fn get_balance(address: String) -> Nat { // { "id": "[CHAIN ID]", "jsonrpc": "2.0", "result": "[BALANCE IN HEX]" } let hex_balance = json_rpc_result.result.expect("No balance received"); + // Make sure that the number of digits is even and remove the "0x" prefix. let hex_balance = if hex_balance.len() % 2 != 0 { format!("0{}", &hex_balance[2..]) } else { hex_balance[2..].to_string() }; - Nat::from_str(&U256::from_str_radix(&hex_balance, 16).unwrap().to_string()).unwrap() + Nat(BigUint::from_str_radix(&hex_balance, 16).unwrap()) } RequestResult::Err(e) => panic!("Received an error response: {:?}", e), } From d4909140ab3e1e6cf6636a49e216f868a317f708 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 14:19:32 +0200 Subject: [PATCH 08/35] Added a new line to the Cargo.toml file. --- rust/basic_ethereum/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rust/basic_ethereum/Cargo.toml b/rust/basic_ethereum/Cargo.toml index 86db41dbc..b4b2591a4 100644 --- a/rust/basic_ethereum/Cargo.toml +++ b/rust/basic_ethereum/Cargo.toml @@ -24,4 +24,4 @@ serde = "1.0" serde_json = "1.0" serde_bytes = "0.11.15" num-traits = "0.2.19" -num = "0.4.3" \ No newline at end of file +num = "0.4.3" From 142b2330f09c6583823296415369cf728ee48a2f Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 14:35:38 +0200 Subject: [PATCH 09/35] Update rust/basic_ethereum/src/lib.rs Co-authored-by: gregorydemay <112856886+gregorydemay@users.noreply.github.com> --- rust/basic_ethereum/src/lib.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 20a9a10c8..40c565ef4 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -64,12 +64,11 @@ pub async fn get_balance(address: String) -> Nat { let max_response_size_bytes = 500_u64; let num_cycles = 1_000_000_000u128; - let chain_id = read_state(|s| s.ethereum_network().chain_id()); + let ethereum_network = read_state(|s| s.ethereum_network()); - let rpc_service = match chain_id { - ETH_MAINNET_CHAIN_ID => RpcService::EthMainnet(EthMainnetService::PublicNode), - ETH_SEPOLIA_CHAIN_ID => RpcService::EthSepolia(EthSepoliaService::PublicNode), - _ => panic!("Unsupported chain ID in get_balance call."), + let rpc_service = match ethereum_network { + EthereumNetwork::Mainnet => RpcService::EthMainnet(EthMainnetService::PublicNode), + EthereumNetwork::Sepolia => RpcService::EthSepolia(EthSepoliaService::PublicNode), }; let (response,) = EVM_RPC From 338c2d19670a413aae4d63a457c14122fe68074d Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 14:35:46 +0200 Subject: [PATCH 10/35] Update rust/basic_ethereum/src/lib.rs Co-authored-by: gregorydemay <112856886+gregorydemay@users.noreply.github.com> --- rust/basic_ethereum/src/lib.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 40c565ef4..12812fa9b 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -17,8 +17,6 @@ use ic_ethereum_types::Address; use num::{BigUint, Num}; use std::str::FromStr; -pub const ETH_MAINNET_CHAIN_ID: u64 = 1; -pub const ETH_SEPOLIA_CHAIN_ID: u64 = 11155111; pub const EVM_RPC_CANISTER_ID: Principal = Principal::from_slice(b"\x00\x00\x00\x00\x02\x30\x00\xCC\x01\x01"); // 7hfb6-caaaa-aaaar-qadga-cai From 6a7de3474faa679faae55e12ef05594692b95102 Mon Sep 17 00:00:00 2001 From: Oleksandr Tkachenko Date: Mon, 9 Sep 2024 14:49:45 +0200 Subject: [PATCH 11/35] . --- .github/CODEOWNERS | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 898752273..636f03085 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -22,8 +22,8 @@ /motoko/defi/ @dfinity/networking /motoko/dip721-nft-container/ @dfinity/languages /motoko/echo/ @dfinity/languages -/motoko/encrypted-notes-dapp-vetkd/ @dfinity/dept-crypto-library -/motoko/encrypted-notes-dapp/ @dfinity/dept-crypto-library +/motoko/encrypted-notes-dapp-vetkd/ @dfinity/crypto-team +/motoko/encrypted-notes-dapp/ @dfinity/crypto-team /motoko/factorial/ @dfinity/languages /motoko/hello-world/ @dfinity/languages /motoko/hello/ @dfinity/languages @@ -47,11 +47,11 @@ /motoko/send_http_post/ @dfinity/networking /motoko/simple-to-do/ @dfinity/growth /motoko/superheroes/ @dfinity/growth -/motoko/threshold-ecdsa/ @dfinity/dept-crypto-library -/motoko/threshold-schnorr/ @dfinity/dept-crypto-library +/motoko/threshold-ecdsa/ @dfinity/crypto-team +/motoko/threshold-schnorr/ @dfinity/crypto-team /motoko/token_transfer/ @dfinity/growth /motoko/token_transfer_from/ @dfinity/growth -/motoko/vetkd/ @dfinity/dept-crypto-library +/motoko/vetkd/ @dfinity/crypto-team /motoko/whoami/ @dfinity/growth /native-apps/unity_ii_applink/ @dfinity/sdk @@ -67,8 +67,8 @@ /rust/counter/ @dfinity/growth /rust/defi/ @dfinity/div-Crypto /rust/dip721-nft-container/ @dfinity/sdk -/rust/encrypted-notes-dapp-vetkd/ @dfinity/dept-crypto-library -/rust/encrypted-notes-dapp/ @dfinity/dept-crypto-library +/rust/encrypted-notes-dapp-vetkd/ @dfinity/crypto-team +/rust/encrypted-notes-dapp/ @dfinity/crypto-team /rust/face-recognition/ @dfinity/execution /rust/guards/ @dfinity/cross-chain-team /rust/hello/ @dfinity/sdk @@ -84,11 +84,11 @@ /rust/send_http_get/ @dfinity/growth /rust/send_http_post/ @dfinity/growth /rust/simd/ @dfinity/execution -/rust/threshold-ecdsa/ @dfinity/dept-crypto-library -/rust/threshold-schnorr/ @dfinity/dept-crypto-library +/rust/threshold-ecdsa/ @dfinity/crypto-team +/rust/threshold-schnorr/ @dfinity/crypto-team /rust/token_transfer/ @dfinity/growth /rust/token_transfer_from/ @dfinity/growth -/rust/vetkd/ @dfinity/dept-crypto-library +/rust/vetkd/ @dfinity/crypto-team /svelte/svelte-motoko-starter/ @dfinity/sdk /svelte/svelte-starter/ @dfinity/sdk From e2382e7ce0bba7bf2014cc8ccd202df8c0b2158a Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 16:36:56 +0200 Subject: [PATCH 12/35] Cleaned up the get_balance endpoint. --- rust/basic_ethereum/src/lib.rs | 47 +++++++++++++--------------------- 1 file changed, 18 insertions(+), 29 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 12812fa9b..b7280caf3 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -17,7 +17,6 @@ use ic_ethereum_types::Address; use num::{BigUint, Num}; use std::str::FromStr; - pub const EVM_RPC_CANISTER_ID: Principal = Principal::from_slice(b"\x00\x00\x00\x00\x02\x30\x00\xCC\x01\x01"); // 7hfb6-caaaa-aaaar-qadga-cai pub const EVM_RPC: EvmRpcCanister = EvmRpcCanister(EVM_RPC_CANISTER_ID); @@ -37,20 +36,6 @@ pub async fn ethereum_address(owner: Option) -> String { wallet.ethereum_address().to_string() } -#[derive(Debug, Deserialize)] -#[allow(dead_code)] -struct JsonRpcResult { - result: Option, - error: Option, -} - -#[derive(Debug, Deserialize)] -#[allow(dead_code)] -struct JsonRpcError { - code: isize, - message: String, -} - #[update] pub async fn get_balance(address: String) -> Nat { let _caller = validate_caller_not_anonymous(); @@ -74,24 +59,28 @@ pub async fn get_balance(address: String) -> Nat { .await .expect("RPC call failed"); - match response { + let hex_balance = match response { RequestResult::Ok(balance_result) => { - let json_rpc_result: JsonRpcResult = - serde_json::from_str(&balance_result).expect("JSON is not well-formatted"); // The response to a successful `eth_getBalance` call has the format - // { "id": "[CHAIN ID]", "jsonrpc": "2.0", "result": "[BALANCE IN HEX]" } - let hex_balance = json_rpc_result.result.expect("No balance received"); - - // Make sure that the number of digits is even and remove the "0x" prefix. - let hex_balance = if hex_balance.len() % 2 != 0 { - format!("0{}", &hex_balance[2..]) - } else { - hex_balance[2..].to_string() - }; - Nat(BigUint::from_str_radix(&hex_balance, 16).unwrap()) + // { "id": "[ID]", "jsonrpc": "2.0", "result": "[BALANCE IN HEX]" } + let response: serde_json::Value = serde_json::from_str(&balance_result).unwrap(); + response + .get("result") + .and_then(|v| v.as_str()) + .unwrap() + .to_string() } RequestResult::Err(e) => panic!("Received an error response: {:?}", e), - } + }; + + // Make sure that the number of digits is even and remove the "0x" prefix. + let hex_balance = if hex_balance.len() % 2 != 0 { + format!("0{}", &hex_balance[2..]) + } else { + hex_balance[2..].to_string() + }; + + Nat(BigUint::from_str_radix(&hex_balance, 16).unwrap()) } #[update] From 148ba4e83d9b46b95fe1901716afedc9f355f1c2 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Mon, 9 Sep 2024 16:51:43 +0200 Subject: [PATCH 13/35] Removed the unnecessary size check of the hexadecimal balance. --- rust/basic_ethereum/src/lib.rs | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index b7280caf3..34f6484cd 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -61,7 +61,7 @@ pub async fn get_balance(address: String) -> Nat { let hex_balance = match response { RequestResult::Ok(balance_result) => { - // The response to a successful `eth_getBalance` call has the format + // The response to a successful `eth_getBalance` call has the following format: // { "id": "[ID]", "jsonrpc": "2.0", "result": "[BALANCE IN HEX]" } let response: serde_json::Value = serde_json::from_str(&balance_result).unwrap(); response @@ -73,14 +73,8 @@ pub async fn get_balance(address: String) -> Nat { RequestResult::Err(e) => panic!("Received an error response: {:?}", e), }; - // Make sure that the number of digits is even and remove the "0x" prefix. - let hex_balance = if hex_balance.len() % 2 != 0 { - format!("0{}", &hex_balance[2..]) - } else { - hex_balance[2..].to_string() - }; - - Nat(BigUint::from_str_radix(&hex_balance, 16).unwrap()) + // Remove the "0x" prefix before converting to a decimal number. + Nat(BigUint::from_str_radix(&hex_balance[2..], 16).unwrap()) } #[update] From 0110795dc0282920720c1208299762bd684d7ded Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Tue, 10 Sep 2024 15:35:02 +0200 Subject: [PATCH 14/35] Switched from Ankr to PublicNode as the single EVM RPC service. --- rust/basic_ethereum/src/state.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rust/basic_ethereum/src/state.rs b/rust/basic_ethereum/src/state.rs index 897dbc61d..73efb8e35 100644 --- a/rust/basic_ethereum/src/state.rs +++ b/rust/basic_ethereum/src/state.rs @@ -50,10 +50,10 @@ impl State { pub fn single_evm_rpc_service(&self) -> RpcServices { match self.ethereum_network { EthereumNetwork::Mainnet => { - RpcServices::EthMainnet(Some(vec![EthMainnetService::Ankr])) + RpcServices::EthMainnet(Some(vec![EthMainnetService::PublicNode])) } EthereumNetwork::Sepolia => { - RpcServices::EthSepolia(Some(vec![EthSepoliaService::Ankr])) + RpcServices::EthSepolia(Some(vec![EthSepoliaService::PublicNode])) } } } From 3f75b518897adb8478e651371df60db43f350130 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Tue, 10 Sep 2024 19:52:51 +0200 Subject: [PATCH 15/35] Made the address parameter of get_balance optional. --- rust/basic_ethereum/basic_ethereum.did | 4 ++-- rust/basic_ethereum/src/lib.rs | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/rust/basic_ethereum/basic_ethereum.did b/rust/basic_ethereum/basic_ethereum.did index c704e4174..a04443789 100644 --- a/rust/basic_ethereum/basic_ethereum.did +++ b/rust/basic_ethereum/basic_ethereum.did @@ -9,7 +9,6 @@ type InitArg = record { type EthereumNetwork = variant { // The public Ethereum mainnet. Mainnet; - // The public Ethereum Sepolia testnet. Sepolia; }; @@ -43,7 +42,8 @@ service : (opt InitArg) -> { ethereum_address : (owner: opt principal) -> (text); // Returns the balance of the given Ethereum address. - get_balance : (address: text) -> (Wei); + // If no address is provided, the address derived from the caller's principal is used. + get_balance : (address: opt text) -> (Wei); // Returns the transaction count for the Ethereum address derived for the given principal. // diff --git a/rust/basic_ethereum/src/lib.rs b/rust/basic_ethereum/src/lib.rs index 34f6484cd..82473c33e 100644 --- a/rust/basic_ethereum/src/lib.rs +++ b/rust/basic_ethereum/src/lib.rs @@ -37,8 +37,9 @@ pub async fn ethereum_address(owner: Option) -> String { } #[update] -pub async fn get_balance(address: String) -> Nat { - let _caller = validate_caller_not_anonymous(); +pub async fn get_balance(address: Option) -> Nat { + let address = address.unwrap_or(ethereum_address(None).await); + let json = format!( r#"{{ "jsonrpc": "2.0", "method": "eth_getBalance", "params": ["{}", "latest"], "id": 1 }}"#, address From c291902cf7ed118ec068ecad269f62f842d4dd89 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 11:31:59 -0700 Subject: [PATCH 16/35] Bump micromatch from 4.0.4 to 4.0.8 in /rust/nft-wallet/frontend (#963) Bumps [micromatch](https://github.com/micromatch/micromatch) from 4.0.4 to 4.0.8. - [Release notes](https://github.com/micromatch/micromatch/releases) - [Changelog](https://github.com/micromatch/micromatch/blob/master/CHANGELOG.md) - [Commits](https://github.com/micromatch/micromatch/compare/4.0.4...4.0.8) --- updated-dependencies: - dependency-name: micromatch dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- rust/nft-wallet/frontend/package-lock.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/rust/nft-wallet/frontend/package-lock.json b/rust/nft-wallet/frontend/package-lock.json index 180f7c829..ed08338ae 100644 --- a/rust/nft-wallet/frontend/package-lock.json +++ b/rust/nft-wallet/frontend/package-lock.json @@ -6370,12 +6370,12 @@ } }, "node_modules/micromatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.4.tgz", - "integrity": "sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg==", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dependencies": { - "braces": "^3.0.1", - "picomatch": "^2.2.3" + "braces": "^3.0.3", + "picomatch": "^2.3.1" }, "engines": { "node": ">=8.6" @@ -6716,9 +6716,9 @@ "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==" }, "node_modules/picomatch": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", - "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "engines": { "node": ">=8.6" }, From 1aff54722aed35e54899bef75ab877a511a9c529 Mon Sep 17 00:00:00 2001 From: Kai Peacock Date: Mon, 16 Sep 2024 11:32:11 -0700 Subject: [PATCH 17/35] chore: promote dfx 0.23.0 (#969) * chore: promote dfx 0.23.0 * Update provision-linux.sh * chore: bump dfx version linux --- .github/workflows/provision-darwin.sh | 2 +- .github/workflows/provision-linux.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/provision-darwin.sh b/.github/workflows/provision-darwin.sh index 9279b0eb2..8db740abf 100755 --- a/.github/workflows/provision-darwin.sh +++ b/.github/workflows/provision-darwin.sh @@ -18,7 +18,7 @@ rm node.pkg # Install DFINITY SDK. curl --location --output install-dfx.sh "https://raw.githubusercontent.com/dfinity/sdk/master/public/install-dfxvm.sh" -DFX_VERSION=${DFX_VERSION:=0.22.0} DFXVM_INIT_YES=true bash install-dfx.sh +DFX_VERSION=${DFX_VERSION:=0.23.0} DFXVM_INIT_YES=true bash install-dfx.sh rm install-dfx.sh echo "$HOME/Library/Application Support/org.dfinity.dfx/bin" >> $GITHUB_PATH source "$HOME/Library/Application Support/org.dfinity.dfx/env" diff --git a/.github/workflows/provision-linux.sh b/.github/workflows/provision-linux.sh index e422cbaa4..2b0b4851d 100755 --- a/.github/workflows/provision-linux.sh +++ b/.github/workflows/provision-linux.sh @@ -13,7 +13,7 @@ rm install-node.sh # Install DFINITY SDK. wget --output-document install-dfx.sh "https://raw.githubusercontent.com/dfinity/sdk/master/public/install-dfxvm.sh" -DFX_VERSION=${DFX_VERSION:=0.22.0} DFXVM_INIT_YES=true bash install-dfx.sh +DFX_VERSION=${DFX_VERSION:=0.23.0} DFXVM_INIT_YES=true bash install-dfx.sh rm install-dfx.sh echo "$HOME/.local/share/dfx/bin" >> $GITHUB_PATH source "$HOME/.local/share/dfx/env" From d223d3052eb14c0a751affe6ee608aacc1e4115c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 11:32:59 -0700 Subject: [PATCH 18/35] Bump webpack from 5.86.0 to 5.94.0 in /motoko/vetkd (#959) Bumps [webpack](https://github.com/webpack/webpack) from 5.86.0 to 5.94.0. - [Release notes](https://github.com/webpack/webpack/releases) - [Commits](https://github.com/webpack/webpack/compare/v5.86.0...v5.94.0) --- updated-dependencies: - dependency-name: webpack dependency-type: direct:development ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- motoko/vetkd/package-lock.json | 245 +++++++++++++++------------------ motoko/vetkd/package.json | 2 +- 2 files changed, 110 insertions(+), 137 deletions(-) diff --git a/motoko/vetkd/package-lock.json b/motoko/vetkd/package-lock.json index ca84f92b9..b0c635cf0 100644 --- a/motoko/vetkd/package-lock.json +++ b/motoko/vetkd/package-lock.json @@ -25,7 +25,7 @@ "stream-browserify": "3.0.0", "terser-webpack-plugin": "^5.3.3", "util": "0.12.4", - "webpack": "^5.73.0", + "webpack": "^5.94.0", "webpack-cli": "^4.10.0", "webpack-dev-server": "^4.8.1" }, @@ -163,21 +163,15 @@ "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==" }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.18", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz", - "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "dependencies": { - "@jridgewell/resolve-uri": "3.1.0", - "@jridgewell/sourcemap-codec": "1.4.14" + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "node_modules/@jridgewell/trace-mapping/node_modules/@jridgewell/sourcemap-codec": { - "version": "1.4.14", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", - "dev": true - }, "node_modules/@leichtgewicht/ip-codec": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz", @@ -316,30 +310,10 @@ "@types/node": "*" } }, - "node_modules/@types/eslint": { - "version": "8.40.1", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.40.1.tgz", - "integrity": "sha512-vRb792M4mF1FBT+eoLecmkpLXwxsBHvWWRGJjzbYANBM6DtiJc6yETyv4rqDA6QNjF1pkj1U7LMA6dGb3VYlHw==", - "dev": true, - "dependencies": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "node_modules/@types/eslint-scope": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz", - "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==", - "dev": true, - "dependencies": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "node_modules/@types/estree": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.1.tgz", - "integrity": "sha512-LG4opVs2ANWZ1TJoKc937iMmNstM/d0ae1vNbnBvBhqCSezgVUOzcLCqbI5elV8Vy6WKwKjaqR+zO9VKirBBCA==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true }, "node_modules/@types/express": { @@ -464,9 +438,9 @@ } }, "node_modules/@webassemblyjs/ast": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.6.tgz", - "integrity": "sha512-IN1xI7PwOvLPgjcf180gC1bqn3q/QaOCwYUahIOhbYUu8KA/3tw2RT/T0Gidi1l7Hhj5D/INhJxiICObqpMu4Q==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "dependencies": { "@webassemblyjs/helper-numbers": "1.11.6", @@ -486,9 +460,9 @@ "dev": true }, "node_modules/@webassemblyjs/helper-buffer": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.6.tgz", - "integrity": "sha512-z3nFzdcp1mb8nEOFFk8DrYLpHvhKC3grJD2ardfKOzmbmJvEf/tPIqCY+sNcwZIY8ZD7IkB2l7/pqhUhqm7hLA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true }, "node_modules/@webassemblyjs/helper-numbers": { @@ -509,15 +483,15 @@ "dev": true }, "node_modules/@webassemblyjs/helper-wasm-section": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.6.tgz", - "integrity": "sha512-LPpZbSOwTpEC2cgn4hTydySy1Ke+XEu+ETXuoyvuyezHO3Kjdu90KK95Sh9xTbmjrCsUwvWwCOQQNta37VrS9g==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6" + "@webassemblyjs/wasm-gen": "1.12.1" } }, "node_modules/@webassemblyjs/ieee754": { @@ -545,28 +519,28 @@ "dev": true }, "node_modules/@webassemblyjs/wasm-edit": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.6.tgz", - "integrity": "sha512-Ybn2I6fnfIGuCR+Faaz7YcvtBKxvoLV3Lebn1tM4o/IAJzmi9AWYIPWpyBfU8cC+JxAO57bk4+zdsTjJR+VTOw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", - "@webassemblyjs/helper-wasm-section": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6", - "@webassemblyjs/wasm-opt": "1.11.6", - "@webassemblyjs/wasm-parser": "1.11.6", - "@webassemblyjs/wast-printer": "1.11.6" + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-gen": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.6.tgz", - "integrity": "sha512-3XOqkZP/y6B4F0PBAXvI1/bky7GryoogUtfwExeP/v7Nzwo1QLcq5oQmpKlftZLbT+ERUOAZVQjuNVak6UXjPA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", "@webassemblyjs/ieee754": "1.11.6", "@webassemblyjs/leb128": "1.11.6", @@ -574,24 +548,24 @@ } }, "node_modules/@webassemblyjs/wasm-opt": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.6.tgz", - "integrity": "sha512-cOrKuLRE7PCe6AsOVl7WasYf3wbSo4CeOk6PkrjS7g57MFfVUF9u6ysQBBODX0LdgSvQqRiGz3CXvIDKcPNy4g==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", - "@webassemblyjs/helper-buffer": "1.11.6", - "@webassemblyjs/wasm-gen": "1.11.6", - "@webassemblyjs/wasm-parser": "1.11.6" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-parser": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.6.tgz", - "integrity": "sha512-6ZwPeGzMJM3Dqp3hCsLgESxBGtT/OeCvCZ4TA1JUPYgmhAx38tTPR9JaKy0S5H3evQpO/h2uWs2j6Yc/fjkpTQ==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@webassemblyjs/helper-api-error": "1.11.6", "@webassemblyjs/helper-wasm-bytecode": "1.11.6", "@webassemblyjs/ieee754": "1.11.6", @@ -600,12 +574,12 @@ } }, "node_modules/@webassemblyjs/wast-printer": { - "version": "1.11.6", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.6.tgz", - "integrity": "sha512-JM7AhRcE+yW2GWYaKeHL5vt4xqee5N2WcezptmgyhNS+ScggqcT1OtXykhAb13Sn5Yas0j2uv9tHgrjwvzAP4A==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.6", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -681,10 +655,10 @@ "node": ">=0.4.0" } }, - "node_modules/acorn-import-assertions": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.9.0.tgz", - "integrity": "sha512-cmMwop9x+8KFhxvKrKfPYmN6/pKTYYHBqLa0DfvVZcKMJWNyWLnaqND7dx/qn66R7ewM1UX5XMaDVP5wlVTaVA==", + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "dev": true, "peerDependencies": { "acorn": "^8" @@ -997,9 +971,9 @@ } }, "node_modules/browserslist": { - "version": "4.21.7", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.7.tgz", - "integrity": "sha512-BauCXrQ7I2ftSqd2mvKHGo85XR0u7Ru3C/Hxsy/0TkfCtjrmAbPdzLGasmoiBxplpDXlPvdjX9u7srIMfgasNA==", + "version": "4.23.3", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.3.tgz", + "integrity": "sha512-btwCFJVjI4YWDNfau8RhZ+B1Q/VLoUITrm3RlP6y1tYGWIOa+InuYiRGXUBXo8nA1qKmHMyLB/iVQg5TT4eFoA==", "dev": true, "funding": [ { @@ -1016,10 +990,10 @@ } ], "dependencies": { - "caniuse-lite": "^1.0.30001489", - "electron-to-chromium": "^1.4.411", - "node-releases": "^2.0.12", - "update-browserslist-db": "^1.0.11" + "caniuse-lite": "^1.0.30001646", + "electron-to-chromium": "^1.5.4", + "node-releases": "^2.0.18", + "update-browserslist-db": "^1.1.0" }, "bin": { "browserslist": "cli.js" @@ -1097,9 +1071,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001502", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001502.tgz", - "integrity": "sha512-AZ+9tFXw1sS0o0jcpJQIXvFTOB/xGiQ4OQ2t98QX3NDn2EZTSRBC801gxrsGgViuq2ak/NLkNgSNEPtCr5lfKg==", + "version": "1.0.30001653", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001653.tgz", + "integrity": "sha512-XGWQVB8wFQ2+9NZwZ10GxTYC5hk0Fa+q8cSkr0tgvMhYhMHP/QC+WTgrePMDBWiWc/pV+1ik82Al20XOK25Gcw==", "dev": true, "funding": [ { @@ -1641,9 +1615,9 @@ "dev": true }, "node_modules/electron-to-chromium": { - "version": "1.4.427", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.427.tgz", - "integrity": "sha512-HK3r9l+Jm8dYAm1ctXEWIC+hV60zfcjS9UA5BDlYvnI5S7PU/yytjpvSrTNrSSRRkuu3tDyZhdkwIczh+0DWaw==", + "version": "1.5.13", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.13.tgz", + "integrity": "sha512-lbBcvtIJ4J6sS4tb5TLp1b4LyfCdMkwStzXPyAgVgTRAsep4bvrAGaBOP7ZJtQMNJpSQ9SqG4brWOroNaQtm7Q==", "dev": true }, "node_modules/encodeurl": { @@ -1656,9 +1630,9 @@ } }, "node_modules/enhanced-resolve": { - "version": "5.14.1", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.14.1.tgz", - "integrity": "sha512-Vklwq2vDKtl0y/vtwjSesgJ5MYS7Etuk5txS8VdKL4AOS1aUlD96zqIfsOSLQsdv3xgMRbtkWM8eG9XDfKUPow==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dev": true, "dependencies": { "graceful-fs": "^4.2.4", @@ -1714,9 +1688,9 @@ "dev": true }, "node_modules/escalade": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", + "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", "dev": true, "engines": { "node": ">=6" @@ -3083,9 +3057,9 @@ } }, "node_modules/node-releases": { - "version": "2.0.12", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.12.tgz", - "integrity": "sha512-QzsYKWhXTWx8h1kIvqfnC++o0pEmpRQA/aenALsL2F4pqNVr7YzcdMlDij5WBnwftRbJCNJL/O7zdKaxKPHqgQ==", + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.18.tgz", + "integrity": "sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g==", "dev": true }, "node_modules/normalize-path": { @@ -3338,9 +3312,9 @@ } }, "node_modules/picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", + "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==", "dev": true }, "node_modules/picomatch": { @@ -4173,9 +4147,9 @@ } }, "node_modules/terser": { - "version": "5.17.7", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.17.7.tgz", - "integrity": "sha512-/bi0Zm2C6VAexlGgLlVxA0P2lru/sdLyfCVaRMfKVo9nWxbmz7f/sD8VPybPeSUJaJcwmCJis9pBIhcVcG1QcQ==", + "version": "5.31.6", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz", + "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==", "dev": true, "dependencies": { "@jridgewell/source-map": "^0.3.3", @@ -4191,16 +4165,16 @@ } }, "node_modules/terser-webpack-plugin": { - "version": "5.3.9", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.9.tgz", - "integrity": "sha512-ZuXsqE07EcggTWQjXUj+Aot/OMcD0bMKGgF63f7UxYcu5/AJF53aIpK1YoP5xR9l6s/Hy2b+t1AM0bLNPRuhwA==", + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", "dev": true, "dependencies": { - "@jridgewell/trace-mapping": "^0.3.17", + "@jridgewell/trace-mapping": "^0.3.20", "jest-worker": "^27.4.5", "schema-utils": "^3.1.1", "serialize-javascript": "^6.0.1", - "terser": "^5.16.8" + "terser": "^5.26.0" }, "engines": { "node": ">= 10.13.0" @@ -4395,9 +4369,9 @@ } }, "node_modules/update-browserslist-db": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz", - "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.0.tgz", + "integrity": "sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ==", "dev": true, "funding": [ { @@ -4414,8 +4388,8 @@ } ], "dependencies": { - "escalade": "^3.1.1", - "picocolors": "^1.0.0" + "escalade": "^3.1.2", + "picocolors": "^1.0.1" }, "bin": { "update-browserslist-db": "cli.js" @@ -4507,9 +4481,9 @@ } }, "node_modules/watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "dependencies": { "glob-to-regexp": "^0.4.1", @@ -4542,34 +4516,33 @@ } }, "node_modules/webpack": { - "version": "5.86.0", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.86.0.tgz", - "integrity": "sha512-3BOvworZ8SO/D4GVP+GoRC3fVeg5MO4vzmq8TJJEkdmopxyazGDxN8ClqN12uzrZW9Tv8EED8v5VSb6Sqyi0pg==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dev": true, "dependencies": { - "@types/eslint-scope": "^3.7.3", - "@types/estree": "^1.0.0", - "@webassemblyjs/ast": "^1.11.5", - "@webassemblyjs/wasm-edit": "^1.11.5", - "@webassemblyjs/wasm-parser": "^1.11.5", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.9.0", - "browserslist": "^4.14.5", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.14.1", + "enhanced-resolve": "^5.17.1", "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", "neo-async": "^2.6.2", - "schema-utils": "^3.1.2", + "schema-utils": "^3.2.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.3.7", - "watchpack": "^2.4.0", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "bin": { diff --git a/motoko/vetkd/package.json b/motoko/vetkd/package.json index 66061dec9..2860b0d13 100644 --- a/motoko/vetkd/package.json +++ b/motoko/vetkd/package.json @@ -34,7 +34,7 @@ "stream-browserify": "3.0.0", "terser-webpack-plugin": "^5.3.3", "util": "0.12.4", - "webpack": "^5.73.0", + "webpack": "^5.94.0", "webpack-cli": "^4.10.0", "webpack-dev-server": "^4.8.1" }, From 80491218c514008722d04eb7c858bd39cb0599c1 Mon Sep 17 00:00:00 2001 From: mraszyk <31483726+mraszyk@users.noreply.github.com> Date: Mon, 16 Sep 2024 21:26:31 +0200 Subject: [PATCH 19/35] chore(rust/basic_bitcoin): release action (#976) * chore(rust/basic_bitcoin): release action * gzip * fix path * paths --- .../rust-basic-bitcoin-example-release.yml | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/rust-basic-bitcoin-example-release.yml diff --git a/.github/workflows/rust-basic-bitcoin-example-release.yml b/.github/workflows/rust-basic-bitcoin-example-release.yml new file mode 100644 index 000000000..4d534acb3 --- /dev/null +++ b/.github/workflows/rust-basic-bitcoin-example-release.yml @@ -0,0 +1,32 @@ +name: rust-basic-bitcoin-release +on: + push: + branches: + - master + pull_request: + paths: + - rust/basic_bitcoin/** + - .github/workflows/provision-linux.sh + - .github/workflows/rust-basic-bitcoin-example-release.yml + - .ic-commit +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true +jobs: + rust-basic-bitcoin-linux: + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v1 + - name: Provision Linux + run: bash .github/workflows/provision-linux.sh + - name: Rust Basic Bitcoin Linux + run: | + pushd rust/basic_bitcoin + bash src/basic_bitcoin/build.sh + cp target/wasm32-unknown-unknown/release/basic_bitcoin.wasm basic_bitcoin.wasm + gzip -9 basic_bitcoin.wasm + - uses: actions/upload-artifact@v4 + with: + name: "basic_bitcoin.wasm.gz" + path: "rust/basic_bitcoin/basic_bitcoin.wasm.gz" + compression-level: 0 From 2f8895fbca35d90577e1981e84b1174c1c019f89 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:32:47 -0700 Subject: [PATCH 20/35] Bump express from 4.19.2 to 4.21.0 in /motoko/vetkd (#980) Bumps [express](https://github.com/expressjs/express) from 4.19.2 to 4.21.0. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- motoko/vetkd/package-lock.json | 121 ++++++++++++++++++--------------- 1 file changed, 65 insertions(+), 56 deletions(-) diff --git a/motoko/vetkd/package-lock.json b/motoko/vetkd/package-lock.json index b0c635cf0..ca2df4584 100644 --- a/motoko/vetkd/package-lock.json +++ b/motoko/vetkd/package-lock.json @@ -839,9 +839,9 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "dependencies": { "bytes": "3.1.2", @@ -852,7 +852,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -1621,9 +1621,9 @@ "dev": true }, "node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "engines": { "node": ">= 0.8" @@ -1802,37 +1802,37 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -1849,12 +1849,6 @@ "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", "dev": true }, - "node_modules/express/node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "dev": true - }, "node_modules/fast-glob": { "version": "3.2.12", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.12.tgz", @@ -1932,13 +1926,13 @@ } }, "node_modules/finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "dependencies": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -2406,12 +2400,6 @@ "node": ">= 0.8" } }, - "node_modules/http-errors/node_modules/setprototypeof": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", - "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "dev": true - }, "node_modules/http-parser-js": { "version": "0.5.8", "resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz", @@ -2901,10 +2889,13 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", - "dev": true + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -3084,10 +3075,13 @@ } }, "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", "dev": true, + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -3297,9 +3291,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "node_modules/path-type": { @@ -3416,12 +3410,12 @@ } }, "node_modules/qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "dependencies": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" }, "engines": { "node": ">=0.6" @@ -3733,9 +3727,9 @@ "dev": true }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "dependencies": { "debug": "2.6.9", @@ -3756,6 +3750,15 @@ "node": ">= 0.8.0" } }, + "node_modules/send/node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/serialize-javascript": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.1.tgz", @@ -3829,15 +3832,15 @@ } }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "dependencies": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" }, "engines": { "node": ">= 0.8.0" @@ -3860,6 +3863,12 @@ "node": ">= 0.4" } }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "dev": true + }, "node_modules/shallow-clone": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz", From 05af06129b554344a122f85d0c2bfda4f1f9f450 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:33:03 -0700 Subject: [PATCH 21/35] Bump send and express in /rust/face-recognition (#979) Bumps [send](https://github.com/pillarjs/send) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `send` from 0.18.0 to 0.19.0 - [Release notes](https://github.com/pillarjs/send/releases) - [Changelog](https://github.com/pillarjs/send/blob/master/HISTORY.md) - [Commits](https://github.com/pillarjs/send/compare/0.18.0...0.19.0) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: send dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- rust/face-recognition/package-lock.json | 103 ++++++++++++++---------- 1 file changed, 59 insertions(+), 44 deletions(-) diff --git a/rust/face-recognition/package-lock.json b/rust/face-recognition/package-lock.json index 2f510456c..c90b8ff04 100644 --- a/rust/face-recognition/package-lock.json +++ b/rust/face-recognition/package-lock.json @@ -766,9 +766,9 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "dependencies": { "bytes": "3.1.2", @@ -779,7 +779,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -1465,9 +1465,9 @@ "dev": true }, "node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "engines": { "node": ">= 0.8" @@ -1646,37 +1646,37 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -1776,13 +1776,13 @@ } }, "node_modules/finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "dependencies": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -2723,10 +2723,13 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", - "dev": true + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -2918,10 +2921,13 @@ } }, "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", "dev": true, + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -3131,9 +3137,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "node_modules/path-type": { @@ -3232,12 +3238,12 @@ } }, "node_modules/qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "dependencies": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" }, "engines": { "node": ">=0.6" @@ -3541,9 +3547,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "dependencies": { "debug": "2.6.9", @@ -3564,6 +3570,15 @@ "node": ">= 0.8.0" } }, + "node_modules/send/node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/send/node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -3643,15 +3658,15 @@ } }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "dependencies": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" }, "engines": { "node": ">= 0.8.0" From f6191e18384ca283d320139e18a14b12cc4d7340 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:33:16 -0700 Subject: [PATCH 22/35] Bump body-parser and express in /rust/face-recognition (#978) Bumps [body-parser](https://github.com/expressjs/body-parser) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `body-parser` from 1.20.2 to 1.20.3 - [Release notes](https://github.com/expressjs/body-parser/releases) - [Changelog](https://github.com/expressjs/body-parser/blob/master/HISTORY.md) - [Commits](https://github.com/expressjs/body-parser/compare/1.20.2...1.20.3) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: body-parser dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> From 6dc8933fd19f4a7d561a22f62711930b09c456be Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:46:51 -0700 Subject: [PATCH 23/35] Bump send and express in /motoko/send_http_post (#982) Bumps [send](https://github.com/pillarjs/send) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `send` from 0.18.0 to 0.19.0 - [Release notes](https://github.com/pillarjs/send/releases) - [Changelog](https://github.com/pillarjs/send/blob/master/HISTORY.md) - [Commits](https://github.com/pillarjs/send/compare/0.18.0...0.19.0) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: send dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- motoko/send_http_post/package-lock.json | 195 +++++++++++++----------- 1 file changed, 108 insertions(+), 87 deletions(-) diff --git a/motoko/send_http_post/package-lock.json b/motoko/send_http_post/package-lock.json index eaa693bb9..559ba9e5a 100644 --- a/motoko/send_http_post/package-lock.json +++ b/motoko/send_http_post/package-lock.json @@ -808,9 +808,9 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "dependencies": { "bytes": "3.1.2", @@ -821,7 +821,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -1519,9 +1519,9 @@ "dev": true }, "node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "engines": { "node": ">= 0.8" @@ -1700,37 +1700,37 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -1830,13 +1830,13 @@ } }, "node_modules/finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "dependencies": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -2789,10 +2789,13 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", - "dev": true + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -2984,10 +2987,13 @@ } }, "node_modules/object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", "dev": true, + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -3197,9 +3203,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "node_modules/path-type": { @@ -3298,12 +3304,12 @@ } }, "node_modules/qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "dependencies": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" }, "engines": { "node": ">=0.6" @@ -3606,9 +3612,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "dependencies": { "debug": "2.6.9", @@ -3629,6 +3635,15 @@ "node": ">= 0.8.0" } }, + "node_modules/send/node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/send/node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -3708,15 +3723,15 @@ } }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "dependencies": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" }, "engines": { "node": ">= 0.8.0" @@ -5374,9 +5389,9 @@ "dev": true }, "body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "requires": { "bytes": "3.1.2", @@ -5387,7 +5402,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -5888,9 +5903,9 @@ "dev": true }, "encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true }, "enhanced-resolve": { @@ -6023,37 +6038,37 @@ } }, "express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -6139,13 +6154,13 @@ } }, "finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "requires": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -6816,9 +6831,9 @@ } }, "merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", "dev": true }, "merge-stream": { @@ -6966,9 +6981,9 @@ } }, "object-inspect": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.1.tgz", - "integrity": "sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", "dev": true }, "object-is": { @@ -7122,9 +7137,9 @@ "dev": true }, "path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "path-type": { @@ -7201,12 +7216,12 @@ "dev": true }, "qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "requires": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" } }, "queue-microtask": { @@ -7404,9 +7419,9 @@ } }, "send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "requires": { "debug": "2.6.9", @@ -7424,6 +7439,12 @@ "statuses": "2.0.1" }, "dependencies": { + "encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true + }, "ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -7495,15 +7516,15 @@ } }, "serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "requires": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" } }, "set-function-length": { From 959f8e6222d95e0b3ab2d59a38c661f9e2360989 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 13:47:05 -0700 Subject: [PATCH 24/35] Bump serve-static and express in /motoko/send_http_post (#981) Bumps [serve-static](https://github.com/expressjs/serve-static) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `serve-static` from 1.15.0 to 1.16.2 - [Release notes](https://github.com/expressjs/serve-static/releases) - [Changelog](https://github.com/expressjs/serve-static/blob/v1.16.2/HISTORY.md) - [Commits](https://github.com/expressjs/serve-static/compare/v1.15.0...v1.16.2) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: serve-static dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> From 995fa06a26a17804cb93677b5f0c1409c6835ea9 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Tue, 17 Sep 2024 13:38:15 +0200 Subject: [PATCH 25/35] Added a comment again that was removed accidentally. --- rust/basic_ethereum/basic_ethereum.did | 1 + 1 file changed, 1 insertion(+) diff --git a/rust/basic_ethereum/basic_ethereum.did b/rust/basic_ethereum/basic_ethereum.did index a04443789..ffee964d2 100644 --- a/rust/basic_ethereum/basic_ethereum.did +++ b/rust/basic_ethereum/basic_ethereum.did @@ -9,6 +9,7 @@ type InitArg = record { type EthereumNetwork = variant { // The public Ethereum mainnet. Mainnet; + // The public Sepolia testnet. Sepolia; }; From a13fdf94eca8f6f1e81b2b647ab242a74b39eab0 Mon Sep 17 00:00:00 2001 From: Thomas Locher Date: Tue, 17 Sep 2024 13:39:19 +0200 Subject: [PATCH 26/35] Fixed the comment. --- rust/basic_ethereum/basic_ethereum.did | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rust/basic_ethereum/basic_ethereum.did b/rust/basic_ethereum/basic_ethereum.did index ffee964d2..36ff95e4e 100644 --- a/rust/basic_ethereum/basic_ethereum.did +++ b/rust/basic_ethereum/basic_ethereum.did @@ -9,7 +9,7 @@ type InitArg = record { type EthereumNetwork = variant { // The public Ethereum mainnet. Mainnet; - // The public Sepolia testnet. + // The public Ethereum Sepolia testnet. Sepolia; }; From af51830bdfced38661b0b0d7c28ad572310d43e5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Sep 2024 09:33:03 -0700 Subject: [PATCH 27/35] Bump serve-static and express in /motoko/random_maze (#985) Bumps [serve-static](https://github.com/expressjs/serve-static) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `serve-static` from 1.15.0 to 1.16.2 - [Release notes](https://github.com/expressjs/serve-static/releases) - [Changelog](https://github.com/expressjs/serve-static/blob/v1.16.2/HISTORY.md) - [Commits](https://github.com/expressjs/serve-static/compare/v1.15.0...v1.16.2) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: serve-static dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- motoko/random_maze/package-lock.json | 180 +++++++++++++++------------ 1 file changed, 99 insertions(+), 81 deletions(-) diff --git a/motoko/random_maze/package-lock.json b/motoko/random_maze/package-lock.json index 722e209af..4ca03e56b 100644 --- a/motoko/random_maze/package-lock.json +++ b/motoko/random_maze/package-lock.json @@ -886,9 +886,9 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "dependencies": { "bytes": "3.1.2", @@ -899,7 +899,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -1720,9 +1720,9 @@ "dev": true }, "node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, "engines": { "node": ">= 0.8" @@ -1960,37 +1960,37 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -2120,13 +2120,13 @@ } }, "node_modules/finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "dependencies": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -3245,10 +3245,13 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=", - "dev": true + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "dev": true, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -3751,9 +3754,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "node_modules/path-type": { @@ -3972,12 +3975,12 @@ } }, "node_modules/qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "dependencies": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" }, "engines": { "node": ">=0.6" @@ -4342,9 +4345,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "dependencies": { "debug": "2.6.9", @@ -4389,6 +4392,15 @@ "node": ">= 0.8" } }, + "node_modules/send/node_modules/encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/send/node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -4474,15 +4486,15 @@ "dev": true }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "dependencies": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" }, "engines": { "node": ">= 0.8.0" @@ -6377,9 +6389,9 @@ "dev": true }, "body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dev": true, "requires": { "bytes": "3.1.2", @@ -6390,7 +6402,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -7014,9 +7026,9 @@ "dev": true }, "encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true }, "enhanced-resolve": { @@ -7193,37 +7205,37 @@ } }, "express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.21.0.tgz", + "integrity": "sha512-VqcNGcj/Id5ZT1LZ/cfihi3ttTn+NJmkli2eZADigjq29qTlWi/hAQ43t/VLPq8+UX06FCEx3ByOYet6ZFblng==", "dev": true, "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", - "finalhandler": "1.2.0", + "finalhandler": "1.3.1", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", - "qs": "6.11.0", + "qs": "6.13.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.2", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -7336,13 +7348,13 @@ } }, "finalhandler": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.2.0.tgz", - "integrity": "sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==", + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", + "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", "dev": true, "requires": { "debug": "2.6.9", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "on-finished": "2.4.1", "parseurl": "~1.3.3", @@ -8139,9 +8151,9 @@ } }, "merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", "dev": true }, "merge-stream": { @@ -8509,9 +8521,9 @@ "dev": true }, "path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=", + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", "dev": true }, "path-type": { @@ -8665,12 +8677,12 @@ "dev": true }, "qs": { - "version": "6.11.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.11.0.tgz", - "integrity": "sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==", + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", "dev": true, "requires": { - "side-channel": "^1.0.4" + "side-channel": "^1.0.6" } }, "queue-microtask": { @@ -8915,9 +8927,9 @@ } }, "send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dev": true, "requires": { "debug": "2.6.9", @@ -8958,6 +8970,12 @@ "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", "dev": true }, + "encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", + "dev": true + }, "ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -9038,15 +9056,15 @@ } }, "serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.2", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", + "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", "dev": true, "requires": { - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "parseurl": "~1.3.3", - "send": "0.18.0" + "send": "0.19.0" } }, "set-function-length": { From e04100330c4294bff61793907573930120c02b83 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Sep 2024 09:33:17 -0700 Subject: [PATCH 28/35] Bump send and express in /motoko/random_maze (#984) Bumps [send](https://github.com/pillarjs/send) and [express](https://github.com/expressjs/express). These dependencies needed to be updated together. Updates `send` from 0.18.0 to 0.19.0 - [Release notes](https://github.com/pillarjs/send/releases) - [Changelog](https://github.com/pillarjs/send/blob/master/HISTORY.md) - [Commits](https://github.com/pillarjs/send/compare/0.18.0...0.19.0) Updates `express` from 4.19.2 to 4.21.0 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.0/History.md) - [Commits](https://github.com/expressjs/express/compare/4.19.2...4.21.0) --- updated-dependencies: - dependency-name: send dependency-type: indirect - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> From 836b999eb6b15799d4c83aa08e3bcb66f5c1e685 Mon Sep 17 00:00:00 2001 From: Jessie Mongeon <133128541+jessiemongeon1@users.noreply.github.com> Date: Fri, 20 Sep 2024 10:11:35 -0500 Subject: [PATCH 29/35] Update README.md --- motoko/basic_bitcoin/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/motoko/basic_bitcoin/README.md b/motoko/basic_bitcoin/README.md index 54ffa2a11..e5ee7044f 100644 --- a/motoko/basic_bitcoin/README.md +++ b/motoko/basic_bitcoin/README.md @@ -20,6 +20,10 @@ For a deeper understanding of the ICP < > BTC integration, see the [Bitcoin inte * [x] Install the [IC SDK](https://internetcomputer.org/docs/current/developer-docs/setup/install/index.mdx). +:::info +This example is designed to be deployed on the mainnet. It will return errors when deployed locally; these errors are expected. +::: + ## Step 1: Building and deploying sample code ### Clone the smart contract @@ -174,4 +178,4 @@ If you base your application on this example, we recommend you familiarize yours For example, the following aspects are particularly relevant for this app: * [Certify query responses if they are relevant for security](https://internetcomputer.org/docs/current/references/security/general-security-best-practices#certify-query-responses-if-they-are-relevant-for-security), since the app e.g. offers a method to read balances. -* [Use a decentralized governance system like SNS to make a canister have a decentralized controller](https://internetcomputer.org/docs/current/developer-docs/security/security-best-practices/overview) \ No newline at end of file +* [Use a decentralized governance system like SNS to make a canister have a decentralized controller](https://internetcomputer.org/docs/current/developer-docs/security/security-best-practices/overview) From e60c6a76f98b2c289a186df50dc34539db46f487 Mon Sep 17 00:00:00 2001 From: Jessie Mongeon <133128541+jessiemongeon1@users.noreply.github.com> Date: Fri, 20 Sep 2024 15:23:27 -0500 Subject: [PATCH 30/35] Update README.md --- README.md | 58 ++++++++++++++++++++++++++++++------------------------- 1 file changed, 32 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index 50d9e5949..9be143060 100644 --- a/README.md +++ b/README.md @@ -1,44 +1,50 @@ -## DFINITY Examples for the Internet Computer +# Internet Computer sample applications -This repository provides access to sample code, applications, and microservices that run on the Internet Computer platform. +Get started building on ICP with the sample applications in this repository. -From this repository, you can download, clone, fork, or share sample projects. +From this repository, you can deploy, download, clone, fork, or share sample projects. -You will also be able to contribute your own project or suggest updates to published projects using the standard Git work flow. - -Sample projects provide a way for you to experiment and collaborate with other developers. The projects and sample code are not, however, intended to be used as commercial applications and do not provide any explicit or implied support or warranty of any kind. -To get started: +You can also contribute your own project or suggest updates to published projects using the standard GitHub workflow. + +## Deploying samples + +### GitHub Codespaces or Gitpod + +This repo can be opened in a web-based developer environment such as [GitHub Codespaces](https://github.com/codespaces) or [Gitpod](https://www.gitpod.io/), allowing you to edit and deploy the sample projects without downloading any tools or setting up a local environment. + +[Get started with GitHub codespaces](https://internetcomputer.org/docs/current/developer-docs/developer-tools/ide/codespaces). + +[Get started with Gitpod](https://internetcomputer.org/docs/current/developer-docs/developer-tools/ide/gitpod). + +### Motoko Playground -1. Open a terminal shell on your local computer. +Motoko Playground is a web-based developer environment for Motoko projects. To use Motoko Playground, navigate to the [playground UI](https://m7sm4-2iaaa-aaaab-qabra-cai.ic0.app/) and select a template to get started, or start a new project. -1. Download the DFINITY Canister SDK, if needed: +### dfx - ``` - sh -ci "$(curl -fsSL https://internetcomputer.org/install.sh)" - ``` +dfx is a command-line tool used to create, deploy. and manage projects on ICP. To download and use dfx with this examples repo, run the following commands locally (macOS/Linux systems): -1. Select a language—for example, `c` or `motoko`—to explore the examples available in the language of your choice. +``` +git clone https://github.com/dfinity/examples.git +cd examples +sh -ci "$(curl -fsSL https://internetcomputer.org/install.sh)" +``` -1. Clone the repository to download the `examples` repo to your local workspace. +Then, navigate into the folder of the sample that you want to use and follow the project's README instructions to setup and deploy the sample code. -1. Open the project folder for the example you want to use. -1. Start a local internet computer replica by running the following command: +## Resources - ``` - dfx start - ``` +- [ICP Developer Docs](https://internetcomputer.org/docs/current/home) -1. Open a new terminal shell on your local computer. +- [Overview of ICP](https://internetcomputer.org/docs/current/developer-docs/getting-started/overview-of-icp) -1. Build the sample project by running the following command: +- [Installing dfx](https://internetcomputer.org/docs/current/developer-docs/getting-started/install/) - ``` - dfx build - ``` +- [Developer tools](https://internetcomputer.org/docs/current/developer-docs/developer-tools/dev-tools-overview) -## Security Considerations and Best Practices +## Security considerations and best practices -If you base your application on one of these examples, we recommend you familiarize yourself with and adhere to the [Security Best Practices](https://internetcomputer.org/docs/current/references/security/) for developing on the Internet Computer. The examples provided here may not implement all the best practices. +If you base your application on one of these examples, we recommend you familiarize yourself with and adhere to the [security best practices](https://internetcomputer.org/docs/current/references/security/) for developing on the Internet Computer. The examples provided here may not implement all the best practices. From 0f616529d6d905c67b203395ba46e3731b21487c Mon Sep 17 00:00:00 2001 From: Jessie Mongeon <133128541+jessiemongeon1@users.noreply.github.com> Date: Fri, 20 Sep 2024 15:29:57 -0500 Subject: [PATCH 31/35] Update README.md --- README.md | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 9be143060..4df4c6ab1 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,27 @@ # Internet Computer sample applications -Get started building on ICP with the sample applications in this repository. +Get started building on ICP with the sample applications in this repository. From this repository, you can deploy, download, clone, fork, or share sample projects. -From this repository, you can deploy, download, clone, fork, or share sample projects. - -The projects and sample code are not, however, intended to be used as commercial applications and do not provide any explicit or implied support or warranty of any kind. +The projects in this repository are not intended to be used as commercial applications and do not provide any explicit or implied support or warranty of any kind. You can also contribute your own project or suggest updates to published projects using the standard GitHub workflow. +## Sample applications + +Code samples are organized by programming language: + +- [Motoko](https://github.com/dfinity/examples/tree/master/motoko) +- [Rust](https://github.com/dfinity/examples/tree/master/rust) +- [C](https://github.com/dfinity/examples/tree/master/c) + +Some examples include frontends written in a variety of frameworks, such as React, JavaScript, etc. + +Additional frontend samples can be found in the following folders: + +- [Svelte](https://github.com/dfinity/examples/tree/master/svelte) +- [HTML](https://github.com/dfinity/examples/tree/master/hosting) +- [Unity](https://github.com/dfinity/examples/tree/master/native-apps) + ## Deploying samples ### GitHub Codespaces or Gitpod From e243f7a422f95f7d4022c2fe605dbf172a79d24e Mon Sep 17 00:00:00 2001 From: Jessie Mongeon Date: Fri, 20 Sep 2024 15:41:18 -0500 Subject: [PATCH 32/35] Archive examples 2 --- .../motoko-actor_reference-example.yaml | 40 -------- .github/workflows/motoko-calc-example.yaml | 40 -------- .github/workflows/motoko-defi-example.yml | 48 ---------- .github/workflows/motoko-dip721-example.yml | 42 --------- .github/workflows/motoko-echo-example.yaml | 40 -------- .../workflows/motoko-factorial-example.yaml | 40 -------- .github/workflows/motoko-hello-example.yml | 40 -------- .../workflows/motoko-hello-world-example.yaml | 40 -------- .../workflows/motoko-icp-transfer-example.yml | 39 -------- .../motoko-ios-notifications-example.yml | 38 -------- .../motoko-persistent-storage-example.yaml | 40 -------- .../workflows/motoko-phone-book-example.yaml | 40 -------- .../workflows/motoko-quicksort-example.yaml | 40 -------- .../motoko-simple-to-do-example.yaml | 40 -------- archive/README.md | 3 + .../motoko}/actor_reference/Makefile | 0 .../motoko}/actor_reference/README.md | 0 .../motoko}/actor_reference/dfx.json | 0 .../src/actor_reference/main.mo | 0 .../.github/workflows/release.yml | 0 .../motoko}/auth_client_demo/.gitignore | 0 .../motoko}/auth_client_demo/README.md | 0 .../auth_client_demo/canister_ids.json | 0 .../candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did | 0 .../motoko}/auth_client_demo/deps/init.json | 0 .../motoko}/auth_client_demo/deps/pulled.json | 0 .../dfinity-auth-client-0.15.1.tgz | Bin .../motoko}/auth_client_demo/dfx.json | 0 .../motoko}/auth_client_demo/meta.json | 0 .../auth_client_demo/package-lock.json | 0 .../motoko}/auth_client_demo/package.json | 0 .../motoko}/auth_client_demo/release.mjs | 0 .../src/auth_client_demo_assets/react/App.jsx | 0 .../react/LoggedIn.jsx | 0 .../react/LoggedOut.jsx | 0 .../react/assets/main.css | 0 .../auth_client_demo_assets/react/index.html | 0 .../auth_client_demo_assets/react/index.jsx | 0 .../react/use-auth-client.jsx | 0 .../auth_client_demo_assets/svelte/.gitignore | 0 .../src/auth_client_demo_assets/svelte/.npmrc | 0 .../auth_client_demo_assets/svelte/README.md | 0 .../svelte/jsconfig.json | 0 .../svelte/package-lock.json | 0 .../svelte/package.json | 0 .../svelte/src/app.d.ts | 0 .../svelte/src/app.html | 0 .../svelte/src/components/LoggedIn.svelte | 0 .../svelte/src/components/LoggedOut.svelte | 0 .../svelte/src/routes/+page.svelte | 0 .../svelte/src/stores/auth.js | 0 .../svelte/static/favicon.png | Bin .../svelte/static/main.css | 0 .../svelte/svelte.config.js | 0 .../svelte/vite.config.js | 0 .../vanilla/assets/main.css | 0 .../vanilla/index.html | 0 .../auth_client_demo_assets/vanilla/index.ts | 0 .../vanilla/views/index.ts | 0 .../vanilla/views/loggedIn.ts | 0 .../src/auth_client_demo_assets/vue/App.vue | 0 .../vue/assets/favicon.ico | Bin .../vue/assets/main.css | 0 .../vue/components/LoggedIn.vue | 0 .../vue/components/LoggedOut.vue | 0 .../auth_client_demo_assets/vue/index.html | 0 .../src/auth_client_demo_assets/vue/main.js | 0 .../auth_client_demo_assets/vue/store/auth.js | 0 .../auth_client_demo/src/whoami/main.mo | 0 .../motoko}/auth_client_demo/svelte.config.js | 0 .../motoko}/auth_client_demo/tsconfig.json | 0 .../motoko}/auth_client_demo/vite.config.js | 0 .../auth_client_demo/vite.config.react.js | 0 .../auth_client_demo/vite.config.vue.js | 0 {motoko => archive/motoko}/calc/Makefile | 0 {motoko => archive/motoko}/calc/README.md | 0 {motoko => archive/motoko}/calc/dfx.json | 0 {motoko => archive/motoko}/calc/src/Main.mo | 0 {motoko => archive/motoko}/defi/.gitignore | 0 {motoko => archive/motoko}/defi/.gitmodules | 0 {motoko => archive/motoko}/defi/Makefile | 0 {motoko => archive/motoko}/defi/README.md | 0 .../motoko}/defi/architecture.md | 0 {motoko => archive/motoko}/defi/dfx.json | 0 .../motoko}/defi/scripts/deploy_dip20.sh | 0 .../defi/scripts/initalize_local_balance.sh | 0 .../motoko}/defi/scripts/install.sh | 0 .../principal_to_default_account_id.py | 0 .../motoko}/defi/src/defi_dapp/Account.mo | 0 .../motoko}/defi/src/defi_dapp/CRC32.mo | 0 .../motoko}/defi/src/defi_dapp/SHA224.mo | 0 .../motoko}/defi/src/defi_dapp/book.mo | 0 .../motoko}/defi/src/defi_dapp/exchange.mo | 0 .../motoko}/defi/src/defi_dapp/main.mo | 0 .../motoko}/defi/src/defi_dapp/types.mo | 0 .../motoko}/defi/src/frontend/README.md | 0 .../defi/src/frontend/package-lock.json | 0 .../motoko}/defi/src/frontend/package.json | 0 .../defi/src/frontend/rollup.config.js | 0 .../motoko}/defi/src/frontend/src/App.svelte | 0 .../src/frontend/src/components/Auth.svelte | 0 .../src/components/BalanceInfo.svelte | 0 .../src/components/CanisterIds.svelte | 0 .../src/frontend/src/components/Links.svelte | 0 .../src/frontend/src/components/Nav.svelte | 0 .../src/frontend/src/components/Orders.svelte | 0 .../motoko}/defi/src/frontend/src/main.js | 0 .../defi/src/frontend/src/store/auth.js | 0 .../defi/src/frontend/src/store/order.js | 0 .../defi/src/frontend/src/store/store.js | 0 .../defi/src/frontend/src/utils/helpers.js | 0 .../defi/src/frontend_assets/favicon.png | Bin .../defi/src/frontend_assets/global.css | 0 .../src/frontend_assets/images/dfinity.svg | 0 .../src/frontend_assets/images/ic-badge.png | Bin .../src/frontend_assets/images/plug_logo.png | Bin .../defi/src/frontend_assets/index.html | 0 .../defi/src/ledger/ledger.private.did | 0 .../motoko}/defi/src/ledger/ledger.public.did | 0 .../motoko}/defi/src/ledger/ledger.wasm | Bin .../motoko}/defi/src/ledger/ledger/index.d.ts | 0 .../motoko}/defi/src/ledger/ledger/index.js | 0 .../defi/src/ledger/ledger/ledger.did.d.ts | 0 .../defi/src/ledger/ledger/ledger.did.js | 0 {motoko => archive/motoko}/defi/test/demo.sh | 0 {motoko => archive/motoko}/defi/test/trade.sh | 0 .../motoko}/defi/test/transfer.sh | 0 .../motoko}/dip721-nft-container/README.md | 0 .../motoko}/dip721-nft-container/demo.sh | 0 .../motoko}/dip721-nft-container/dfx.json | 0 .../motoko}/dip721-nft-container/src/Main.mo | 0 .../motoko}/dip721-nft-container/src/Types.mo | 0 {motoko => archive/motoko}/echo/Makefile | 0 {motoko => archive/motoko}/echo/README.md | 0 {motoko => archive/motoko}/echo/dfx.json | 0 {motoko => archive/motoko}/echo/src/Main.mo | 0 {motoko => archive/motoko}/factorial/Makefile | 0 .../motoko}/factorial/README.md | 0 {motoko => archive/motoko}/factorial/dfx.json | 0 .../motoko}/factorial/src/Main.mo | 0 .../motoko}/hello-world/Makefile | 0 .../motoko}/hello-world/README.md | 0 .../motoko}/hello-world/dfx.json | 0 {motoko => archive/motoko}/hello-world/ii.did | 0 .../motoko}/hello-world/src/Main.mo | 0 .../declarations/hello_world/hello_world.did | 0 .../hello_world/hello_world.did.d.ts | 0 .../hello_world/hello_world.did.js | 0 .../src/declarations/hello_world/index.d.ts | 0 .../src/declarations/hello_world/index.js | 0 {motoko => archive/motoko}/hello/Makefile | 0 {motoko => archive/motoko}/hello/README.md | 0 {motoko => archive/motoko}/hello/dfx.json | 0 .../motoko}/hello/package-lock.json | 0 {motoko => archive/motoko}/hello/package.json | 0 .../motoko}/hello/src/hello/main.mo | 0 .../hello/src/hello_assets/assets/favicon.ico | Bin .../hello/src/hello_assets/assets/logo.png | Bin .../hello/src/hello_assets/assets/main.css | 0 .../src/hello_assets/assets/sample-asset.txt | 0 .../hello/src/hello_assets/src/index.html | 0 .../hello/src/hello_assets/src/index.js | 0 .../motoko}/hello/webpack.config.js | 0 .../motoko}/icp_transfer/.gitignore | 0 .../motoko}/icp_transfer/README.md | 0 .../motoko}/icp_transfer/demo.sh | 0 .../motoko}/icp_transfer/dfx.json | 0 .../src/icp_transfer_backend/main.mo | 0 .../motoko}/ios-notifications/.gitignore | 0 .../motoko}/ios-notifications/README.md | 0 .../ios-notifications/dapp-demo/.gitignore | 0 .../ios-notifications/dapp-demo/Makefile | 0 .../ios-notifications/dapp-demo/README.md | 0 .../dapp-demo/canister_ids.json | 0 .../ios-notifications/dapp-demo/dfx.json | 0 .../dapp-demo/package-lock.json | 0 .../ios-notifications/dapp-demo/package.json | 0 .../dapp-demo/src/api/main.mo | 0 .../dapp-demo/src/www/assets/.ic-assets.json | 0 .../.well-known/apple-app-site-association | 0 .../dapp-demo/src/www/assets/main.css | 0 .../dapp-demo/src/www/src/auth.ts | 0 .../dapp-demo/src/www/src/index.html | 0 .../dapp-demo/src/www/src/index.ts | 0 .../dapp-demo/src/www/src/pages/about.ts | 0 .../dapp-demo/src/www/src/pages/home.ts | 0 .../dapp-demo/src/www/src/pages/index.ts | 0 .../dapp-demo/src/www/src/pages/login.ts | 0 .../dapp-demo/src/www/src/router.ts | 0 .../dapp-demo/src/www/src/types.ts | 0 .../ios-notifications/dapp-demo/test_api.sh | 0 .../ios-notifications/dapp-demo/tsconfig.json | 0 .../dapp-demo/webpack.config.js | 0 .../ios-dapp-demo/DAppExample-Info.plist | 0 .../DAppExample.xcodeproj/project.pbxproj | 0 .../contents.xcworkspacedata | 0 .../xcshareddata/IDEWorkspaceChecks.plist | 0 .../xcshareddata/swiftpm/Package.resolved | 0 .../AccentColor.colorset/Contents.json | 0 .../AppIcon.appiconset/Contents.json | 0 .../DAppExample/Assets.xcassets/Contents.json | 0 .../DAppExample/ContentView.swift | 0 .../ios-dapp-demo/DAppExample/DApp.swift | 0 .../DAppExample/DAppDelegate.swift | 0 .../DAppExample/DAppExample.entitlements | 0 .../DAppExample/DAppWebView.swift | 0 .../DAppExample/DappConfig.swift | 0 .../DAppExample/IdentityKeyPair.swift | 0 .../DAppExample/LoadingScreen.swift | 0 .../DAppExample/LoginSession.swift | 0 .../Preview Assets.xcassets/Contents.json | 0 .../ios-notifications/ios-dapp-demo/README.md | 0 .../ios-notifications/send-notification.sh | 0 .../motoko}/persistent-storage/Makefile | 0 .../motoko}/persistent-storage/README.md | 0 .../README_images/candid_ui.png | Bin .../motoko}/persistent-storage/dfx.json | 0 .../src/persistent_storage/main.mo | 0 .../motoko}/phone-book/Makefile | 0 .../motoko}/phone-book/README.md | 0 .../motoko}/phone-book/dfx.json | 0 .../motoko}/phone-book/package-lock.json | 0 .../motoko}/phone-book/package.json | 0 .../src/declarations/phone_book/index.d.ts | 0 .../src/declarations/phone_book/index.js | 0 .../declarations/phone_book/phone_book.did | 0 .../phone_book/phone_book.did.d.ts | 0 .../declarations/phone_book/phone_book.did.js | 0 .../motoko}/phone-book/src/phone-book/Main.mo | 0 .../src/www/assets/sample-asset.txt | 0 .../motoko}/phone-book/src/www/src/index.html | 0 .../motoko}/phone-book/src/www/src/index.jsx | 0 .../motoko}/phone-book/tsconfig.json | 0 .../motoko}/phone-book/webpack.config.js | 0 {motoko => archive/motoko}/quicksort/Makefile | 0 .../motoko}/quicksort/README.md | 0 {motoko => archive/motoko}/quicksort/dfx.json | 0 .../motoko}/quicksort/src/Main.mo | 0 .../motoko}/quicksort/src/Quicksort.mo | 0 .../motoko}/simple-to-do/Makefile | 0 .../motoko}/simple-to-do/README.md | 0 .../motoko}/simple-to-do/dfx.json | 0 .../motoko}/simple-to-do/src/Main.mo | 0 motoko/defi/src/DIP20 | 1 - motoko/defi/src/ledger/ledger.did | 87 ------------------ 245 files changed, 3 insertions(+), 655 deletions(-) delete mode 100644 .github/workflows/motoko-actor_reference-example.yaml delete mode 100644 .github/workflows/motoko-calc-example.yaml delete mode 100644 .github/workflows/motoko-defi-example.yml delete mode 100644 .github/workflows/motoko-dip721-example.yml delete mode 100644 .github/workflows/motoko-echo-example.yaml delete mode 100644 .github/workflows/motoko-factorial-example.yaml delete mode 100644 .github/workflows/motoko-hello-example.yml delete mode 100644 .github/workflows/motoko-hello-world-example.yaml delete mode 100644 .github/workflows/motoko-icp-transfer-example.yml delete mode 100644 .github/workflows/motoko-ios-notifications-example.yml delete mode 100644 .github/workflows/motoko-persistent-storage-example.yaml delete mode 100644 .github/workflows/motoko-phone-book-example.yaml delete mode 100644 .github/workflows/motoko-quicksort-example.yaml delete mode 100644 .github/workflows/motoko-simple-to-do-example.yaml create mode 100644 archive/README.md rename {motoko => archive/motoko}/actor_reference/Makefile (100%) rename {motoko => archive/motoko}/actor_reference/README.md (100%) rename {motoko => archive/motoko}/actor_reference/dfx.json (100%) rename {motoko => archive/motoko}/actor_reference/src/actor_reference/main.mo (100%) rename {motoko => archive/motoko}/auth_client_demo/.github/workflows/release.yml (100%) rename {motoko => archive/motoko}/auth_client_demo/.gitignore (100%) rename {motoko => archive/motoko}/auth_client_demo/README.md (100%) rename {motoko => archive/motoko}/auth_client_demo/canister_ids.json (100%) rename {motoko => archive/motoko}/auth_client_demo/deps/candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did (100%) rename {motoko => archive/motoko}/auth_client_demo/deps/init.json (100%) rename {motoko => archive/motoko}/auth_client_demo/deps/pulled.json (100%) rename {motoko => archive/motoko}/auth_client_demo/dfinity-auth-client-0.15.1.tgz (100%) rename {motoko => archive/motoko}/auth_client_demo/dfx.json (100%) rename {motoko => archive/motoko}/auth_client_demo/meta.json (100%) rename {motoko => archive/motoko}/auth_client_demo/package-lock.json (100%) rename {motoko => archive/motoko}/auth_client_demo/package.json (100%) rename {motoko => archive/motoko}/auth_client_demo/release.mjs (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/App.jsx (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/LoggedIn.jsx (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/LoggedOut.jsx (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/assets/main.css (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/index.html (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/index.jsx (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/react/use-auth-client.jsx (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/.gitignore (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/.npmrc (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/README.md (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/jsconfig.json (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/package-lock.json (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/package.json (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.d.ts (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.html (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedIn.svelte (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedOut.svelte (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/routes/+page.svelte (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/src/stores/auth.js (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/static/favicon.png (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/static/main.css (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/svelte.config.js (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/svelte/vite.config.js (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vanilla/assets/main.css (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vanilla/index.html (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vanilla/index.ts (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vanilla/views/index.ts (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vanilla/views/loggedIn.ts (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/App.vue (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/assets/favicon.ico (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/assets/main.css (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedIn.vue (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedOut.vue (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/index.html (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/main.js (100%) rename {motoko => archive/motoko}/auth_client_demo/src/auth_client_demo_assets/vue/store/auth.js (100%) rename {motoko => archive/motoko}/auth_client_demo/src/whoami/main.mo (100%) rename {motoko => archive/motoko}/auth_client_demo/svelte.config.js (100%) rename {motoko => archive/motoko}/auth_client_demo/tsconfig.json (100%) rename {motoko => archive/motoko}/auth_client_demo/vite.config.js (100%) rename {motoko => archive/motoko}/auth_client_demo/vite.config.react.js (100%) rename {motoko => archive/motoko}/auth_client_demo/vite.config.vue.js (100%) rename {motoko => archive/motoko}/calc/Makefile (100%) rename {motoko => archive/motoko}/calc/README.md (100%) rename {motoko => archive/motoko}/calc/dfx.json (100%) rename {motoko => archive/motoko}/calc/src/Main.mo (100%) rename {motoko => archive/motoko}/defi/.gitignore (100%) rename {motoko => archive/motoko}/defi/.gitmodules (100%) rename {motoko => archive/motoko}/defi/Makefile (100%) rename {motoko => archive/motoko}/defi/README.md (100%) rename {motoko => archive/motoko}/defi/architecture.md (100%) rename {motoko => archive/motoko}/defi/dfx.json (100%) rename {motoko => archive/motoko}/defi/scripts/deploy_dip20.sh (100%) rename {motoko => archive/motoko}/defi/scripts/initalize_local_balance.sh (100%) rename {motoko => archive/motoko}/defi/scripts/install.sh (100%) rename {motoko => archive/motoko}/defi/scripts/principal_to_default_account_id.py (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/Account.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/CRC32.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/SHA224.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/book.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/exchange.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/main.mo (100%) rename {motoko => archive/motoko}/defi/src/defi_dapp/types.mo (100%) rename {motoko => archive/motoko}/defi/src/frontend/README.md (100%) rename {motoko => archive/motoko}/defi/src/frontend/package-lock.json (100%) rename {motoko => archive/motoko}/defi/src/frontend/package.json (100%) rename {motoko => archive/motoko}/defi/src/frontend/rollup.config.js (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/App.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/Auth.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/BalanceInfo.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/CanisterIds.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/Links.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/Nav.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/components/Orders.svelte (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/main.js (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/store/auth.js (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/store/order.js (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/store/store.js (100%) rename {motoko => archive/motoko}/defi/src/frontend/src/utils/helpers.js (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/favicon.png (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/global.css (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/images/dfinity.svg (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/images/ic-badge.png (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/images/plug_logo.png (100%) rename {motoko => archive/motoko}/defi/src/frontend_assets/index.html (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger.private.did (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger.public.did (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger.wasm (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger/index.d.ts (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger/index.js (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger/ledger.did.d.ts (100%) rename {motoko => archive/motoko}/defi/src/ledger/ledger/ledger.did.js (100%) rename {motoko => archive/motoko}/defi/test/demo.sh (100%) rename {motoko => archive/motoko}/defi/test/trade.sh (100%) rename {motoko => archive/motoko}/defi/test/transfer.sh (100%) rename {motoko => archive/motoko}/dip721-nft-container/README.md (100%) rename {motoko => archive/motoko}/dip721-nft-container/demo.sh (100%) rename {motoko => archive/motoko}/dip721-nft-container/dfx.json (100%) rename {motoko => archive/motoko}/dip721-nft-container/src/Main.mo (100%) rename {motoko => archive/motoko}/dip721-nft-container/src/Types.mo (100%) rename {motoko => archive/motoko}/echo/Makefile (100%) rename {motoko => archive/motoko}/echo/README.md (100%) rename {motoko => archive/motoko}/echo/dfx.json (100%) rename {motoko => archive/motoko}/echo/src/Main.mo (100%) rename {motoko => archive/motoko}/factorial/Makefile (100%) rename {motoko => archive/motoko}/factorial/README.md (100%) rename {motoko => archive/motoko}/factorial/dfx.json (100%) rename {motoko => archive/motoko}/factorial/src/Main.mo (100%) rename {motoko => archive/motoko}/hello-world/Makefile (100%) rename {motoko => archive/motoko}/hello-world/README.md (100%) rename {motoko => archive/motoko}/hello-world/dfx.json (100%) rename {motoko => archive/motoko}/hello-world/ii.did (100%) rename {motoko => archive/motoko}/hello-world/src/Main.mo (100%) rename {motoko => archive/motoko}/hello-world/src/declarations/hello_world/hello_world.did (100%) rename {motoko => archive/motoko}/hello-world/src/declarations/hello_world/hello_world.did.d.ts (100%) rename {motoko => archive/motoko}/hello-world/src/declarations/hello_world/hello_world.did.js (100%) rename {motoko => archive/motoko}/hello-world/src/declarations/hello_world/index.d.ts (100%) rename {motoko => archive/motoko}/hello-world/src/declarations/hello_world/index.js (100%) rename {motoko => archive/motoko}/hello/Makefile (100%) rename {motoko => archive/motoko}/hello/README.md (100%) rename {motoko => archive/motoko}/hello/dfx.json (100%) rename {motoko => archive/motoko}/hello/package-lock.json (100%) rename {motoko => archive/motoko}/hello/package.json (100%) rename {motoko => archive/motoko}/hello/src/hello/main.mo (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/assets/favicon.ico (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/assets/logo.png (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/assets/main.css (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/assets/sample-asset.txt (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/src/index.html (100%) rename {motoko => archive/motoko}/hello/src/hello_assets/src/index.js (100%) rename {motoko => archive/motoko}/hello/webpack.config.js (100%) rename {motoko => archive/motoko}/icp_transfer/.gitignore (100%) rename {motoko => archive/motoko}/icp_transfer/README.md (100%) rename {motoko => archive/motoko}/icp_transfer/demo.sh (100%) rename {motoko => archive/motoko}/icp_transfer/dfx.json (100%) rename {motoko => archive/motoko}/icp_transfer/src/icp_transfer_backend/main.mo (100%) rename {motoko => archive/motoko}/ios-notifications/.gitignore (100%) rename {motoko => archive/motoko}/ios-notifications/README.md (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/.gitignore (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/Makefile (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/README.md (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/canister_ids.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/dfx.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/package-lock.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/package.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/api/main.mo (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/assets/.ic-assets.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/assets/.well-known/apple-app-site-association (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/assets/main.css (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/auth.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/index.html (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/index.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/pages/about.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/pages/home.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/pages/index.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/pages/login.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/router.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/src/www/src/types.ts (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/test_api.sh (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/tsconfig.json (100%) rename {motoko => archive/motoko}/ios-notifications/dapp-demo/webpack.config.js (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample-Info.plist (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.pbxproj (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AccentColor.colorset/Contents.json (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AppIcon.appiconset/Contents.json (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/Contents.json (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/ContentView.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/DApp.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/DAppDelegate.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/DAppExample.entitlements (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/DAppWebView.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/DappConfig.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/IdentityKeyPair.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/LoadingScreen.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/LoginSession.swift (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/DAppExample/Preview Content/Preview Assets.xcassets/Contents.json (100%) rename {motoko => archive/motoko}/ios-notifications/ios-dapp-demo/README.md (100%) rename {motoko => archive/motoko}/ios-notifications/send-notification.sh (100%) rename {motoko => archive/motoko}/persistent-storage/Makefile (100%) rename {motoko => archive/motoko}/persistent-storage/README.md (100%) rename {motoko => archive/motoko}/persistent-storage/README_images/candid_ui.png (100%) rename {motoko => archive/motoko}/persistent-storage/dfx.json (100%) rename {motoko => archive/motoko}/persistent-storage/src/persistent_storage/main.mo (100%) rename {motoko => archive/motoko}/phone-book/Makefile (100%) rename {motoko => archive/motoko}/phone-book/README.md (100%) rename {motoko => archive/motoko}/phone-book/dfx.json (100%) rename {motoko => archive/motoko}/phone-book/package-lock.json (100%) rename {motoko => archive/motoko}/phone-book/package.json (100%) rename {motoko => archive/motoko}/phone-book/src/declarations/phone_book/index.d.ts (100%) rename {motoko => archive/motoko}/phone-book/src/declarations/phone_book/index.js (100%) rename {motoko => archive/motoko}/phone-book/src/declarations/phone_book/phone_book.did (100%) rename {motoko => archive/motoko}/phone-book/src/declarations/phone_book/phone_book.did.d.ts (100%) rename {motoko => archive/motoko}/phone-book/src/declarations/phone_book/phone_book.did.js (100%) rename {motoko => archive/motoko}/phone-book/src/phone-book/Main.mo (100%) rename {motoko => archive/motoko}/phone-book/src/www/assets/sample-asset.txt (100%) rename {motoko => archive/motoko}/phone-book/src/www/src/index.html (100%) rename {motoko => archive/motoko}/phone-book/src/www/src/index.jsx (100%) rename {motoko => archive/motoko}/phone-book/tsconfig.json (100%) rename {motoko => archive/motoko}/phone-book/webpack.config.js (100%) rename {motoko => archive/motoko}/quicksort/Makefile (100%) rename {motoko => archive/motoko}/quicksort/README.md (100%) rename {motoko => archive/motoko}/quicksort/dfx.json (100%) rename {motoko => archive/motoko}/quicksort/src/Main.mo (100%) rename {motoko => archive/motoko}/quicksort/src/Quicksort.mo (100%) rename {motoko => archive/motoko}/simple-to-do/Makefile (100%) rename {motoko => archive/motoko}/simple-to-do/README.md (100%) rename {motoko => archive/motoko}/simple-to-do/dfx.json (100%) rename {motoko => archive/motoko}/simple-to-do/src/Main.mo (100%) delete mode 160000 motoko/defi/src/DIP20 delete mode 100644 motoko/defi/src/ledger/ledger.did diff --git a/.github/workflows/motoko-actor_reference-example.yaml b/.github/workflows/motoko-actor_reference-example.yaml deleted file mode 100644 index 1d66ffab9..000000000 --- a/.github/workflows/motoko-actor_reference-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-actor-reference -on: - push: - branches: - - master - pull_request: - paths: - - motoko/actor_reference/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-actor_reference-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-actor-reference-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Actor Reference Darwin - run: | - dfx start --background - pushd motoko/actor_reference - make test - popd - motoko-actor-reference-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Actor Reference Linux - run: | - dfx start --background - pushd motoko/actor_reference - make test - popd diff --git a/.github/workflows/motoko-calc-example.yaml b/.github/workflows/motoko-calc-example.yaml deleted file mode 100644 index 761d72095..000000000 --- a/.github/workflows/motoko-calc-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-calc -on: - push: - branches: - - master - pull_request: - paths: - - motoko/calc/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-calc-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-calc-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Calc Darwin - run: | - dfx start --background - pushd motoko/calc - make test - popd - motoko-calc-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Calc Linux - run: | - dfx start --background - pushd motoko/calc - make test - popd diff --git a/.github/workflows/motoko-defi-example.yml b/.github/workflows/motoko-defi-example.yml deleted file mode 100644 index 9974d4d31..000000000 --- a/.github/workflows/motoko-defi-example.yml +++ /dev/null @@ -1,48 +0,0 @@ -name: motoko-defi -on: - push: - branches: - - master - pull_request: - paths: - - motoko/defi/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-defi-example.yml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-defi-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v2 - with: - submodules: recursive - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Defi Darwin - run: | - pushd motoko/defi - bash ./scripts/install.sh - bash ./test/demo.sh - bash ./test/trade.sh - bash ./test/transfer.sh - popd - motoko-defi-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: recursive - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Defi Linux - run: | - pushd motoko/defi - bash ./scripts/install.sh - bash ./test/demo.sh - bash ./test/trade.sh - bash ./test/transfer.sh - popd diff --git a/.github/workflows/motoko-dip721-example.yml b/.github/workflows/motoko-dip721-example.yml deleted file mode 100644 index 55c739951..000000000 --- a/.github/workflows/motoko-dip721-example.yml +++ /dev/null @@ -1,42 +0,0 @@ -name: motoko-dip721 -on: - push: - branches: - - master - pull_request: - paths: - - motoko/dip721-nft-container/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-dip721-example.yml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-dip721-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v2 - with: - submodules: recursive - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko DIP-721 Darwin - run: | - pushd motoko/dip721-nft-container - bash ./demo.sh - popd - motoko-dip721-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: recursive - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko DIP-721 Linux - run: | - pushd motoko/dip721-nft-container - bash ./demo.sh - popd diff --git a/.github/workflows/motoko-echo-example.yaml b/.github/workflows/motoko-echo-example.yaml deleted file mode 100644 index 3bd1a9fd2..000000000 --- a/.github/workflows/motoko-echo-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-echo -on: - push: - branches: - - master - pull_request: - paths: - - motoko/echo/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-echo-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-echo-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Echo Darwin - run: | - dfx start --background - pushd motoko/echo - make test - popd - motoko-echo-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Echo Linux - run: | - dfx start --background - pushd motoko/echo - make test - popd diff --git a/.github/workflows/motoko-factorial-example.yaml b/.github/workflows/motoko-factorial-example.yaml deleted file mode 100644 index 69e3bd2c6..000000000 --- a/.github/workflows/motoko-factorial-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-factorial -on: - push: - branches: - - master - pull_request: - paths: - - motoko/factorial/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-factorial-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-factorial-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Factorial Darwin - run: | - dfx start --background - pushd motoko/factorial - make test - popd - motoko-factorial-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Factorial Linux - run: | - dfx start --background - pushd motoko/factorial - make test - popd diff --git a/.github/workflows/motoko-hello-example.yml b/.github/workflows/motoko-hello-example.yml deleted file mode 100644 index 2d2cfbb1c..000000000 --- a/.github/workflows/motoko-hello-example.yml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-hello -on: - push: - branches: - - master - pull_request: - paths: - - motoko/hello/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-hello-example.yml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-hello-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Hello Darwin - run: | - dfx start --background - pushd motoko/hello - make test - popd - motoko-hello-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Hello Linux - run: | - dfx start --background - pushd motoko/hello - make test - popd \ No newline at end of file diff --git a/.github/workflows/motoko-hello-world-example.yaml b/.github/workflows/motoko-hello-world-example.yaml deleted file mode 100644 index 368f7b473..000000000 --- a/.github/workflows/motoko-hello-world-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-hello-world -on: - push: - branches: - - master - pull_request: - paths: - - motoko/hello-world/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-hello-world-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-hello-world-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Hello World Darwin - run: | - dfx start --background - pushd motoko/hello-world - make test - popd - motoko-hello-world-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Hello World Linux - run: | - dfx start --background - pushd motoko/hello-world - make test - popd diff --git a/.github/workflows/motoko-icp-transfer-example.yml b/.github/workflows/motoko-icp-transfer-example.yml deleted file mode 100644 index 185b8dc5f..000000000 --- a/.github/workflows/motoko-icp-transfer-example.yml +++ /dev/null @@ -1,39 +0,0 @@ -# Known failure: https://dfinity.atlassian.net/browse/EM-5 -name: motoko-icp_transfer -on: - push: - branches: - - master - pull_request: - paths: - - motoko/icp_transfer/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-icp-transfer-example.yml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-icp_transfer-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Ledger Transfer Darwin - run: | - pushd motoko/icp_transfer - bash ./demo.sh - popd - motoko-icp_transfer-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Ledger Transfer Linux - run: | - pushd motoko/icp_transfer - bash ./demo.sh - popd diff --git a/.github/workflows/motoko-ios-notifications-example.yml b/.github/workflows/motoko-ios-notifications-example.yml deleted file mode 100644 index bf859ef66..000000000 --- a/.github/workflows/motoko-ios-notifications-example.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: motoko-ios-notifications -on: - push: - branches: - - master - pull_request: - paths: - - motoko/ios-notifications/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/ios-notifications-example.yml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-ios-notifications-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko iOS Notifications Darwin - run: | - pushd motoko/ios-notifications/dapp-demo - make test - popd - motoko-ios-notifications-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko iOS Notifications Linux - run: | - pushd motoko/ios-notifications/dapp-demo - make test - popd diff --git a/.github/workflows/motoko-persistent-storage-example.yaml b/.github/workflows/motoko-persistent-storage-example.yaml deleted file mode 100644 index 403c78358..000000000 --- a/.github/workflows/motoko-persistent-storage-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-persistent-storage -on: - push: - branches: - - master - pull_request: - paths: - - motoko/persistent-storage/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-persistent-storage-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-persistent-storage-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Persistent Storage Darwin - run: | - dfx start --background - pushd motoko/persistent-storage - make test - popd - motoko-persistent-storage-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Persistent Storage Linux - run: | - dfx start --background - pushd motoko/persistent-storage - make test - popd diff --git a/.github/workflows/motoko-phone-book-example.yaml b/.github/workflows/motoko-phone-book-example.yaml deleted file mode 100644 index 46002b63b..000000000 --- a/.github/workflows/motoko-phone-book-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-phone-book -on: - push: - branches: - - master - pull_request: - paths: - - motoko/phone-book/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-phone-book-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-phone-book-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Phone Book Darwin - run: | - dfx start --background - pushd motoko/phone-book - make test - popd - motoko-phone-book-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Phone Book Linux - run: | - dfx start --background - pushd motoko/phone-book - make test - popd diff --git a/.github/workflows/motoko-quicksort-example.yaml b/.github/workflows/motoko-quicksort-example.yaml deleted file mode 100644 index c447a49b3..000000000 --- a/.github/workflows/motoko-quicksort-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-quicksort -on: - push: - branches: - - master - pull_request: - paths: - - motoko/quicksort/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-quicksort-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-quicksort-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Quicksort Darwin - run: | - dfx start --background - pushd motoko/quicksort - make test - popd - motoko-quicksort-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Quicksort Linux - run: | - dfx start --background - pushd motoko/quicksort - make test - popd diff --git a/.github/workflows/motoko-simple-to-do-example.yaml b/.github/workflows/motoko-simple-to-do-example.yaml deleted file mode 100644 index ddfbba987..000000000 --- a/.github/workflows/motoko-simple-to-do-example.yaml +++ /dev/null @@ -1,40 +0,0 @@ -name: motoko-simple-to-do -on: - push: - branches: - - master - pull_request: - paths: - - motoko/simple-to-do/** - - .github/workflows/provision-darwin.sh - - .github/workflows/provision-linux.sh - - .github/workflows/motoko-simple-to-do-example.yaml - - .ic-commit -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - motoko-simple-to-do-example-darwin: - runs-on: macos-12 - steps: - - uses: actions/checkout@v1 - - name: Provision Darwin - run: bash .github/workflows/provision-darwin.sh - - name: Motoko Simple To-Do Darwin - run: | - dfx start --background - pushd motoko/simple-to-do - make test - popd - motoko-simple-to-do-example-linux: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v1 - - name: Provision Linux - run: bash .github/workflows/provision-linux.sh - - name: Motoko Simple To-Do Linux - run: | - dfx start --background - pushd motoko/simple-to-do - make test - popd diff --git a/archive/README.md b/archive/README.md new file mode 100644 index 000000000..28c0a436d --- /dev/null +++ b/archive/README.md @@ -0,0 +1,3 @@ +# Archived examples + +The examples in this folder are archived and will no longer be maintained. \ No newline at end of file diff --git a/motoko/actor_reference/Makefile b/archive/motoko/actor_reference/Makefile similarity index 100% rename from motoko/actor_reference/Makefile rename to archive/motoko/actor_reference/Makefile diff --git a/motoko/actor_reference/README.md b/archive/motoko/actor_reference/README.md similarity index 100% rename from motoko/actor_reference/README.md rename to archive/motoko/actor_reference/README.md diff --git a/motoko/actor_reference/dfx.json b/archive/motoko/actor_reference/dfx.json similarity index 100% rename from motoko/actor_reference/dfx.json rename to archive/motoko/actor_reference/dfx.json diff --git a/motoko/actor_reference/src/actor_reference/main.mo b/archive/motoko/actor_reference/src/actor_reference/main.mo similarity index 100% rename from motoko/actor_reference/src/actor_reference/main.mo rename to archive/motoko/actor_reference/src/actor_reference/main.mo diff --git a/motoko/auth_client_demo/.github/workflows/release.yml b/archive/motoko/auth_client_demo/.github/workflows/release.yml similarity index 100% rename from motoko/auth_client_demo/.github/workflows/release.yml rename to archive/motoko/auth_client_demo/.github/workflows/release.yml diff --git a/motoko/auth_client_demo/.gitignore b/archive/motoko/auth_client_demo/.gitignore similarity index 100% rename from motoko/auth_client_demo/.gitignore rename to archive/motoko/auth_client_demo/.gitignore diff --git a/motoko/auth_client_demo/README.md b/archive/motoko/auth_client_demo/README.md similarity index 100% rename from motoko/auth_client_demo/README.md rename to archive/motoko/auth_client_demo/README.md diff --git a/motoko/auth_client_demo/canister_ids.json b/archive/motoko/auth_client_demo/canister_ids.json similarity index 100% rename from motoko/auth_client_demo/canister_ids.json rename to archive/motoko/auth_client_demo/canister_ids.json diff --git a/motoko/auth_client_demo/deps/candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did b/archive/motoko/auth_client_demo/deps/candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did similarity index 100% rename from motoko/auth_client_demo/deps/candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did rename to archive/motoko/auth_client_demo/deps/candid/rdmx6-jaaaa-aaaaa-aaadq-cai.did diff --git a/motoko/auth_client_demo/deps/init.json b/archive/motoko/auth_client_demo/deps/init.json similarity index 100% rename from motoko/auth_client_demo/deps/init.json rename to archive/motoko/auth_client_demo/deps/init.json diff --git a/motoko/auth_client_demo/deps/pulled.json b/archive/motoko/auth_client_demo/deps/pulled.json similarity index 100% rename from motoko/auth_client_demo/deps/pulled.json rename to archive/motoko/auth_client_demo/deps/pulled.json diff --git a/motoko/auth_client_demo/dfinity-auth-client-0.15.1.tgz b/archive/motoko/auth_client_demo/dfinity-auth-client-0.15.1.tgz similarity index 100% rename from motoko/auth_client_demo/dfinity-auth-client-0.15.1.tgz rename to archive/motoko/auth_client_demo/dfinity-auth-client-0.15.1.tgz diff --git a/motoko/auth_client_demo/dfx.json b/archive/motoko/auth_client_demo/dfx.json similarity index 100% rename from motoko/auth_client_demo/dfx.json rename to archive/motoko/auth_client_demo/dfx.json diff --git a/motoko/auth_client_demo/meta.json b/archive/motoko/auth_client_demo/meta.json similarity index 100% rename from motoko/auth_client_demo/meta.json rename to archive/motoko/auth_client_demo/meta.json diff --git a/motoko/auth_client_demo/package-lock.json b/archive/motoko/auth_client_demo/package-lock.json similarity index 100% rename from motoko/auth_client_demo/package-lock.json rename to archive/motoko/auth_client_demo/package-lock.json diff --git a/motoko/auth_client_demo/package.json b/archive/motoko/auth_client_demo/package.json similarity index 100% rename from motoko/auth_client_demo/package.json rename to archive/motoko/auth_client_demo/package.json diff --git a/motoko/auth_client_demo/release.mjs b/archive/motoko/auth_client_demo/release.mjs similarity index 100% rename from motoko/auth_client_demo/release.mjs rename to archive/motoko/auth_client_demo/release.mjs diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/App.jsx b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/App.jsx similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/App.jsx rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/App.jsx diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedIn.jsx b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedIn.jsx similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedIn.jsx rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedIn.jsx diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedOut.jsx b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedOut.jsx similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedOut.jsx rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/LoggedOut.jsx diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/assets/main.css b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/assets/main.css similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/assets/main.css rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/assets/main.css diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.html b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.html similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/index.html rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.html diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.jsx b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.jsx similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/index.jsx rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/index.jsx diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/react/use-auth-client.jsx b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/use-auth-client.jsx similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/react/use-auth-client.jsx rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/react/use-auth-client.jsx diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.gitignore b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.gitignore similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.gitignore rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.gitignore diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.npmrc b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.npmrc similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.npmrc rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/.npmrc diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/README.md b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/README.md similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/README.md rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/README.md diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/jsconfig.json b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/jsconfig.json similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/jsconfig.json rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/jsconfig.json diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package-lock.json b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package-lock.json similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package-lock.json rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package-lock.json diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package.json b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package.json similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package.json rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/package.json diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.d.ts b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.d.ts similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.d.ts rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.d.ts diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.html b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.html similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.html rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/app.html diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedIn.svelte b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedIn.svelte similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedIn.svelte rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedIn.svelte diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedOut.svelte b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedOut.svelte similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedOut.svelte rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/components/LoggedOut.svelte diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/routes/+page.svelte b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/routes/+page.svelte similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/routes/+page.svelte rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/routes/+page.svelte diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/stores/auth.js b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/stores/auth.js similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/stores/auth.js rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/src/stores/auth.js diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/favicon.png b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/favicon.png similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/favicon.png rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/favicon.png diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/main.css b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/main.css similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/main.css rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/static/main.css diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/svelte.config.js b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/svelte.config.js similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/svelte.config.js rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/svelte.config.js diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/vite.config.js b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/vite.config.js similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/svelte/vite.config.js rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/svelte/vite.config.js diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/assets/main.css b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/assets/main.css similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/assets/main.css rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/assets/main.css diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.html b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.html similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.html rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.html diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.ts b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.ts similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.ts rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/index.ts diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/index.ts b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/index.ts similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/index.ts rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/index.ts diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/loggedIn.ts b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/loggedIn.ts similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/loggedIn.ts rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vanilla/views/loggedIn.ts diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/App.vue b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/App.vue similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/App.vue rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/App.vue diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/favicon.ico b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/favicon.ico similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/favicon.ico rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/favicon.ico diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/main.css b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/main.css similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/main.css rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/assets/main.css diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedIn.vue b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedIn.vue similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedIn.vue rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedIn.vue diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedOut.vue b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedOut.vue similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedOut.vue rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/components/LoggedOut.vue diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/index.html b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/index.html similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/index.html rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/index.html diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/main.js b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/main.js similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/main.js rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/main.js diff --git a/motoko/auth_client_demo/src/auth_client_demo_assets/vue/store/auth.js b/archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/store/auth.js similarity index 100% rename from motoko/auth_client_demo/src/auth_client_demo_assets/vue/store/auth.js rename to archive/motoko/auth_client_demo/src/auth_client_demo_assets/vue/store/auth.js diff --git a/motoko/auth_client_demo/src/whoami/main.mo b/archive/motoko/auth_client_demo/src/whoami/main.mo similarity index 100% rename from motoko/auth_client_demo/src/whoami/main.mo rename to archive/motoko/auth_client_demo/src/whoami/main.mo diff --git a/motoko/auth_client_demo/svelte.config.js b/archive/motoko/auth_client_demo/svelte.config.js similarity index 100% rename from motoko/auth_client_demo/svelte.config.js rename to archive/motoko/auth_client_demo/svelte.config.js diff --git a/motoko/auth_client_demo/tsconfig.json b/archive/motoko/auth_client_demo/tsconfig.json similarity index 100% rename from motoko/auth_client_demo/tsconfig.json rename to archive/motoko/auth_client_demo/tsconfig.json diff --git a/motoko/auth_client_demo/vite.config.js b/archive/motoko/auth_client_demo/vite.config.js similarity index 100% rename from motoko/auth_client_demo/vite.config.js rename to archive/motoko/auth_client_demo/vite.config.js diff --git a/motoko/auth_client_demo/vite.config.react.js b/archive/motoko/auth_client_demo/vite.config.react.js similarity index 100% rename from motoko/auth_client_demo/vite.config.react.js rename to archive/motoko/auth_client_demo/vite.config.react.js diff --git a/motoko/auth_client_demo/vite.config.vue.js b/archive/motoko/auth_client_demo/vite.config.vue.js similarity index 100% rename from motoko/auth_client_demo/vite.config.vue.js rename to archive/motoko/auth_client_demo/vite.config.vue.js diff --git a/motoko/calc/Makefile b/archive/motoko/calc/Makefile similarity index 100% rename from motoko/calc/Makefile rename to archive/motoko/calc/Makefile diff --git a/motoko/calc/README.md b/archive/motoko/calc/README.md similarity index 100% rename from motoko/calc/README.md rename to archive/motoko/calc/README.md diff --git a/motoko/calc/dfx.json b/archive/motoko/calc/dfx.json similarity index 100% rename from motoko/calc/dfx.json rename to archive/motoko/calc/dfx.json diff --git a/motoko/calc/src/Main.mo b/archive/motoko/calc/src/Main.mo similarity index 100% rename from motoko/calc/src/Main.mo rename to archive/motoko/calc/src/Main.mo diff --git a/motoko/defi/.gitignore b/archive/motoko/defi/.gitignore similarity index 100% rename from motoko/defi/.gitignore rename to archive/motoko/defi/.gitignore diff --git a/motoko/defi/.gitmodules b/archive/motoko/defi/.gitmodules similarity index 100% rename from motoko/defi/.gitmodules rename to archive/motoko/defi/.gitmodules diff --git a/motoko/defi/Makefile b/archive/motoko/defi/Makefile similarity index 100% rename from motoko/defi/Makefile rename to archive/motoko/defi/Makefile diff --git a/motoko/defi/README.md b/archive/motoko/defi/README.md similarity index 100% rename from motoko/defi/README.md rename to archive/motoko/defi/README.md diff --git a/motoko/defi/architecture.md b/archive/motoko/defi/architecture.md similarity index 100% rename from motoko/defi/architecture.md rename to archive/motoko/defi/architecture.md diff --git a/motoko/defi/dfx.json b/archive/motoko/defi/dfx.json similarity index 100% rename from motoko/defi/dfx.json rename to archive/motoko/defi/dfx.json diff --git a/motoko/defi/scripts/deploy_dip20.sh b/archive/motoko/defi/scripts/deploy_dip20.sh similarity index 100% rename from motoko/defi/scripts/deploy_dip20.sh rename to archive/motoko/defi/scripts/deploy_dip20.sh diff --git a/motoko/defi/scripts/initalize_local_balance.sh b/archive/motoko/defi/scripts/initalize_local_balance.sh similarity index 100% rename from motoko/defi/scripts/initalize_local_balance.sh rename to archive/motoko/defi/scripts/initalize_local_balance.sh diff --git a/motoko/defi/scripts/install.sh b/archive/motoko/defi/scripts/install.sh similarity index 100% rename from motoko/defi/scripts/install.sh rename to archive/motoko/defi/scripts/install.sh diff --git a/motoko/defi/scripts/principal_to_default_account_id.py b/archive/motoko/defi/scripts/principal_to_default_account_id.py similarity index 100% rename from motoko/defi/scripts/principal_to_default_account_id.py rename to archive/motoko/defi/scripts/principal_to_default_account_id.py diff --git a/motoko/defi/src/defi_dapp/Account.mo b/archive/motoko/defi/src/defi_dapp/Account.mo similarity index 100% rename from motoko/defi/src/defi_dapp/Account.mo rename to archive/motoko/defi/src/defi_dapp/Account.mo diff --git a/motoko/defi/src/defi_dapp/CRC32.mo b/archive/motoko/defi/src/defi_dapp/CRC32.mo similarity index 100% rename from motoko/defi/src/defi_dapp/CRC32.mo rename to archive/motoko/defi/src/defi_dapp/CRC32.mo diff --git a/motoko/defi/src/defi_dapp/SHA224.mo b/archive/motoko/defi/src/defi_dapp/SHA224.mo similarity index 100% rename from motoko/defi/src/defi_dapp/SHA224.mo rename to archive/motoko/defi/src/defi_dapp/SHA224.mo diff --git a/motoko/defi/src/defi_dapp/book.mo b/archive/motoko/defi/src/defi_dapp/book.mo similarity index 100% rename from motoko/defi/src/defi_dapp/book.mo rename to archive/motoko/defi/src/defi_dapp/book.mo diff --git a/motoko/defi/src/defi_dapp/exchange.mo b/archive/motoko/defi/src/defi_dapp/exchange.mo similarity index 100% rename from motoko/defi/src/defi_dapp/exchange.mo rename to archive/motoko/defi/src/defi_dapp/exchange.mo diff --git a/motoko/defi/src/defi_dapp/main.mo b/archive/motoko/defi/src/defi_dapp/main.mo similarity index 100% rename from motoko/defi/src/defi_dapp/main.mo rename to archive/motoko/defi/src/defi_dapp/main.mo diff --git a/motoko/defi/src/defi_dapp/types.mo b/archive/motoko/defi/src/defi_dapp/types.mo similarity index 100% rename from motoko/defi/src/defi_dapp/types.mo rename to archive/motoko/defi/src/defi_dapp/types.mo diff --git a/motoko/defi/src/frontend/README.md b/archive/motoko/defi/src/frontend/README.md similarity index 100% rename from motoko/defi/src/frontend/README.md rename to archive/motoko/defi/src/frontend/README.md diff --git a/motoko/defi/src/frontend/package-lock.json b/archive/motoko/defi/src/frontend/package-lock.json similarity index 100% rename from motoko/defi/src/frontend/package-lock.json rename to archive/motoko/defi/src/frontend/package-lock.json diff --git a/motoko/defi/src/frontend/package.json b/archive/motoko/defi/src/frontend/package.json similarity index 100% rename from motoko/defi/src/frontend/package.json rename to archive/motoko/defi/src/frontend/package.json diff --git a/motoko/defi/src/frontend/rollup.config.js b/archive/motoko/defi/src/frontend/rollup.config.js similarity index 100% rename from motoko/defi/src/frontend/rollup.config.js rename to archive/motoko/defi/src/frontend/rollup.config.js diff --git a/motoko/defi/src/frontend/src/App.svelte b/archive/motoko/defi/src/frontend/src/App.svelte similarity index 100% rename from motoko/defi/src/frontend/src/App.svelte rename to archive/motoko/defi/src/frontend/src/App.svelte diff --git a/motoko/defi/src/frontend/src/components/Auth.svelte b/archive/motoko/defi/src/frontend/src/components/Auth.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/Auth.svelte rename to archive/motoko/defi/src/frontend/src/components/Auth.svelte diff --git a/motoko/defi/src/frontend/src/components/BalanceInfo.svelte b/archive/motoko/defi/src/frontend/src/components/BalanceInfo.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/BalanceInfo.svelte rename to archive/motoko/defi/src/frontend/src/components/BalanceInfo.svelte diff --git a/motoko/defi/src/frontend/src/components/CanisterIds.svelte b/archive/motoko/defi/src/frontend/src/components/CanisterIds.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/CanisterIds.svelte rename to archive/motoko/defi/src/frontend/src/components/CanisterIds.svelte diff --git a/motoko/defi/src/frontend/src/components/Links.svelte b/archive/motoko/defi/src/frontend/src/components/Links.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/Links.svelte rename to archive/motoko/defi/src/frontend/src/components/Links.svelte diff --git a/motoko/defi/src/frontend/src/components/Nav.svelte b/archive/motoko/defi/src/frontend/src/components/Nav.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/Nav.svelte rename to archive/motoko/defi/src/frontend/src/components/Nav.svelte diff --git a/motoko/defi/src/frontend/src/components/Orders.svelte b/archive/motoko/defi/src/frontend/src/components/Orders.svelte similarity index 100% rename from motoko/defi/src/frontend/src/components/Orders.svelte rename to archive/motoko/defi/src/frontend/src/components/Orders.svelte diff --git a/motoko/defi/src/frontend/src/main.js b/archive/motoko/defi/src/frontend/src/main.js similarity index 100% rename from motoko/defi/src/frontend/src/main.js rename to archive/motoko/defi/src/frontend/src/main.js diff --git a/motoko/defi/src/frontend/src/store/auth.js b/archive/motoko/defi/src/frontend/src/store/auth.js similarity index 100% rename from motoko/defi/src/frontend/src/store/auth.js rename to archive/motoko/defi/src/frontend/src/store/auth.js diff --git a/motoko/defi/src/frontend/src/store/order.js b/archive/motoko/defi/src/frontend/src/store/order.js similarity index 100% rename from motoko/defi/src/frontend/src/store/order.js rename to archive/motoko/defi/src/frontend/src/store/order.js diff --git a/motoko/defi/src/frontend/src/store/store.js b/archive/motoko/defi/src/frontend/src/store/store.js similarity index 100% rename from motoko/defi/src/frontend/src/store/store.js rename to archive/motoko/defi/src/frontend/src/store/store.js diff --git a/motoko/defi/src/frontend/src/utils/helpers.js b/archive/motoko/defi/src/frontend/src/utils/helpers.js similarity index 100% rename from motoko/defi/src/frontend/src/utils/helpers.js rename to archive/motoko/defi/src/frontend/src/utils/helpers.js diff --git a/motoko/defi/src/frontend_assets/favicon.png b/archive/motoko/defi/src/frontend_assets/favicon.png similarity index 100% rename from motoko/defi/src/frontend_assets/favicon.png rename to archive/motoko/defi/src/frontend_assets/favicon.png diff --git a/motoko/defi/src/frontend_assets/global.css b/archive/motoko/defi/src/frontend_assets/global.css similarity index 100% rename from motoko/defi/src/frontend_assets/global.css rename to archive/motoko/defi/src/frontend_assets/global.css diff --git a/motoko/defi/src/frontend_assets/images/dfinity.svg b/archive/motoko/defi/src/frontend_assets/images/dfinity.svg similarity index 100% rename from motoko/defi/src/frontend_assets/images/dfinity.svg rename to archive/motoko/defi/src/frontend_assets/images/dfinity.svg diff --git a/motoko/defi/src/frontend_assets/images/ic-badge.png b/archive/motoko/defi/src/frontend_assets/images/ic-badge.png similarity index 100% rename from motoko/defi/src/frontend_assets/images/ic-badge.png rename to archive/motoko/defi/src/frontend_assets/images/ic-badge.png diff --git a/motoko/defi/src/frontend_assets/images/plug_logo.png b/archive/motoko/defi/src/frontend_assets/images/plug_logo.png similarity index 100% rename from motoko/defi/src/frontend_assets/images/plug_logo.png rename to archive/motoko/defi/src/frontend_assets/images/plug_logo.png diff --git a/motoko/defi/src/frontend_assets/index.html b/archive/motoko/defi/src/frontend_assets/index.html similarity index 100% rename from motoko/defi/src/frontend_assets/index.html rename to archive/motoko/defi/src/frontend_assets/index.html diff --git a/motoko/defi/src/ledger/ledger.private.did b/archive/motoko/defi/src/ledger/ledger.private.did similarity index 100% rename from motoko/defi/src/ledger/ledger.private.did rename to archive/motoko/defi/src/ledger/ledger.private.did diff --git a/motoko/defi/src/ledger/ledger.public.did b/archive/motoko/defi/src/ledger/ledger.public.did similarity index 100% rename from motoko/defi/src/ledger/ledger.public.did rename to archive/motoko/defi/src/ledger/ledger.public.did diff --git a/motoko/defi/src/ledger/ledger.wasm b/archive/motoko/defi/src/ledger/ledger.wasm similarity index 100% rename from motoko/defi/src/ledger/ledger.wasm rename to archive/motoko/defi/src/ledger/ledger.wasm diff --git a/motoko/defi/src/ledger/ledger/index.d.ts b/archive/motoko/defi/src/ledger/ledger/index.d.ts similarity index 100% rename from motoko/defi/src/ledger/ledger/index.d.ts rename to archive/motoko/defi/src/ledger/ledger/index.d.ts diff --git a/motoko/defi/src/ledger/ledger/index.js b/archive/motoko/defi/src/ledger/ledger/index.js similarity index 100% rename from motoko/defi/src/ledger/ledger/index.js rename to archive/motoko/defi/src/ledger/ledger/index.js diff --git a/motoko/defi/src/ledger/ledger/ledger.did.d.ts b/archive/motoko/defi/src/ledger/ledger/ledger.did.d.ts similarity index 100% rename from motoko/defi/src/ledger/ledger/ledger.did.d.ts rename to archive/motoko/defi/src/ledger/ledger/ledger.did.d.ts diff --git a/motoko/defi/src/ledger/ledger/ledger.did.js b/archive/motoko/defi/src/ledger/ledger/ledger.did.js similarity index 100% rename from motoko/defi/src/ledger/ledger/ledger.did.js rename to archive/motoko/defi/src/ledger/ledger/ledger.did.js diff --git a/motoko/defi/test/demo.sh b/archive/motoko/defi/test/demo.sh similarity index 100% rename from motoko/defi/test/demo.sh rename to archive/motoko/defi/test/demo.sh diff --git a/motoko/defi/test/trade.sh b/archive/motoko/defi/test/trade.sh similarity index 100% rename from motoko/defi/test/trade.sh rename to archive/motoko/defi/test/trade.sh diff --git a/motoko/defi/test/transfer.sh b/archive/motoko/defi/test/transfer.sh similarity index 100% rename from motoko/defi/test/transfer.sh rename to archive/motoko/defi/test/transfer.sh diff --git a/motoko/dip721-nft-container/README.md b/archive/motoko/dip721-nft-container/README.md similarity index 100% rename from motoko/dip721-nft-container/README.md rename to archive/motoko/dip721-nft-container/README.md diff --git a/motoko/dip721-nft-container/demo.sh b/archive/motoko/dip721-nft-container/demo.sh similarity index 100% rename from motoko/dip721-nft-container/demo.sh rename to archive/motoko/dip721-nft-container/demo.sh diff --git a/motoko/dip721-nft-container/dfx.json b/archive/motoko/dip721-nft-container/dfx.json similarity index 100% rename from motoko/dip721-nft-container/dfx.json rename to archive/motoko/dip721-nft-container/dfx.json diff --git a/motoko/dip721-nft-container/src/Main.mo b/archive/motoko/dip721-nft-container/src/Main.mo similarity index 100% rename from motoko/dip721-nft-container/src/Main.mo rename to archive/motoko/dip721-nft-container/src/Main.mo diff --git a/motoko/dip721-nft-container/src/Types.mo b/archive/motoko/dip721-nft-container/src/Types.mo similarity index 100% rename from motoko/dip721-nft-container/src/Types.mo rename to archive/motoko/dip721-nft-container/src/Types.mo diff --git a/motoko/echo/Makefile b/archive/motoko/echo/Makefile similarity index 100% rename from motoko/echo/Makefile rename to archive/motoko/echo/Makefile diff --git a/motoko/echo/README.md b/archive/motoko/echo/README.md similarity index 100% rename from motoko/echo/README.md rename to archive/motoko/echo/README.md diff --git a/motoko/echo/dfx.json b/archive/motoko/echo/dfx.json similarity index 100% rename from motoko/echo/dfx.json rename to archive/motoko/echo/dfx.json diff --git a/motoko/echo/src/Main.mo b/archive/motoko/echo/src/Main.mo similarity index 100% rename from motoko/echo/src/Main.mo rename to archive/motoko/echo/src/Main.mo diff --git a/motoko/factorial/Makefile b/archive/motoko/factorial/Makefile similarity index 100% rename from motoko/factorial/Makefile rename to archive/motoko/factorial/Makefile diff --git a/motoko/factorial/README.md b/archive/motoko/factorial/README.md similarity index 100% rename from motoko/factorial/README.md rename to archive/motoko/factorial/README.md diff --git a/motoko/factorial/dfx.json b/archive/motoko/factorial/dfx.json similarity index 100% rename from motoko/factorial/dfx.json rename to archive/motoko/factorial/dfx.json diff --git a/motoko/factorial/src/Main.mo b/archive/motoko/factorial/src/Main.mo similarity index 100% rename from motoko/factorial/src/Main.mo rename to archive/motoko/factorial/src/Main.mo diff --git a/motoko/hello-world/Makefile b/archive/motoko/hello-world/Makefile similarity index 100% rename from motoko/hello-world/Makefile rename to archive/motoko/hello-world/Makefile diff --git a/motoko/hello-world/README.md b/archive/motoko/hello-world/README.md similarity index 100% rename from motoko/hello-world/README.md rename to archive/motoko/hello-world/README.md diff --git a/motoko/hello-world/dfx.json b/archive/motoko/hello-world/dfx.json similarity index 100% rename from motoko/hello-world/dfx.json rename to archive/motoko/hello-world/dfx.json diff --git a/motoko/hello-world/ii.did b/archive/motoko/hello-world/ii.did similarity index 100% rename from motoko/hello-world/ii.did rename to archive/motoko/hello-world/ii.did diff --git a/motoko/hello-world/src/Main.mo b/archive/motoko/hello-world/src/Main.mo similarity index 100% rename from motoko/hello-world/src/Main.mo rename to archive/motoko/hello-world/src/Main.mo diff --git a/motoko/hello-world/src/declarations/hello_world/hello_world.did b/archive/motoko/hello-world/src/declarations/hello_world/hello_world.did similarity index 100% rename from motoko/hello-world/src/declarations/hello_world/hello_world.did rename to archive/motoko/hello-world/src/declarations/hello_world/hello_world.did diff --git a/motoko/hello-world/src/declarations/hello_world/hello_world.did.d.ts b/archive/motoko/hello-world/src/declarations/hello_world/hello_world.did.d.ts similarity index 100% rename from motoko/hello-world/src/declarations/hello_world/hello_world.did.d.ts rename to archive/motoko/hello-world/src/declarations/hello_world/hello_world.did.d.ts diff --git a/motoko/hello-world/src/declarations/hello_world/hello_world.did.js b/archive/motoko/hello-world/src/declarations/hello_world/hello_world.did.js similarity index 100% rename from motoko/hello-world/src/declarations/hello_world/hello_world.did.js rename to archive/motoko/hello-world/src/declarations/hello_world/hello_world.did.js diff --git a/motoko/hello-world/src/declarations/hello_world/index.d.ts b/archive/motoko/hello-world/src/declarations/hello_world/index.d.ts similarity index 100% rename from motoko/hello-world/src/declarations/hello_world/index.d.ts rename to archive/motoko/hello-world/src/declarations/hello_world/index.d.ts diff --git a/motoko/hello-world/src/declarations/hello_world/index.js b/archive/motoko/hello-world/src/declarations/hello_world/index.js similarity index 100% rename from motoko/hello-world/src/declarations/hello_world/index.js rename to archive/motoko/hello-world/src/declarations/hello_world/index.js diff --git a/motoko/hello/Makefile b/archive/motoko/hello/Makefile similarity index 100% rename from motoko/hello/Makefile rename to archive/motoko/hello/Makefile diff --git a/motoko/hello/README.md b/archive/motoko/hello/README.md similarity index 100% rename from motoko/hello/README.md rename to archive/motoko/hello/README.md diff --git a/motoko/hello/dfx.json b/archive/motoko/hello/dfx.json similarity index 100% rename from motoko/hello/dfx.json rename to archive/motoko/hello/dfx.json diff --git a/motoko/hello/package-lock.json b/archive/motoko/hello/package-lock.json similarity index 100% rename from motoko/hello/package-lock.json rename to archive/motoko/hello/package-lock.json diff --git a/motoko/hello/package.json b/archive/motoko/hello/package.json similarity index 100% rename from motoko/hello/package.json rename to archive/motoko/hello/package.json diff --git a/motoko/hello/src/hello/main.mo b/archive/motoko/hello/src/hello/main.mo similarity index 100% rename from motoko/hello/src/hello/main.mo rename to archive/motoko/hello/src/hello/main.mo diff --git a/motoko/hello/src/hello_assets/assets/favicon.ico b/archive/motoko/hello/src/hello_assets/assets/favicon.ico similarity index 100% rename from motoko/hello/src/hello_assets/assets/favicon.ico rename to archive/motoko/hello/src/hello_assets/assets/favicon.ico diff --git a/motoko/hello/src/hello_assets/assets/logo.png b/archive/motoko/hello/src/hello_assets/assets/logo.png similarity index 100% rename from motoko/hello/src/hello_assets/assets/logo.png rename to archive/motoko/hello/src/hello_assets/assets/logo.png diff --git a/motoko/hello/src/hello_assets/assets/main.css b/archive/motoko/hello/src/hello_assets/assets/main.css similarity index 100% rename from motoko/hello/src/hello_assets/assets/main.css rename to archive/motoko/hello/src/hello_assets/assets/main.css diff --git a/motoko/hello/src/hello_assets/assets/sample-asset.txt b/archive/motoko/hello/src/hello_assets/assets/sample-asset.txt similarity index 100% rename from motoko/hello/src/hello_assets/assets/sample-asset.txt rename to archive/motoko/hello/src/hello_assets/assets/sample-asset.txt diff --git a/motoko/hello/src/hello_assets/src/index.html b/archive/motoko/hello/src/hello_assets/src/index.html similarity index 100% rename from motoko/hello/src/hello_assets/src/index.html rename to archive/motoko/hello/src/hello_assets/src/index.html diff --git a/motoko/hello/src/hello_assets/src/index.js b/archive/motoko/hello/src/hello_assets/src/index.js similarity index 100% rename from motoko/hello/src/hello_assets/src/index.js rename to archive/motoko/hello/src/hello_assets/src/index.js diff --git a/motoko/hello/webpack.config.js b/archive/motoko/hello/webpack.config.js similarity index 100% rename from motoko/hello/webpack.config.js rename to archive/motoko/hello/webpack.config.js diff --git a/motoko/icp_transfer/.gitignore b/archive/motoko/icp_transfer/.gitignore similarity index 100% rename from motoko/icp_transfer/.gitignore rename to archive/motoko/icp_transfer/.gitignore diff --git a/motoko/icp_transfer/README.md b/archive/motoko/icp_transfer/README.md similarity index 100% rename from motoko/icp_transfer/README.md rename to archive/motoko/icp_transfer/README.md diff --git a/motoko/icp_transfer/demo.sh b/archive/motoko/icp_transfer/demo.sh similarity index 100% rename from motoko/icp_transfer/demo.sh rename to archive/motoko/icp_transfer/demo.sh diff --git a/motoko/icp_transfer/dfx.json b/archive/motoko/icp_transfer/dfx.json similarity index 100% rename from motoko/icp_transfer/dfx.json rename to archive/motoko/icp_transfer/dfx.json diff --git a/motoko/icp_transfer/src/icp_transfer_backend/main.mo b/archive/motoko/icp_transfer/src/icp_transfer_backend/main.mo similarity index 100% rename from motoko/icp_transfer/src/icp_transfer_backend/main.mo rename to archive/motoko/icp_transfer/src/icp_transfer_backend/main.mo diff --git a/motoko/ios-notifications/.gitignore b/archive/motoko/ios-notifications/.gitignore similarity index 100% rename from motoko/ios-notifications/.gitignore rename to archive/motoko/ios-notifications/.gitignore diff --git a/motoko/ios-notifications/README.md b/archive/motoko/ios-notifications/README.md similarity index 100% rename from motoko/ios-notifications/README.md rename to archive/motoko/ios-notifications/README.md diff --git a/motoko/ios-notifications/dapp-demo/.gitignore b/archive/motoko/ios-notifications/dapp-demo/.gitignore similarity index 100% rename from motoko/ios-notifications/dapp-demo/.gitignore rename to archive/motoko/ios-notifications/dapp-demo/.gitignore diff --git a/motoko/ios-notifications/dapp-demo/Makefile b/archive/motoko/ios-notifications/dapp-demo/Makefile similarity index 100% rename from motoko/ios-notifications/dapp-demo/Makefile rename to archive/motoko/ios-notifications/dapp-demo/Makefile diff --git a/motoko/ios-notifications/dapp-demo/README.md b/archive/motoko/ios-notifications/dapp-demo/README.md similarity index 100% rename from motoko/ios-notifications/dapp-demo/README.md rename to archive/motoko/ios-notifications/dapp-demo/README.md diff --git a/motoko/ios-notifications/dapp-demo/canister_ids.json b/archive/motoko/ios-notifications/dapp-demo/canister_ids.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/canister_ids.json rename to archive/motoko/ios-notifications/dapp-demo/canister_ids.json diff --git a/motoko/ios-notifications/dapp-demo/dfx.json b/archive/motoko/ios-notifications/dapp-demo/dfx.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/dfx.json rename to archive/motoko/ios-notifications/dapp-demo/dfx.json diff --git a/motoko/ios-notifications/dapp-demo/package-lock.json b/archive/motoko/ios-notifications/dapp-demo/package-lock.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/package-lock.json rename to archive/motoko/ios-notifications/dapp-demo/package-lock.json diff --git a/motoko/ios-notifications/dapp-demo/package.json b/archive/motoko/ios-notifications/dapp-demo/package.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/package.json rename to archive/motoko/ios-notifications/dapp-demo/package.json diff --git a/motoko/ios-notifications/dapp-demo/src/api/main.mo b/archive/motoko/ios-notifications/dapp-demo/src/api/main.mo similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/api/main.mo rename to archive/motoko/ios-notifications/dapp-demo/src/api/main.mo diff --git a/motoko/ios-notifications/dapp-demo/src/www/assets/.ic-assets.json b/archive/motoko/ios-notifications/dapp-demo/src/www/assets/.ic-assets.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/assets/.ic-assets.json rename to archive/motoko/ios-notifications/dapp-demo/src/www/assets/.ic-assets.json diff --git a/motoko/ios-notifications/dapp-demo/src/www/assets/.well-known/apple-app-site-association b/archive/motoko/ios-notifications/dapp-demo/src/www/assets/.well-known/apple-app-site-association similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/assets/.well-known/apple-app-site-association rename to archive/motoko/ios-notifications/dapp-demo/src/www/assets/.well-known/apple-app-site-association diff --git a/motoko/ios-notifications/dapp-demo/src/www/assets/main.css b/archive/motoko/ios-notifications/dapp-demo/src/www/assets/main.css similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/assets/main.css rename to archive/motoko/ios-notifications/dapp-demo/src/www/assets/main.css diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/auth.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/auth.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/auth.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/auth.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/index.html b/archive/motoko/ios-notifications/dapp-demo/src/www/src/index.html similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/index.html rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/index.html diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/index.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/index.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/index.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/index.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/pages/about.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/about.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/pages/about.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/about.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/pages/home.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/home.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/pages/home.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/home.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/pages/index.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/index.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/pages/index.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/index.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/pages/login.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/login.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/pages/login.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/pages/login.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/router.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/router.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/router.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/router.ts diff --git a/motoko/ios-notifications/dapp-demo/src/www/src/types.ts b/archive/motoko/ios-notifications/dapp-demo/src/www/src/types.ts similarity index 100% rename from motoko/ios-notifications/dapp-demo/src/www/src/types.ts rename to archive/motoko/ios-notifications/dapp-demo/src/www/src/types.ts diff --git a/motoko/ios-notifications/dapp-demo/test_api.sh b/archive/motoko/ios-notifications/dapp-demo/test_api.sh similarity index 100% rename from motoko/ios-notifications/dapp-demo/test_api.sh rename to archive/motoko/ios-notifications/dapp-demo/test_api.sh diff --git a/motoko/ios-notifications/dapp-demo/tsconfig.json b/archive/motoko/ios-notifications/dapp-demo/tsconfig.json similarity index 100% rename from motoko/ios-notifications/dapp-demo/tsconfig.json rename to archive/motoko/ios-notifications/dapp-demo/tsconfig.json diff --git a/motoko/ios-notifications/dapp-demo/webpack.config.js b/archive/motoko/ios-notifications/dapp-demo/webpack.config.js similarity index 100% rename from motoko/ios-notifications/dapp-demo/webpack.config.js rename to archive/motoko/ios-notifications/dapp-demo/webpack.config.js diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample-Info.plist b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample-Info.plist similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample-Info.plist rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample-Info.plist diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.pbxproj b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.pbxproj similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.pbxproj rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.pbxproj diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AccentColor.colorset/Contents.json b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AccentColor.colorset/Contents.json similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AccentColor.colorset/Contents.json rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AccentColor.colorset/Contents.json diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AppIcon.appiconset/Contents.json b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AppIcon.appiconset/Contents.json similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AppIcon.appiconset/Contents.json rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/AppIcon.appiconset/Contents.json diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/Contents.json b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/Contents.json similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/Contents.json rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Assets.xcassets/Contents.json diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/ContentView.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/ContentView.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/ContentView.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/ContentView.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/DApp.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DApp.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/DApp.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DApp.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppDelegate.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppDelegate.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppDelegate.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppDelegate.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppExample.entitlements b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppExample.entitlements similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppExample.entitlements rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppExample.entitlements diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppWebView.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppWebView.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppWebView.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DAppWebView.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/DappConfig.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DappConfig.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/DappConfig.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/DappConfig.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/IdentityKeyPair.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/IdentityKeyPair.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/IdentityKeyPair.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/IdentityKeyPair.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoadingScreen.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoadingScreen.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/LoadingScreen.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoadingScreen.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoginSession.swift b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoginSession.swift similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/LoginSession.swift rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/LoginSession.swift diff --git a/motoko/ios-notifications/ios-dapp-demo/DAppExample/Preview Content/Preview Assets.xcassets/Contents.json b/archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Preview Content/Preview Assets.xcassets/Contents.json similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/DAppExample/Preview Content/Preview Assets.xcassets/Contents.json rename to archive/motoko/ios-notifications/ios-dapp-demo/DAppExample/Preview Content/Preview Assets.xcassets/Contents.json diff --git a/motoko/ios-notifications/ios-dapp-demo/README.md b/archive/motoko/ios-notifications/ios-dapp-demo/README.md similarity index 100% rename from motoko/ios-notifications/ios-dapp-demo/README.md rename to archive/motoko/ios-notifications/ios-dapp-demo/README.md diff --git a/motoko/ios-notifications/send-notification.sh b/archive/motoko/ios-notifications/send-notification.sh similarity index 100% rename from motoko/ios-notifications/send-notification.sh rename to archive/motoko/ios-notifications/send-notification.sh diff --git a/motoko/persistent-storage/Makefile b/archive/motoko/persistent-storage/Makefile similarity index 100% rename from motoko/persistent-storage/Makefile rename to archive/motoko/persistent-storage/Makefile diff --git a/motoko/persistent-storage/README.md b/archive/motoko/persistent-storage/README.md similarity index 100% rename from motoko/persistent-storage/README.md rename to archive/motoko/persistent-storage/README.md diff --git a/motoko/persistent-storage/README_images/candid_ui.png b/archive/motoko/persistent-storage/README_images/candid_ui.png similarity index 100% rename from motoko/persistent-storage/README_images/candid_ui.png rename to archive/motoko/persistent-storage/README_images/candid_ui.png diff --git a/motoko/persistent-storage/dfx.json b/archive/motoko/persistent-storage/dfx.json similarity index 100% rename from motoko/persistent-storage/dfx.json rename to archive/motoko/persistent-storage/dfx.json diff --git a/motoko/persistent-storage/src/persistent_storage/main.mo b/archive/motoko/persistent-storage/src/persistent_storage/main.mo similarity index 100% rename from motoko/persistent-storage/src/persistent_storage/main.mo rename to archive/motoko/persistent-storage/src/persistent_storage/main.mo diff --git a/motoko/phone-book/Makefile b/archive/motoko/phone-book/Makefile similarity index 100% rename from motoko/phone-book/Makefile rename to archive/motoko/phone-book/Makefile diff --git a/motoko/phone-book/README.md b/archive/motoko/phone-book/README.md similarity index 100% rename from motoko/phone-book/README.md rename to archive/motoko/phone-book/README.md diff --git a/motoko/phone-book/dfx.json b/archive/motoko/phone-book/dfx.json similarity index 100% rename from motoko/phone-book/dfx.json rename to archive/motoko/phone-book/dfx.json diff --git a/motoko/phone-book/package-lock.json b/archive/motoko/phone-book/package-lock.json similarity index 100% rename from motoko/phone-book/package-lock.json rename to archive/motoko/phone-book/package-lock.json diff --git a/motoko/phone-book/package.json b/archive/motoko/phone-book/package.json similarity index 100% rename from motoko/phone-book/package.json rename to archive/motoko/phone-book/package.json diff --git a/motoko/phone-book/src/declarations/phone_book/index.d.ts b/archive/motoko/phone-book/src/declarations/phone_book/index.d.ts similarity index 100% rename from motoko/phone-book/src/declarations/phone_book/index.d.ts rename to archive/motoko/phone-book/src/declarations/phone_book/index.d.ts diff --git a/motoko/phone-book/src/declarations/phone_book/index.js b/archive/motoko/phone-book/src/declarations/phone_book/index.js similarity index 100% rename from motoko/phone-book/src/declarations/phone_book/index.js rename to archive/motoko/phone-book/src/declarations/phone_book/index.js diff --git a/motoko/phone-book/src/declarations/phone_book/phone_book.did b/archive/motoko/phone-book/src/declarations/phone_book/phone_book.did similarity index 100% rename from motoko/phone-book/src/declarations/phone_book/phone_book.did rename to archive/motoko/phone-book/src/declarations/phone_book/phone_book.did diff --git a/motoko/phone-book/src/declarations/phone_book/phone_book.did.d.ts b/archive/motoko/phone-book/src/declarations/phone_book/phone_book.did.d.ts similarity index 100% rename from motoko/phone-book/src/declarations/phone_book/phone_book.did.d.ts rename to archive/motoko/phone-book/src/declarations/phone_book/phone_book.did.d.ts diff --git a/motoko/phone-book/src/declarations/phone_book/phone_book.did.js b/archive/motoko/phone-book/src/declarations/phone_book/phone_book.did.js similarity index 100% rename from motoko/phone-book/src/declarations/phone_book/phone_book.did.js rename to archive/motoko/phone-book/src/declarations/phone_book/phone_book.did.js diff --git a/motoko/phone-book/src/phone-book/Main.mo b/archive/motoko/phone-book/src/phone-book/Main.mo similarity index 100% rename from motoko/phone-book/src/phone-book/Main.mo rename to archive/motoko/phone-book/src/phone-book/Main.mo diff --git a/motoko/phone-book/src/www/assets/sample-asset.txt b/archive/motoko/phone-book/src/www/assets/sample-asset.txt similarity index 100% rename from motoko/phone-book/src/www/assets/sample-asset.txt rename to archive/motoko/phone-book/src/www/assets/sample-asset.txt diff --git a/motoko/phone-book/src/www/src/index.html b/archive/motoko/phone-book/src/www/src/index.html similarity index 100% rename from motoko/phone-book/src/www/src/index.html rename to archive/motoko/phone-book/src/www/src/index.html diff --git a/motoko/phone-book/src/www/src/index.jsx b/archive/motoko/phone-book/src/www/src/index.jsx similarity index 100% rename from motoko/phone-book/src/www/src/index.jsx rename to archive/motoko/phone-book/src/www/src/index.jsx diff --git a/motoko/phone-book/tsconfig.json b/archive/motoko/phone-book/tsconfig.json similarity index 100% rename from motoko/phone-book/tsconfig.json rename to archive/motoko/phone-book/tsconfig.json diff --git a/motoko/phone-book/webpack.config.js b/archive/motoko/phone-book/webpack.config.js similarity index 100% rename from motoko/phone-book/webpack.config.js rename to archive/motoko/phone-book/webpack.config.js diff --git a/motoko/quicksort/Makefile b/archive/motoko/quicksort/Makefile similarity index 100% rename from motoko/quicksort/Makefile rename to archive/motoko/quicksort/Makefile diff --git a/motoko/quicksort/README.md b/archive/motoko/quicksort/README.md similarity index 100% rename from motoko/quicksort/README.md rename to archive/motoko/quicksort/README.md diff --git a/motoko/quicksort/dfx.json b/archive/motoko/quicksort/dfx.json similarity index 100% rename from motoko/quicksort/dfx.json rename to archive/motoko/quicksort/dfx.json diff --git a/motoko/quicksort/src/Main.mo b/archive/motoko/quicksort/src/Main.mo similarity index 100% rename from motoko/quicksort/src/Main.mo rename to archive/motoko/quicksort/src/Main.mo diff --git a/motoko/quicksort/src/Quicksort.mo b/archive/motoko/quicksort/src/Quicksort.mo similarity index 100% rename from motoko/quicksort/src/Quicksort.mo rename to archive/motoko/quicksort/src/Quicksort.mo diff --git a/motoko/simple-to-do/Makefile b/archive/motoko/simple-to-do/Makefile similarity index 100% rename from motoko/simple-to-do/Makefile rename to archive/motoko/simple-to-do/Makefile diff --git a/motoko/simple-to-do/README.md b/archive/motoko/simple-to-do/README.md similarity index 100% rename from motoko/simple-to-do/README.md rename to archive/motoko/simple-to-do/README.md diff --git a/motoko/simple-to-do/dfx.json b/archive/motoko/simple-to-do/dfx.json similarity index 100% rename from motoko/simple-to-do/dfx.json rename to archive/motoko/simple-to-do/dfx.json diff --git a/motoko/simple-to-do/src/Main.mo b/archive/motoko/simple-to-do/src/Main.mo similarity index 100% rename from motoko/simple-to-do/src/Main.mo rename to archive/motoko/simple-to-do/src/Main.mo diff --git a/motoko/defi/src/DIP20 b/motoko/defi/src/DIP20 deleted file mode 160000 index 1d4b92781..000000000 --- a/motoko/defi/src/DIP20 +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 1d4b92781e46cee528e52f578c55e384561f380a diff --git a/motoko/defi/src/ledger/ledger.did b/motoko/defi/src/ledger/ledger.did deleted file mode 100644 index 26adbe583..000000000 --- a/motoko/defi/src/ledger/ledger.did +++ /dev/null @@ -1,87 +0,0 @@ -// This is the official Ledger interface that is guaranteed to be backward compatible. - -// Amount of tokens, measured in 10^-8 of a token. -type Tokens = record { - e8s : nat64; -}; - -// Number of nanoseconds from the UNIX epoch in UTC timezone. -type TimeStamp = record { - timestamp_nanos: nat64; -}; - -// AccountIdentifier is a 32-byte array. -// The first 4 bytes is big-endian encoding of a CRC32 checksum of the last 28 bytes. -type AccountIdentifier = blob; - -// Subaccount is an arbitrary 32-byte byte array. -// Ledger uses subaccounts to compute the source address, which enables one -// principal to control multiple ledger accounts. -type SubAccount = blob; - -// Sequence number of a block produced by the ledger. -type BlockIndex = nat64; - -// An arbitrary number associated with a transaction. -// The caller can set it in a `transfer` call as a correlation identifier. -type Memo = nat64; - -// Arguments for the `transfer` call. -type TransferArgs = record { - // Transaction memo. - // See comments for the `Memo` type. - memo: Memo; - // The amount that the caller wants to transfer to the destination address. - amount: Tokens; - // The amount that the caller pays for the transaction. - // Must be 10000 e8s. - fee: Tokens; - // The subaccount from which the caller wants to transfer funds. - // If null, the ledger uses the default (all zeros) subaccount to compute the source address. - // See comments for the `SubAccount` type. - from_subaccount: opt SubAccount; - // The destination account. - // If the transfer is successful, the balance of this address increases by `amount`. - to: AccountIdentifier; - // The point in time when the caller created this request. - // If null, the ledger uses current IC time as the timestamp. - created_at_time: opt TimeStamp; -}; - -type TransferError = variant { - // The fee that the caller specified in the transfer request was not the one that ledger expects. - // The caller can change the transfer fee to the `expected_fee` and retry the request. - BadFee : record { expected_fee : Tokens; }; - // The account specified by the caller doesn't have enough funds. - InsufficientFunds : record { balance: Tokens; }; - // The request is too old. - // The ledger only accepts requests created within 24 hours window. - // This is a non-recoverable error. - TxTooOld : record { allowed_window_nanos: nat64 }; - // The caller specified `created_at_time` that is too far in future. - // The caller can retry the request later. - TxCreatedInFuture : null; - // The ledger has already executed the request. - // `duplicate_of` field is equal to the index of the block containing the original transaction. - TxDuplicate : record { duplicate_of: BlockIndex; } -}; - -type TransferResult = variant { - Ok : BlockIndex; - Err : TransferError; -}; - -// Arguments for the `account_balance` call. -type AccountBalanceArgs = record { - account: AccountIdentifier; -}; - -service : { - // Transfers tokens from a subaccount of the caller to the destination address. - // The source address is computed from the principal of the caller and the specified subaccount. - // When successful, returns the index of the block containing the transaction. - transfer : (TransferArgs) -> (TransferResult); - - // Returns the amount of Tokens on the specified account. - account_balance : (AccountBalanceArgs) -> (Tokens) query; -} From e4d3b6faa1d3901bbd53e78786387b8150c775c7 Mon Sep 17 00:00:00 2001 From: Jessie Mongeon Date: Fri, 20 Sep 2024 15:42:40 -0500 Subject: [PATCH 33/35] Archive examples 2 --- .github/CODEOWNERS | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 636f03085..1acc7bb2d 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -9,43 +9,28 @@ /hosting/static-website/ @dfinity/sdk /hosting/unity-webgl-template/ @dfinity/sdk -/motoko/actor_reference/ @dfinity/languages -/motoko/auth_client_demo/ @dfinity/sdk /motoko/basic_bitcoin/ @dfinity/execution /motoko/basic_dao/ @dfinity/languages -/motoko/calc/ @dfinity/languages /motoko/canister_logs/ @dfinity/execution /motoko/cert-var/ @dfinity/trust /motoko/classes/ @dfinity/languages /motoko/composite_query/ @dfinity/languages /motoko/counter/ @dfinity/languages -/motoko/defi/ @dfinity/networking -/motoko/dip721-nft-container/ @dfinity/languages -/motoko/echo/ @dfinity/languages /motoko/encrypted-notes-dapp-vetkd/ @dfinity/crypto-team /motoko/encrypted-notes-dapp/ @dfinity/crypto-team -/motoko/factorial/ @dfinity/languages -/motoko/hello-world/ @dfinity/languages -/motoko/hello/ @dfinity/languages /motoko/hello_cycles/ @dfinity/languages /motoko/http_counter/ @dfinity/networking /motoko/ic-pos/ @dfinity/div-Crypto -/motoko/icp_transfer/ @dfinity/growth /motoko/icrc2-swap/ @dfinity/div-Crypto /motoko/internet_identity_integration/ @dfinity/gix -/motoko/ios-notifications/ @dfinity/trust /motoko/life/ @dfinity/languages /motoko/minimal-counter-dapp/ @dfinity/growth /motoko/parallel_calls/ @dfinity/languages -/motoko/persistent-storage/ @dfinity/growth -/motoko/phone-book/ @dfinity/growth /motoko/pub-sub/ @dfinity/growth /motoko/query_stats/ @dfinity/sdk -/motoko/quicksort/ @dfinity/growth /motoko/random_maze/ @dfinity/languages /motoko/send_http_get/ @dfinity/networking /motoko/send_http_post/ @dfinity/networking -/motoko/simple-to-do/ @dfinity/growth /motoko/superheroes/ @dfinity/growth /motoko/threshold-ecdsa/ @dfinity/crypto-team /motoko/threshold-schnorr/ @dfinity/crypto-team From f98325c17ac3270b22462a2814761d028257bfa1 Mon Sep 17 00:00:00 2001 From: Jessie Mongeon Date: Mon, 23 Sep 2024 15:26:41 -0500 Subject: [PATCH 34/35] Update on-chain -> onchain --- archive/motoko/defi/src/ledger/ledger.did | 87 +++++++++++++++++++ motoko/defi/README.md | 8 +- motoko/defi/architecture.md | 8 +- rust/defi/README.md | 8 +- rust/dip721-nft-container/README.md | 14 +-- .../src/frontend/src/index.html | 4 +- svelte/svelte-motoko-starter/README.md | 4 +- svelte/svelte-starter/README.md | 4 +- 8 files changed, 112 insertions(+), 25 deletions(-) create mode 100644 archive/motoko/defi/src/ledger/ledger.did diff --git a/archive/motoko/defi/src/ledger/ledger.did b/archive/motoko/defi/src/ledger/ledger.did new file mode 100644 index 000000000..26adbe583 --- /dev/null +++ b/archive/motoko/defi/src/ledger/ledger.did @@ -0,0 +1,87 @@ +// This is the official Ledger interface that is guaranteed to be backward compatible. + +// Amount of tokens, measured in 10^-8 of a token. +type Tokens = record { + e8s : nat64; +}; + +// Number of nanoseconds from the UNIX epoch in UTC timezone. +type TimeStamp = record { + timestamp_nanos: nat64; +}; + +// AccountIdentifier is a 32-byte array. +// The first 4 bytes is big-endian encoding of a CRC32 checksum of the last 28 bytes. +type AccountIdentifier = blob; + +// Subaccount is an arbitrary 32-byte byte array. +// Ledger uses subaccounts to compute the source address, which enables one +// principal to control multiple ledger accounts. +type SubAccount = blob; + +// Sequence number of a block produced by the ledger. +type BlockIndex = nat64; + +// An arbitrary number associated with a transaction. +// The caller can set it in a `transfer` call as a correlation identifier. +type Memo = nat64; + +// Arguments for the `transfer` call. +type TransferArgs = record { + // Transaction memo. + // See comments for the `Memo` type. + memo: Memo; + // The amount that the caller wants to transfer to the destination address. + amount: Tokens; + // The amount that the caller pays for the transaction. + // Must be 10000 e8s. + fee: Tokens; + // The subaccount from which the caller wants to transfer funds. + // If null, the ledger uses the default (all zeros) subaccount to compute the source address. + // See comments for the `SubAccount` type. + from_subaccount: opt SubAccount; + // The destination account. + // If the transfer is successful, the balance of this address increases by `amount`. + to: AccountIdentifier; + // The point in time when the caller created this request. + // If null, the ledger uses current IC time as the timestamp. + created_at_time: opt TimeStamp; +}; + +type TransferError = variant { + // The fee that the caller specified in the transfer request was not the one that ledger expects. + // The caller can change the transfer fee to the `expected_fee` and retry the request. + BadFee : record { expected_fee : Tokens; }; + // The account specified by the caller doesn't have enough funds. + InsufficientFunds : record { balance: Tokens; }; + // The request is too old. + // The ledger only accepts requests created within 24 hours window. + // This is a non-recoverable error. + TxTooOld : record { allowed_window_nanos: nat64 }; + // The caller specified `created_at_time` that is too far in future. + // The caller can retry the request later. + TxCreatedInFuture : null; + // The ledger has already executed the request. + // `duplicate_of` field is equal to the index of the block containing the original transaction. + TxDuplicate : record { duplicate_of: BlockIndex; } +}; + +type TransferResult = variant { + Ok : BlockIndex; + Err : TransferError; +}; + +// Arguments for the `account_balance` call. +type AccountBalanceArgs = record { + account: AccountIdentifier; +}; + +service : { + // Transfers tokens from a subaccount of the caller to the destination address. + // The source address is computed from the principal of the caller and the specified subaccount. + // When successful, returns the index of the block containing the transaction. + transfer : (TransferArgs) -> (TransferResult); + + // Returns the amount of Tokens on the specified account. + account_balance : (AccountBalanceArgs) -> (Tokens) query; +} diff --git a/motoko/defi/README.md b/motoko/defi/README.md index 1248f4967..02d559f59 100644 --- a/motoko/defi/README.md +++ b/motoko/defi/README.md @@ -14,7 +14,7 @@ The sample exchange is implemented in [Motoko](https://github.com/dfinity/exampl ## Architecture -The design of the IC allows for more complex on-chain computation. In combination with cheap storage, it is possible to have on-chain order books. This sample code takes advantage of these features and stores user balances and orders inside the exchange canister. The sample exchange functionality can be condensed into the following steps: +The design of the IC allows for more complex onchain computation. In combination with cheap storage, it is possible to have onchain order books. This sample code takes advantage of these features and stores user balances and orders inside the exchange canister. The sample exchange functionality can be condensed into the following steps: - Exchange takes custody of funds (different mechanism for tokens and ICP, see below). @@ -78,7 +78,7 @@ There are a number of token standards in development (e.g. IS20, DFT, and DRC20) ### Placing orders -After depositing funds to the exchange, the user can place orders. An order consists of two tuples. `from: (Token1, amount1)` and `to: (Token2, amount2)`. These orders get added to the exchange. What happens to these orders is specific to the exchange implementation. This sample provides a simple exchange that only executes exactly matching orders. Be aware this is just a toy exchange, and the exchange functionality is just for completeness. +After depositing funds to the exchange, the user can place orders. An order consists of two tuples. `from: (Token1, amount1)` and `to: (Token2, amount2)`. These orders get added to the exchange. What happens to these orders is specific to the exchange implementation. This sample provides a simple exchange that only executes exactly matching orders. Be aware this is just a toy exchange, and the exchange functionality is just for completeness. ### Withdrawing funds @@ -112,7 +112,7 @@ or you can regenerate the URL `http://127.0.0.1:4943?canisterId=$(dfx canister i ### Step 2: To interact with the exchange, you can create a local Internet Identity by clicking the login button. -This sample project uses a local test version of Internet Identity. Do not use your mainnet Internet Identity, and this testnet Internet Identity will not work on the mainnet. +This sample project uses a local test version of Internet Identity. Do not use your mainnet Internet Identity, and this testnet Internet Identity will not work on the mainnet. ### Step 3: When prompted, select **Create Internet Identity**. @@ -130,7 +130,7 @@ This sample project uses a local test version of Internet Identity. Do not use y `make init-local II_PRINCIPAL=` -### Step 10: Refresh the web browser to verify that your tokens were deposited. +### Step 10: Refresh the web browser to verify that your tokens were deposited. To trade tokens with yourself, you can open a second incognito browser window. diff --git a/motoko/defi/architecture.md b/motoko/defi/architecture.md index 8752cf9c7..b35d38236 100644 --- a/motoko/defi/architecture.md +++ b/motoko/defi/architecture.md @@ -4,7 +4,7 @@ To enable DEFI application on the IC, canisters need to interact with token cani ## Architecture -The design of the IC allows for more complex on-chain computation. In combination with cheap storage, it is possible to have on-chain order books. This example takes advantage of these features and stores user balances and orders inside the exchange canister. The example exchange functionality can be condensed into the following steps: +The design of the IC allows for more complex onchain computation. In combination with cheap storage, it is possible to have onchain order books. This example takes advantage of these features and stores user balances and orders inside the exchange canister. The example exchange functionality can be condensed into the following steps: 1. Exchange takes custody of funds (different mechanism for tokens and ICP, see below). 2. Exchange updates internal balance book. @@ -13,7 +13,7 @@ The design of the IC allows for more complex on-chain computation. In combinatio ### Interface -Request user-specific ledger account identifier from the exchange. This unique account identifier represents a user-specific subaccount in the exchange's ledger account, allowing it to differentiate between user deposits. +Request user-specific ledger account identifier from the exchange. This unique account identifier represents a user-specific subaccount in the exchange's ledger account, allowing it to differentiate between user deposits. ``` getDepositAddress: () -> (blob); ``` @@ -25,7 +25,7 @@ Withdraw request to the exchange. The exchange will send funds back to the user ``` withdraw: (Token, nat, principal) -> (WithdrawReceipt); ``` -Place new order to exchange. If the order matches an existing order, it will get executed. +Place new order to exchange. If the order matches an existing order, it will get executed. ``` placeOrder: (Token, nat, Token, nat) -> (OrderPlacementReceipt); ``` @@ -72,5 +72,5 @@ Compared to depositing funds, withdrawing funds is simpler. Since the exchange h ## Common mistakes - **Concurrent execution**: If canister functions have `await` statements, it is possible that execution is interleaved. To avoid bugs, it is necessary to carefully consider the placement of data structure updates to prevent double-spend attacks. -- **Floating Points**: More advanced exchanges should take care of floating points and make sure to limit decimals. +- **Floating Points**: More advanced exchanges should take care of floating points and make sure to limit decimals. - **No panics after await**: When a panic happens, the state gets rolled back. This can cause issues with the correctness of the exchange. diff --git a/rust/defi/README.md b/rust/defi/README.md index 34b10b990..8d2b6a6a4 100644 --- a/rust/defi/README.md +++ b/rust/defi/README.md @@ -8,7 +8,7 @@ The sample exchange is implemented in [Motoko](https://github.com/dfinity/exampl ## Architecture -The design of the IC allows for more complex on-chain computation. In combination with cheap storage, it is possible to have on-chain order books. This sample code takes advantage of these features and stores user balances and orders inside the exchange canister. The sample exchange functionality can be condensed into the following steps: +The design of the IC allows for more complex onchain computation. In combination with cheap storage, it is possible to have onchain order books. This sample code takes advantage of these features and stores user balances and orders inside the exchange canister. The sample exchange functionality can be condensed into the following steps: - Exchange takes custody of funds (different mechanism for tokens and ICP, see below). @@ -72,7 +72,7 @@ There are a number of token standards in development (e.g. IS20, DFT, and DRC20) ### Placing orders -After depositing funds to the exchange, the user can place orders. An order consists of two tuples. `from: (Token1, amount1)` and `to: (Token2, amount2)`. These orders get added to the exchange. What happens to these orders is specific to the exchange implementation. This sample provides a simple exchange that only executes exactly matching orders. Be aware this is just a toy exchange, and the exchange functionality is just for completeness. +After depositing funds to the exchange, the user can place orders. An order consists of two tuples. `from: (Token1, amount1)` and `to: (Token2, amount2)`. These orders get added to the exchange. What happens to these orders is specific to the exchange implementation. This sample provides a simple exchange that only executes exactly matching orders. Be aware this is just a toy exchange, and the exchange functionality is just for completeness. ### Withdrawing funds @@ -107,7 +107,7 @@ or you can regenerate the URL "http://127.0.0.1:4943?canisterId=$(dfx canister i ## Step 2: To interact with the exchange, you can create a local Internet Identity by clicking the login button. -This sample project uses a local test version of Internet Identity. Do not use your mainnet Internet Identity, and this testnet Internet Identity will not work on the mainnet. +This sample project uses a local test version of Internet Identity. Do not use your mainnet Internet Identity, and this testnet Internet Identity will not work on the mainnet. ## Step 3: When prompted, select **Create Internet Identity**. @@ -132,7 +132,7 @@ This sample project uses a local test version of Internet Identity. Do not use y `make init-local II_PRINCIPAL=` -## Step 10: Refresh the web browser to verify that your tokens were deposited. +## Step 10: Refresh the web browser to verify that your tokens were deposited. To trade tokens with yourself, you can open a second incognito browser window. diff --git a/rust/dip721-nft-container/README.md b/rust/dip721-nft-container/README.md index bdb0fb856..51be21b49 100644 --- a/rust/dip721-nft-container/README.md +++ b/rust/dip721-nft-container/README.md @@ -2,7 +2,7 @@ keywords: [advanced, rust, nft, dip721] --- -# DIP721 NFT +# DIP721 NFT [View this sample's code on GitHub](https://github.com/dfinity/examples/tree/master/rust/dip721-nft-container) @@ -47,7 +47,7 @@ In case an error occurs during any part of the upgrade (including `post_upgdrade The Rust CDK (Canister Development Kit) currently only supports one value in stable memory, so it is necessary to create an object that can hold everything you care about. In addition, not every data type can be stored in stable memory; only ones that implement the [CandidType trait](https://docs.rs/candid/latest/candid/types/trait.CandidType.html) -(usually via the [CandidType derive macro](https://docs.rs/candid/latest/candid/derive.CandidType.html)) can be written to stable memory. +(usually via the [CandidType derive macro](https://docs.rs/candid/latest/candid/derive.CandidType.html)) can be written to stable memory. Since the state of our canister includes an `RbTree` which does not implement the `CandidType`, it has to be converted into a data structure (in this case a `Vec`) that implements `CandidType`. Luckily, both `RbTree` and `Vec` implement functions that allow converting to/from iterators, so the conversion can be done quite easily. @@ -76,7 +76,7 @@ For a much more detailed explanation of how certification works, see [this expla - **Operator**: sort of a delegated owner. The operator does not own the NFT but can do the same actions an owner can do. - **Custodian**: creator of the NFT collection/canister. They can do anything (transfer, add/remove operators, burn, and even un-burn) to NFTs, but also mint new ones or change the symbol or description of the collection. -The NFT example canister keeps access control in these three levels very simple: +The NFT example canister keeps access control in these three levels very simple: - For every level of control, a separate list (or set) of principals is kept. - Those three levels are then manually checked every single time someone attempts to do something for which they require authorization. - If a user is not authorized to call a certain function an error is returned. @@ -111,7 +111,7 @@ cd examples/rust/dip721-nft-container dfx start --background --clean ``` - ### Step 3: Install the canister. + ### Step 3: Install the canister. Deploy the canister with the command: ```sh @@ -145,9 +145,9 @@ The canister also supports a certified HTTP interface; going to `//` wi Remember that query functions are uncertified; the result of functions like `ownerOfDip721` can be modified arbitrarily by a single malicious node. If queried information is depended on, for example, if someone might send ICP to the owner of a particular NFT to buy it from them, those calls should be performed as update calls instead. You can force an update call by passing the `--update` flag to `dfx` or using the `Agent::update` function in `agent-rs`. - ### Step 5: Mint an NFT. + ### Step 5: Mint an NFT. -Due to size limitations on the length of a terminal command, an image- or video-based NFT would be impossible to send via `dfx`. To that end, there is an experimental [minting tool](https://github.com/dfinity/experimental-minting-tool) you can use to mint a single-file NFT. +Due to size limitations on the length of a terminal command, an image- or video-based NFT would be impossible to send via `dfx`. To that end, there is an experimental [minting tool](https://github.com/dfinity/experimental-minting-tool) you can use to mint a single-file NFT. To use this tool, install the minting tool with the command: @@ -165,7 +165,7 @@ The output of this command should look like this: Successfully minted token 0 to x4d3z-ufpaj-lpxs4-v7gmt-v56ze-aub3k-bvifl-y4lsq-soafd-d3i4k-fqe (transaction id 0) ``` -Minting is restricted to anyone authorized with the `custodians` parameter or the `set_custodians` function. Since the contents of `--file` are stored on-chain, it's important to prevent arbitrary users from minting tokens, or they will be able to store arbitrarily-sized data in the contract and exhaust the canister's cycles. Be careful not to upload too much data to the canister yourself, or the contract will no longer be able to be upgraded afterward. +Minting is restricted to anyone authorized with the `custodians` parameter or the `set_custodians` function. Since the contents of `--file` are stored onchain, it's important to prevent arbitrary users from minting tokens, or they will be able to store arbitrarily-sized data in the contract and exhaust the canister's cycles. Be careful not to upload too much data to the canister yourself, or the contract will no longer be able to be upgraded afterward. #### Demo diff --git a/rust/face-recognition/src/frontend/src/index.html b/rust/face-recognition/src/frontend/src/index.html index 145125771..3c11059eb 100644 --- a/rust/face-recognition/src/frontend/src/index.html +++ b/rust/face-recognition/src/frontend/src/index.html @@ -4,7 +4,7 @@ - On-chain ICP face recognition + Onchain ICP face recognition @@ -13,7 +13,7 @@
-

On-chain ICP face recognition

+

Onchain ICP face recognition