From 6b301aa74d866d5f7c686d23ec53199454c50df7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Pedro=20Sousa?= Date: Tue, 24 Oct 2023 22:10:50 +0100 Subject: [PATCH 1/5] chore: adding fix to master branch --- .github/workflows/build-docs.yml | 1 - docs/docs/language_concepts/01_functions.md | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-docs.yml b/.github/workflows/build-docs.yml index af3565ba61d..543f1583e10 100644 --- a/.github/workflows/build-docs.yml +++ b/.github/workflows/build-docs.yml @@ -98,7 +98,6 @@ jobs: with: branch-name: ${{ github.head_ref || github.ref }} site-id: ${{ secrets.NETLIFY_SITE_ID }} - continue-on-error: true - name: Debugging - print deploy_status run: echo "${{ steps.check_deploy_status.outputs.deploy_status }}" diff --git a/docs/docs/language_concepts/01_functions.md b/docs/docs/language_concepts/01_functions.md index c42aa9eab12..47cdea0cf04 100644 --- a/docs/docs/language_concepts/01_functions.md +++ b/docs/docs/language_concepts/01_functions.md @@ -160,12 +160,14 @@ fn main() { Also note that impls with the same method name defined in them cannot overlap. For example, if we already have `foo` defined for `Foo` and `Foo` like we do above, we cannot also define `foo` in an `impl Foo` since it would be ambiguous which version of `foo` to choose. -```rs +```rust // Including this impl in the same project as the above snippet would // cause an overlapping impls error impl Foo { fn foo(self) -> Field { 3 } } +``` + ## Lambdas Lambdas are anonymous functions. They follow the syntax of Rust - `|arg1, arg2, ..., argN| return_expression`. From f5fc94e15cdf31ad434872a29730b51e98ff2de3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Pedro=20Sousa?= Date: Tue, 24 Oct 2023 22:14:54 +0100 Subject: [PATCH 2/5] chore: adding fix to master branch --- .github/actions/docs/build-status/script.sh | 4 ++-- .github/workflows/build-docs.yml | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/actions/docs/build-status/script.sh b/.github/actions/docs/build-status/script.sh index a8d31ff4f4b..0b282557cf2 100755 --- a/.github/actions/docs/build-status/script.sh +++ b/.github/actions/docs/build-status/script.sh @@ -18,11 +18,11 @@ while [[ "$DEPLOY_STATUS" != "ready" && $COUNT -lt $MAX_RETRIES ]]; do exit 0 elif [[ "$DEPLOY_STATUS" == "error" ]]; then echo "deploy_status=failure" >> $GITHUB_OUTPUT - exit 0 + exit 1 fi echo "Deploy still running. Retrying..." done echo "deploy_status=failure" >> $GITHUB_OUTPUT -exit 0 +exit 1 diff --git a/.github/workflows/build-docs.yml b/.github/workflows/build-docs.yml index 543f1583e10..3257a259417 100644 --- a/.github/workflows/build-docs.yml +++ b/.github/workflows/build-docs.yml @@ -99,9 +99,14 @@ jobs: branch-name: ${{ github.head_ref || github.ref }} site-id: ${{ secrets.NETLIFY_SITE_ID }} + - name: Debugging - print deploy_status run: echo "${{ steps.check_deploy_status.outputs.deploy_status }}" + - name: Fail the workflow if deployment failed + if: steps.check_deploy_status.outputs.deploy_status == 'failure' + run: exit 1 + - name: Change PR Comment for Successful Deployment if: steps.check_deploy_status.outputs.deploy_status == 'success' uses: mshick/add-pr-comment@v2 From 03e91ce670726da6276f7138370b493993d93a12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Pedro=20Sousa?= Date: Tue, 24 Oct 2023 22:15:44 +0100 Subject: [PATCH 3/5] chore: adding a broken link to see it fail miserably --- docs/docs/language_concepts/01_functions.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/docs/language_concepts/01_functions.md b/docs/docs/language_concepts/01_functions.md index 47cdea0cf04..d76460c6daa 100644 --- a/docs/docs/language_concepts/01_functions.md +++ b/docs/docs/language_concepts/01_functions.md @@ -177,7 +177,7 @@ let add_50 = |val| val + 50; assert(add_50(100) == 150); ``` -See [Lambdas](./08_lambdas.md) for more details. +See [Lambdas](./08_lamdas.md) for more details. ## Attributes From d1b3e9e4b1a44bb9ce968b2412e5a8ad42df2a2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Pedro=20Sousa?= Date: Tue, 24 Oct 2023 22:18:07 +0100 Subject: [PATCH 4/5] chore: I like my memes when it fails --- .github/workflows/build-docs.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-docs.yml b/.github/workflows/build-docs.yml index 3257a259417..23ae0e409e9 100644 --- a/.github/workflows/build-docs.yml +++ b/.github/workflows/build-docs.yml @@ -98,14 +98,12 @@ jobs: with: branch-name: ${{ github.head_ref || github.ref }} site-id: ${{ secrets.NETLIFY_SITE_ID }} + continue-on-error: true - name: Debugging - print deploy_status run: echo "${{ steps.check_deploy_status.outputs.deploy_status }}" - - name: Fail the workflow if deployment failed - if: steps.check_deploy_status.outputs.deploy_status == 'failure' - run: exit 1 - name: Change PR Comment for Successful Deployment if: steps.check_deploy_status.outputs.deploy_status == 'success' @@ -138,3 +136,7 @@ jobs: Deployment didn't succeed. Please check logs below and resolve the issue 🧐 [![Netlify Status](https://api.netlify.com/api/v1/badges/${{ secrets.NETLIFY_SITE_ID }}/deploy-status?branch=${{ github.head_ref || github.ref }})](https://app.netlify.com/sites/noir-docs-v2/deploys) + + - name: Fail the workflow if deployment failed + if: steps.check_deploy_status.outputs.deploy_status == 'failure' + run: exit 1 From 08987354919c0f6d52dcd77b31c74bac5bd036f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Pedro=20Sousa?= Date: Tue, 24 Oct 2023 22:19:52 +0100 Subject: [PATCH 5/5] chore: undoing the intentional fuck-up... --- docs/docs/language_concepts/01_functions.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/docs/language_concepts/01_functions.md b/docs/docs/language_concepts/01_functions.md index d76460c6daa..47cdea0cf04 100644 --- a/docs/docs/language_concepts/01_functions.md +++ b/docs/docs/language_concepts/01_functions.md @@ -177,7 +177,7 @@ let add_50 = |val| val + 50; assert(add_50(100) == 150); ``` -See [Lambdas](./08_lamdas.md) for more details. +See [Lambdas](./08_lambdas.md) for more details. ## Attributes