From f12e01546fc849f6de0d1c7b70260e2f4adf8b37 Mon Sep 17 00:00:00 2001 From: Thomas Eizinger Date: Tue, 17 Oct 2023 18:33:42 +1100 Subject: [PATCH] ci: allow opt-out of changelog lint for internal changes We introduced a lint in #4620 that ensures the changelog is updated when we touch a certain crate. This however leads to many "false-positives" where a change to the source code is not actually worth mentioning in the changelog. To opt out of this change, this patch adds a condition to the job that checks for a `internal:$crate` label and if that is applied, it doesn't run the lint. Pull-Request: #4673. --- .github/workflows/ci.yml | 3 ++- docs/maintainer-handbook.md | 8 ++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 68c52cffb2c..bf786abaa2f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -78,7 +78,8 @@ jobs: !startsWith(github.event.pull_request.title, 'chore') && !startsWith(github.event.pull_request.title, 'refactor') && !startsWith(github.event.pull_request.title, 'deps') && - !startsWith(github.event.pull_request.title, 'docs') + !startsWith(github.event.pull_request.title, 'docs') && + !contains(github.event.pull_request.labels.*.name, 'internal-change') run: | git fetch origin master:master ./scripts/ensure-version-bump-and-changelog.sh diff --git a/docs/maintainer-handbook.md b/docs/maintainer-handbook.md index 8ec6e6e8c6a..6d36f6fe77c 100644 --- a/docs/maintainer-handbook.md +++ b/docs/maintainer-handbook.md @@ -26,6 +26,14 @@ Once a PR fulfills all merge requirements (approvals, passing CI, etc), applying In case of a trivial code change, maintainers may choose to apply the `trivial` label. This will have mergify approve your PR, thus fulfilling all requirements to automatically queue a PR for merging. +## Changelog entries + +Our CI checks that each crate which is modified gets a changelog entry. +Whilst this is a good default safety-wise, it creates a lot of false-positives for changes that are internal and don't need a changelog entry. + +For PRs that in the categories `chore`, `deps`, `refactor` and `docs`, this check is disabled automatically. +Any other PR needs to explicitly disable this check if desired by applying the `internal-change` label. + ## Dependencies We version our `Cargo.lock` file for better visibility into which dependencies are required for a functional build.