Skip to content

Commit

Permalink
chore!: remove backend interactions from nargo (AztecProtocol#6320)
Browse files Browse the repository at this point in the history
This PR removes the `nargo codegen-verifier` command and replaces it
with an example bash script showing how to use `nargo` in conjunction
with `bb` to generate a smart contract verifier.

cc @AztecProtocol/devrel 



Closes noir-lang/noir#4447
Closes noir-lang/noir#1138
Closes noir-lang/noir#2222
Closes noir-lang/noir#1159
Closes noir-lang/noir#1009
Closes noir-lang/noir#3837
Closes noir-lang/noir#2667

---------

Co-authored-by: ludamad <[email protected]>
Co-authored-by: Maxim Vezenov <[email protected]>
  • Loading branch information
3 people authored May 17, 2024
1 parent 52d85d1 commit 7a31896
Show file tree
Hide file tree
Showing 81 changed files with 324 additions and 2,872 deletions.
14 changes: 13 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,21 @@ jobs:
- uses: ./.github/ci-setup-action
with:
concurrency_key: noir-x86
- name: "Test Noir JS packages"
- name: "Test Nargo"
run: earthly-ci --no-output ./noir+test

noir-examples:
needs: setup
runs-on: ${{ github.event.pull_request.user.login || github.actor }}-x86
steps:
- uses: actions/checkout@v4
with: { ref: "${{ env.GIT_COMMIT }}" }
- uses: ./.github/ci-setup-action
with:
concurrency_key: noir-examples-x86
- name: "Test Noir examples"
run: earthly-ci --no-output ./noir+examples

noir-packages-test:
needs: setup
runs-on: ${{ github.event.pull_request.user.login || github.actor }}-x86
Expand Down
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
url = https://github.com/Arachnid/solidity-stringutils
[submodule "barretenberg/sol/lib/openzeppelin-contracts"]
path = barretenberg/sol/lib/openzeppelin-contracts
url = https://github.com/OpenZeppelin/openzeppelin-contracts
url = https://github.com/OpenZeppelin/openzeppelin-contracts
15 changes: 15 additions & 0 deletions noir/Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,21 @@ test:
COPY noir-repo/.rustfmt.toml noir-repo/.rustfmt.toml
RUN ./scripts/test_native.sh

examples:
FROM +nargo
ENV PATH="/usr/src/noir-repo/target/release:${PATH}"

COPY --dir noir-repo/examples noir-repo
COPY ../barretenberg/cpp/+preset-clang-assert/bin/bb /usr/src/barretenberg/cpp/build/bin/bb

ENV BACKEND=/usr/src/barretenberg/cpp/build/bin/bb

WORKDIR noir-repo/examples/codegen-verifier
RUN ./test.sh

WORKDIR ../prove_and_verify
RUN ./test.sh

format:
FROM +nargo
ENV PATH=$PATH:/usr/src/noir-repo/target/release
Expand Down
5 changes: 5 additions & 0 deletions noir/noir-repo/.github/workflows/test-js-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,11 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Download bb binary
run: |
# Adds `bb` to PATH
./scripts/install_bb.sh
- name: Download nargo binary
uses: actions/download-artifact@v4
with:
Expand Down
Loading

0 comments on commit 7a31896

Please sign in to comment.