refactor: aztec-cli better volume mounting strategy#3138
Conversation
| if [[ -f "$arg_value" || -d "$arg_value" ]]; then | ||
| add_mount "$arg_value" | ||
| fi |
There was a problem hiding this comment.
Technically add_mount already checks that its argument is an existing directory so this if statement could be skipped.
58d1bf8 to
d299ca4
Compare
For commands like `compute-selector` which take arguments with reserved characters, the bash wrapper script required callers to triple escape characters, e.g. what normally would have been aztec-cli compute-selector foo\(Field\) using the `eval $DOCKER_CMD` approach required: aztec-cli computer-selector foo\\\(Field\\\) Replacing the `eval` with directly running the command fixed it.
d65e4cb to
8f03ad1
Compare
Benchmark resultsMetrics with a significant change:
Detailed resultsAll benchmarks are run on txs on the This benchmark source data is available in JSON format on S3 here. Values are compared against data from master at commit L2 block published to L1Each column represents the number of txs on an L2 block published to L1.
L2 chain processingEach column represents the number of blocks on the L2 chain where each block has 16 txs.
Circuits statsStats on running time and I/O sizes collected for every circuit run across all benchmarks.
MiscellaneousTransaction sizes based on how many contracts are deployed in the tx.
|
🤖 I have created a release *beep* *boop* --- <details><summary>aztec-packages: 0.14.2</summary> ## [0.14.2](aztec-packages-v0.14.1...aztec-packages-v0.14.2) (2023-11-07) ### Features * Load private tests and docs ([#3243](#3243)) ([f3d8aae](f3d8aae)), closes [#1285](#1285) * Run solidity tests for all acir artifacts ([#3161](#3161)) ([d09f667](d09f667)) ### Bug Fixes * Wait for accounts to catch up with notes when deployed ([#2834](#2834)) ([a8f3119](a8f3119)) ### Miscellaneous * Add noir-protocol-circuits to deploy_npm ([#3268](#3268)) ([1a22cae](1a22cae)) * Aztec-cli better volume mounting strategy ([#3138](#3138)) ([d40460e](d40460e)) * Disable circuits tasks ([#3253](#3253)) ([e8945f8](e8945f8)) </details> <details><summary>barretenberg.js: 0.14.2</summary> ## [0.14.2](barretenberg.js-v0.14.1...barretenberg.js-v0.14.2) (2023-11-07) ### Features * Run solidity tests for all acir artifacts ([#3161](#3161)) ([d09f667](d09f667)) </details> <details><summary>barretenberg: 0.14.2</summary> ## [0.14.2](barretenberg-v0.14.1...barretenberg-v0.14.2) (2023-11-07) ### Features * Run solidity tests for all acir artifacts ([#3161](#3161)) ([d09f667](d09f667)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
🤖 I have created a release *beep* *boop* --- <details><summary>aztec-packages: 0.14.2</summary> ## [0.14.2](AztecProtocol/aztec-packages@aztec-packages-v0.14.1...aztec-packages-v0.14.2) (2023-11-07) ### Features * Load private tests and docs ([#3243](AztecProtocol/aztec-packages#3243)) ([f3d8aae](AztecProtocol/aztec-packages@f3d8aae)), closes [#1285](AztecProtocol/aztec-packages#1285) * Run solidity tests for all acir artifacts ([#3161](AztecProtocol/aztec-packages#3161)) ([d09f667](AztecProtocol/aztec-packages@d09f667)) ### Bug Fixes * Wait for accounts to catch up with notes when deployed ([#2834](AztecProtocol/aztec-packages#2834)) ([a8f3119](AztecProtocol/aztec-packages@a8f3119)) ### Miscellaneous * Add noir-protocol-circuits to deploy_npm ([#3268](AztecProtocol/aztec-packages#3268)) ([1a22cae](AztecProtocol/aztec-packages@1a22cae)) * Aztec-cli better volume mounting strategy ([#3138](AztecProtocol/aztec-packages#3138)) ([d40460e](AztecProtocol/aztec-packages@d40460e)) * Disable circuits tasks ([#3253](AztecProtocol/aztec-packages#3253)) ([e8945f8](AztecProtocol/aztec-packages@e8945f8)) </details> <details><summary>barretenberg.js: 0.14.2</summary> ## [0.14.2](AztecProtocol/aztec-packages@barretenberg.js-v0.14.1...barretenberg.js-v0.14.2) (2023-11-07) ### Features * Run solidity tests for all acir artifacts ([#3161](AztecProtocol/aztec-packages#3161)) ([d09f667](AztecProtocol/aztec-packages@d09f667)) </details> <details><summary>barretenberg: 0.14.2</summary> ## [0.14.2](AztecProtocol/aztec-packages@barretenberg-v0.14.1...barretenberg-v0.14.2) (2023-11-07) ### Features * Run solidity tests for all acir artifacts ([#3161](AztecProtocol/aztec-packages#3161)) ([d09f667](AztecProtocol/aztec-packages@d09f667)) </details> --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
This PR changes aztec-cli.sh's mounting strategy to be more generic, ensuring fewer updates are necessary as new commands are added.
Previous strategy: "for these commands A,B,C,etc, recognize these flags and positional parameters as files/directories. Edge case: for the
unboxcommand, mkdir first then mount"New strategy: "go through every CLI arg and if it looks like a file or a directory, mount it in the container. Edge case: for the
unboxcommand, mkdir first then mount"Checklist:
Remove the checklist to signal you've completed it. Enable auto-merge if the PR is ready to merge.