Update testnet3 to mainnet

This commit is contained in:
Pranav Gaddamadugu 2024-05-14 13:31:33 -07:00
parent 100aca0938
commit b0ef7a8f46
48 changed files with 106 additions and 106 deletions

View File

@ -18,7 +18,7 @@ fi
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -52,7 +52,7 @@ leo run mint_public aleo13ssze66adjjkt795z9u5wpq8h6kn0y2657726h4h3e3wfnez4vqsm30
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -86,7 +86,7 @@ leo run mint_private aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4calsrrqdaqyshd
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -120,7 +120,7 @@ leo run transfer_public aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4calsrrqdaqy
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -158,7 +158,7 @@ leo run transfer_private "{
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -193,7 +193,7 @@ leo run transfer_public_to_private aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -234,6 +234,6 @@ leo run transfer_private_to_public "{
# Swap in the private key of Alice.
# This is done to ensure that program.json is the same after every execution of ./run.sh.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env

View File

@ -5,7 +5,7 @@ updates:
schedule:
interval: daily
time: "10:00"
target-branch: "testnet3"
target-branch: "mainnet"
open-pull-requests-limit: 20
ignore:
- dependency-name: snarkvm-curves
@ -89,4 +89,4 @@ updates:
- 0.8.3
- dependency-name: rand_xorshift
versions:
- 0.3.0
- 0.3.0

View File

@ -21,7 +21,7 @@ jobs:
- name: Generate asts
run: |
# This currently has to be on testnet3 to work:
# This currently has to be on mainnet to work:
cd compiler/parser
cargo -q install --path . --example parser
# To ensure full file tests,

View File

@ -3,7 +3,7 @@ on:
pull_request:
push:
branches:
- testnet3
- mainnet
paths-ignore:
- 'docs/**'
- 'documentation/**'
@ -189,7 +189,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v2
with:
ref: testnet3
ref: mainnet
- name: Install sccache
env:

View File

@ -2,7 +2,7 @@ name: Code Coverage
on:
push:
branches:
- testnet3
- mainnet
paths-ignore:
- 'docs/**'
- 'documentation/**'
@ -100,4 +100,4 @@ jobs:
run: sccache --show-stats
- name: Stop sccache server
run: sccache --stop-server || true
run: sccache --stop-server || true

View File

@ -17,7 +17,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v2
with:
ref: testnet3
ref: mainnet
- name: Install sccache
env:

View File

