generated from noir-lang/noir-library-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit cc75d2c
Showing
14 changed files
with
528 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
title: "Tests fail on latest Nargo nightly release" | ||
--- | ||
|
||
The tests on this Noir project have started failing when using the latest nightly release of the Noir compiler. This likely means that there have been breaking changes for which this project needs to be updated to take into account. | ||
|
||
Check the [{{env.WORKFLOW_NAME}}]({{env.WORKFLOW_URL}}) workflow for details. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
name: Benchmarks | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
name: Benchmark library | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Nargo | ||
uses: noir-lang/[email protected] | ||
with: | ||
toolchain: 0.34.0 | ||
|
||
- name: Install bb | ||
run: | | ||
npm install -g bbup | ||
bbup -nv 0.34.0 | ||
- name: Build Noir benchmark programs | ||
run: nargo export | ||
|
||
- name: Generate gates report | ||
run: ./scripts/build-gates-report.sh | ||
env: | ||
BACKEND: /home/runner/.bb/bb | ||
|
||
- name: Compare gates reports | ||
id: gates_diff | ||
uses: noir-lang/noir-gates-diff@1931aaaa848a1a009363d6115293f7b7fc72bb87 | ||
with: | ||
report: gates_report.json | ||
summaryQuantile: 0.9 # only display the 10% most significant circuit size diffs in the summary (defaults to 20%) | ||
|
||
- name: Add gates diff to sticky comment | ||
if: github.event_name == 'pull_request' || github.event_name == 'pull_request_target' | ||
uses: marocchino/sticky-pull-request-comment@v2 | ||
with: | ||
# delete the comment in case changes no longer impact circuit sizes | ||
delete: ${{ !steps.gates_diff.outputs.markdown }} | ||
message: ${{ steps.gates_diff.outputs.markdown }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Noir Nightly Canary | ||
|
||
on: | ||
schedule: | ||
# Run a check at 9 AM UTC | ||
- cron: "0 9 * * *" | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
permissions: | ||
issues: write | ||
|
||
jobs: | ||
test: | ||
name: Test on Nargo ${{matrix.toolchain}} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Nargo | ||
uses: noir-lang/[email protected] | ||
with: | ||
toolchain: nightly | ||
|
||
- name: Run Noir tests | ||
run: nargo test | ||
|
||
- name: Alert on dead links | ||
uses: JasonEtco/create-an-issue@v2 | ||
if: ${{ failure() }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
WORKFLOW_NAME: ${{ github.workflow }} | ||
WORKFLOW_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} | ||
with: | ||
update_existing: true | ||
filename: .github/NIGHTLY_CANARY_DIED.md | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Pull Request | ||
|
||
on: | ||
merge_group: | ||
pull_request_target: | ||
types: | ||
- opened | ||
- reopened | ||
- edited | ||
- synchronize | ||
|
||
permissions: | ||
pull-requests: read | ||
|
||
jobs: | ||
conventional-title: | ||
name: Validate PR title is Conventional Commit | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check title | ||
if: github.event_name == 'pull_request_target' | ||
uses: amannn/action-semantic-pull-request@v5 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
types: | | ||
fix | ||
feat | ||
chore | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
release-please: | ||
name: Create Release | ||
outputs: | ||
release-pr: ${{ steps.release.outputs.pr }} | ||
tag-name: ${{ steps.release.outputs.tag_name }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Run release-please | ||
id: release | ||
uses: google-github-actions/release-please-action@v3 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
command: manifest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: Noir tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
test: | ||
name: Test on Nargo ${{matrix.toolchain}} | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
toolchain: [nightly, 0.34.0] | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Nargo | ||
uses: noir-lang/[email protected] | ||
with: | ||
toolchain: ${{ matrix.toolchain }} | ||
|
||
- name: Run Noir tests | ||
run: nargo test | ||
|
||
format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Nargo | ||
uses: noir-lang/[email protected] | ||
with: | ||
toolchain: 0.34.0 | ||
|
||
- name: Run formatter | ||
run: nargo fmt --check | ||
|
||
# This is a job which depends on all test jobs and reports the overall status. | ||
# This allows us to add/remove test jobs without having to update the required workflows. | ||
tests-end: | ||
name: Noir End | ||
runs-on: ubuntu-latest | ||
# We want this job to always run (even if the dependant jobs fail) as we want this job to fail rather than skipping. | ||
if: ${{ always() }} | ||
needs: | ||
- test | ||
- format | ||
|
||
steps: | ||
- name: Report overall success | ||
run: | | ||
if [[ $FAIL == true ]]; then | ||
exit 1 | ||
else | ||
exit 0 | ||
fi | ||
env: | ||
# We treat any cancelled, skipped or failing jobs as a failure for the workflow as a whole. | ||
FAIL: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') || contains(needs.*.result, 'skipped') }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
target | ||
export | ||
gates_report.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{".": "0.0.0"} |
Oops, something went wrong.