@ -6,9 +6,9 @@ Thank you for your interest in contributing to Leo! Below you can find some guid
Please follow the instructions below when filing pull requests:
- Ensure that your branch is forked from the current [testnet3](https://github.com/AleoHQ/leo/tree/testnet3) branch.
- Ensure that your branch is forked from the current [mainnet](https://github.com/AleoHQ/leo/tree/mainnet) branch.
- Fill out the provided markdown template for the feature or proposal. Be sure to link the pull request to any issues by using keywords. Example: "closes #130".
- Run `cargo fmt` before you commit; we use the `nightly` version of `rustfmt` to format the code, so you'll need to have the `nightly` toolchain installed on your machine; there's a [git hook](https://git-scm.com/docs/githooks) that ensures proper formatting before any commits can be made, and [`.rustfmt.toml`](https://github.com/AleoHQ/Leo/blob/testnet3/.rustfmt.toml) specifies some of the formatting conventions.
- Run `cargo fmt` before you commit; we use the `nightly` version of `rustfmt` to format the code, so you'll need to have the `nightly` toolchain installed on your machine; there's a [git hook](https://git-scm.com/docs/githooks) that ensures proper formatting before any commits can be made, and [`.rustfmt.toml`](https://github.com/AleoHQ/Leo/blob/mainnet/.rustfmt.toml) specifies some of the formatting conventions.
- Run `cargo clippy` to ensure that popular correctness and performance pitfalls are avoided.
## Style

View File

@ -6,9 +6,9 @@
<p align="center">
<a href="https://circleci.com/gh/AleoHQ/leo"><img src="https://circleci.com/gh/AleoHQ/leo.svg?style=svg&circle-token=00960191919c40be0774e00ce8f7fa1fcaa20c00"></a>
<a href="https://codecov.io/gh/AleoHQ/leo"><img src="https://codecov.io/gh/AleoHQ/leo/branch/testnet3/graph/badge.svg?token=S6MWO60SYL"/></a>
<a href="https://codecov.io/gh/AleoHQ/leo"><img src="https://codecov.io/gh/AleoHQ/leo/branch/mainnet/graph/badge.svg?token=S6MWO60SYL"/></a>
<a href="https://discord.gg/aleo"><img src="https://img.shields.io/discord/700454073459015690?logo=discord"/></a>
<a href="https://github.com/AleoHQ/leo/blob/testnet3/CONTRIBUTORS.md"><img src="https://img.shields.io/badge/contributors-393-ee8449"/></a>
<a href="https://github.com/AleoHQ/leo/blob/mainnet/CONTRIBUTORS.md"><img src="https://img.shields.io/badge/contributors-393-ee8449"/></a>
<a href="https://twitter.com/AleoHQ"><img src="https://img.shields.io/twitter/follow/AleoHQ?style=social"/></a>
</p>
<div id="top"></div>

View File

@ -998,7 +998,7 @@ impl<'a, N: Network> ExpressionVisitor<'a> for TypeChecker<'a, N> {
Some(Type::Tuple(expected_types.clone()))
} else {
// Tuples must be explicitly typed in testnet3.
// Tuples must be explicitly typed.
self.emit_err(TypeCheckerError::invalid_tuple(input.span()));
None

View File

@ -12,8 +12,8 @@ You will know that the download has failed if you see the following error messag
```bash
ATTENTION - "genesis.prover.1c9bbe9" does not exist, downloading this file remotely and storing it locally. Please ensure "genesis.prover.1c9bbe9" is stored in "/Users/xxx/.aleo/resources/genesis.prover.1c9bbe9".
snarkvm_parameters::testnet3 - Downloading parameters...
snarkvm_parameters::testnet3 - thread `main` panicked at 'Failed to load proving key: Crate("curl::error", "Error { description: \"Transferred a partial file\", code: 18, extra: Some(\"transfer closed with 92197356 bytes remaining to read\") }")', /Users/xxx/.cargo/git/checkouts/snarkvm-f1160780ffe17de8/ea14990/parameters/src/testnet3/symbol_table_creation:95:9
snarkvm_parameters::mainnet - Downloading parameters...
snarkvm_parameters::mainnet - thread `main` panicked at 'Failed to load proving key: Crate("curl::error", "Error { description: \"Transferred a partial file\", code: 18, extra: Some(\"transfer closed with 92197356 bytes remaining to read\") }")', /Users/xxx/.cargo/git/checkouts/snarkvm-f1160780ffe17de8/ea14990/parameters/src/mainnet/symbol_table_creation:95:9
stack backtrace:
0: backtrace::capture::Backtrace::new
1: leo::set_panic_hook::{{closure}}

View File

@ -211,7 +211,7 @@ create_messages!(
invalid_associated_access {
args: (name: impl Display),
msg: format!("Invalid associated access call to struct {name}."),
help: Some("Double colon `::` syntax is only supported for core functions in Leo for testnet3.".to_string()),
help: Some("Double colon `::` syntax is only supported for core functions in Leo for mainnet.".to_string()),
}
@formatted

View File

@ -114,7 +114,7 @@ create_messages!(
missing_network_error {
args: (dependency: impl Display),
msg: format!("Dependency {dependency} is missing a network specification"),
help: Some("Add a network specification to the dependency in the `program.json` file. Example: `network: \"testnet3\"`".to_string()),
help: Some("Add a network specification to the dependency in the `program.json` file. Example: `network: \"mainnet\"`".to_string()),
}
@formatted

View File

@ -1,4 +1,4 @@
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp5wvamYgK3WCAdpBQxZqQX8XnuN2u11Y6QprZTriVwZVc

View File

@ -44,8 +44,8 @@ When executing programs as different parties, be sure to set the `PRIVATE_KEY` f
See `./run.sh` for an example of how to run the program as different parties.
The [Aleo SDK](https://github.com/AleoHQ/leo/tree/testnet3) provides an interface for generating new accounts.
To generate a new account, navigate to [aleo.tools](https://aleo.tools).
The [Aleo SDK](https://github.com/AleoHQ/leo/tree/mainnet) provides an interface for generating new accounts.
To generate a new account, navigate to [provable.tools](https://provable.tools).
### Providing inputs via the command line.

View File

@ -37,7 +37,7 @@ echo "
"
# Swap in the private key and address of the first bidder to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpG9Af9z5Ha4ejVyMCqVFXRKknSm8L1ELEwcc4htk9YhVK
" > .env
@ -59,7 +59,7 @@ leo run place_bid aleo1yzlta2q5h8t0fqe0v6dyh9mtv4aggd53fgzr068jvplqhvqsnvzq7pj2k
# Swap in the private key and address of the second bidder to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpAFshdsj2EqQzXh5zHceDapFWVCwR6wMCJFfkLYRKupug
" > .env
@ -81,7 +81,7 @@ leo run place_bid aleo1esqchvevwn7n5p84e735w4dtwt2hdtu4dpguwgwy94tsxm2p7qpqmlrta
# Swap in the private key and address of the auctioneer to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp5wvamYgK3WCAdpBQxZqQX8XnuN2u11Y6QprZTriVwZVc
" > .env

View File

@ -1,4 +1,4 @@
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpHtqVWT6fSHgUMNxsuVf7eaR6id2cj7TieKY1Z8CP5rCD

View File

@ -45,8 +45,8 @@ When executing programs as different parties, be sure to set the `PRIVATE_KEY` f
See `./run.sh` for an example of how to run the program as different parties.
The [Aleo SDK](https://github.com/AleoHQ/leo/tree/testnet3) provides an interface for generating new accounts.
To generate a new account, navigate to [aleo.tools](https://aleo.tools).
The [Aleo SDK](https://github.com/AleoHQ/leo/tree/mainnet) provides an interface for generating new accounts.
To generate a new account, navigate to [provable.tools](https://provable.tools).
### Providing inputs via the command line.
```bash

View File

@ -18,7 +18,7 @@ fi
# Swap in the private key and address of the bank to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpHtqVWT6fSHgUMNxsuVf7eaR6id2cj7TieKY1Z8CP5rCD
" > .env
@ -67,7 +67,7 @@ leo run issue aleo1zeklp6dd8e764spe74xez6f8w27dlua3w7hl4z2uln03re52egpsv46ngg 10
# Swap in the private key and address of the user to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp75cpr5NNQpVWc5mfsD9Uf2wg6XvHknf82iwB636q3rtc
" > .env
@ -161,7 +161,7 @@ echo "
# Swap in the private key and address of the bank to .env.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpHtqVWT6fSHgUMNxsuVf7eaR6id2cj7TieKY1Z8CP5rCD
" > .env

View File

@ -1,4 +1,4 @@
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp86FNGdKxjgAdgQZ967bqBanjuHkAaoRe19RK24ZCGsHH

View File

@ -17,7 +17,7 @@ echo "
"
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpGKaJY47BXb6knSqmT3JZnBUEGBDFAWz2nMVSsjwYpJmm
" > .env
@ -67,7 +67,7 @@ echo "
"
(
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp86FNGdKxjgAdgQZ967bqBanjuHkAaoRe19RK24ZCGsHH
" > .env
@ -115,7 +115,7 @@ echo "
"
(
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpGKaJY47BXb6knSqmT3JZnBUEGBDFAWz2nMVSsjwYpJmm
" > .env
@ -151,7 +151,7 @@ echo "
(
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp86FNGdKxjgAdgQZ967bqBanjuHkAaoRe19RK24ZCGsHH
" > .env
@ -186,7 +186,7 @@ echo "
"
(
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpGKaJY47BXb6knSqmT3JZnBUEGBDFAWz2nMVSsjwYpJmm
" > .env
@ -222,7 +222,7 @@ echo "
(
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp86FNGdKxjgAdgQZ967bqBanjuHkAaoRe19RK24ZCGsHH
" > .env

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,3 +1,3 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,4 +1,4 @@
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR

View File

@ -18,7 +18,7 @@ fi
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -52,7 +52,7 @@ leo run mint_public aleo13ssze66adjjkt795z9u5wpq8h6kn0y2657726h4h3e3wfnez4vqsm30
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -86,7 +86,7 @@ leo run mint_private aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4calsrrqdaqyshd
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -120,7 +120,7 @@ leo run transfer_public aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4calsrrqdaqy
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -158,7 +158,7 @@ leo run transfer_private "{
# Swap in the private key of Alice.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env
@ -193,7 +193,7 @@ leo run transfer_public_to_private aleo17vy26rpdhqx4598y5gp7nvaa9rk7tnvl6ufhvvf4
# Swap in the private key of Bob.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpFo72g7N9iFt3JzzeG8CqsS5doAiXyFvNCgk2oHvjRCzF
" > .env
@ -234,6 +234,6 @@ leo run transfer_private_to_public "{
# Swap in the private key of Alice.
# This is done to ensure that program.json is the same after every execution of ./run.sh.
echo "
NETWORK=testnet3
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkp1w8PTxrRgGfAtfKUSq43iQyVbdQHfhGbiNPEg2LVSEXR
" > .env

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -1,2 +1,2 @@
NETWORK=testnet3
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx
NETWORK=mainnet
PRIVATE_KEY=APrivateKey1zkpBvXdKZKaXXcLUnwAVFCQNp41jrX6JqTuJo1JShfPoRfx

View File

@ -190,7 +190,7 @@ mod tests {
});
// TODO: Clear tmp directory
// let registry = temp_dir.join(".aleo").join("registry").join("testnet3");
// let registry = temp_dir.join(".aleo").join("registry").join("mainnet");
// std::fs::remove_dir_all(registry).unwrap();
// std::fs::remove_dir_all(project_directory).unwrap();
}
@ -400,7 +400,7 @@ function external_nested_function:
command: Add {
name: "nested_example_layer_0".to_string(),
local: None,
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(project_directory.clone()),
@ -412,7 +412,7 @@ function external_nested_function:
});
// Add custom `.aleo` directory
let registry = temp_dir.join(".aleo").join("registry").join("testnet3");
let registry = temp_dir.join(".aleo").join("registry").join("mainnet");
std::fs::create_dir_all(&registry).unwrap();
std::fs::write(registry.join("nested_example_layer_0.aleo"), nested_example_layer_0).unwrap();
std::fs::write(registry.join("nested_example_layer_1.aleo"), nested_example_layer_1).unwrap();
@ -493,7 +493,7 @@ program child.aleo {
command: Add {
name: "parent".to_string(),
local: Some(parent_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(grandparent_directory.clone()),
@ -507,7 +507,7 @@ program child.aleo {
command: Add {
name: "child".to_string(),
local: Some(child_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(grandparent_directory.clone()),
@ -521,7 +521,7 @@ program child.aleo {
command: Add {
name: "child".to_string(),
local: Some(child_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(parent_directory.clone()),
@ -644,7 +644,7 @@ program outer.aleo {
command: Add {
name: "inner_1".to_string(),
local: Some(inner_1_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(outer_directory.clone()),
@ -658,7 +658,7 @@ program outer.aleo {
command: Add {
name: "inner_2".to_string(),
local: Some(inner_2_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(outer_directory.clone()),
@ -811,7 +811,7 @@ program outer_2.aleo {
command: Add {
name: "inner_1".to_string(),
local: Some(inner_1_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(outer_directory.clone()),
@ -825,7 +825,7 @@ program outer_2.aleo {
command: Add {
name: "inner_2".to_string(),
local: Some(inner_2_directory.clone()),
network: "testnet3".to_string(),
network: "mainnet".to_string(),
},
},
path: Some(outer_directory.clone()),

View File

@ -214,7 +214,7 @@ fn print_keys(private_key: PrivateKey<CurrentNetwork>, discreet: bool) -> Result
// Write the network and private key to the .env file in project directory.
fn write_to_env_file(private_key: PrivateKey<CurrentNetwork>, ctx: &Context) -> Result<()> {
let data = format!("NETWORK=testnet3\nPRIVATE_KEY={private_key}\n");
let data = format!("NETWORK=mainnet\nPRIVATE_KEY={private_key}\n");
let program_dir = ctx.dir()?;
Env::<CurrentNetwork>::from(data).write_to(&program_dir)?;
tracing::info!("✅ Private Key written to {}", program_dir.join(".env").display());

View File

@ -28,7 +28,7 @@ pub struct Add {
#[clap(short = 'l', long, help = "Optional path to local dependency")]
pub(crate) local: Option<PathBuf>,
#[clap(short = 'n', long, help = "Optional name of the network to use", default_value = "testnet3")]
#[clap(short = 'n', long, help = "Optional name of the network to use", default_value = "mainnet")]
pub(crate) network: String,
}

View File

@ -168,7 +168,7 @@ pub struct BuildOptions {
pub struct FeeOptions {
#[clap(long, help = "Priority fee in microcredits. Defaults to 0.", default_value = "0")]
pub(crate) priority_fee: String,
#[clap(long, help = "Network to broadcast to. Defaults to testnet3.", default_value = "testnet3")]
#[clap(long, help = "Network to broadcast to. Defaults to mainnet.", default_value = "mainnet")]
pub(crate) network: String,
#[clap(long, help = "Private key to authorize fee expenditure.")]
pub(crate) private_key: Option<String>,

View File

@ -64,6 +64,6 @@ impl<N: Network> Env<N> {
// Initialize a new development private key.
let private_key = PrivateKey::<N>::new(rng)?;
Ok(format!("NETWORK=testnet3\nPRIVATE_KEY={private_key}\n"))
Ok(format!("NETWORK=mainnet\nPRIVATE_KEY={private_key}\n"))
}
}

View File

@ -123,7 +123,7 @@ mod tests {
fn array_test() {
create_session_if_not_set_then(|_| {
let program_from_file =
fs::read_to_string("../tmp/.aleo/registry/testnet3/zk_bitwise_stack_v0_0_2.aleo").unwrap();
fs::read_to_string("../tmp/.aleo/registry/mainnet/zk_bitwise_stack_v0_0_2.aleo").unwrap();
let _program = disassemble_from_str::<CurrentNetwork>(&program_from_file).unwrap();
});
}