Skip to content

[BUG](ci) Tolerate no-package diff in the changelog fragment check - #636

Closed
Seth Fitzsimmons (sethfitz) wants to merge 1 commit into
mainfrom
fix-changelog-check-misfire
Closed

[BUG](ci) Tolerate no-package diff in the changelog fragment check#636
Seth Fitzsimmons (sethfitz) wants to merge 1 commit into
mainfrom
fix-changelog-check-misfire

Conversation

@sethfitz

Copy link
Copy Markdown
Collaborator

Fixes #635.

Problem

The Require changelog on package change job aborts with a bare exit 1 on any PR whose diff touches no file under packages/ (a workflow-only, docs-only, or root-only change). The touched pipeline runs grep -oE "^packages/[^/]+/" under set -euo pipefail; with no packages/ path in the diff the grep matches nothing and exits 1, the command substitution inherits that status, and set -e kills the job before any output. The result is indistinguishable from a real missing-fragment failure: no ::error::, no package list, just exit 1.

The sibling has_fragment / has_changelog substitutions already guard their grep -c with || true; the touched pipeline was missed.

Observed on #626, a workflow-only publish fix, which was forced to carry a fragment to go green.

Change

Append || true to the touched pipeline, matching the existing guard. Real detection is unaffected — a package changed without a fragment still fails.

Verification

Ran the job logic against four diffs:

Diff Before After
workflow only (no package) abort exit 1 (false fail) pass
package changed, no fragment fail fail
package changed + fragment pass pass
fragment only pass pass

This PR is itself workflow-only. Because the check is on: pull_request, it runs this PR's fixed workflow, so the job exercises the fix on its own diff.

The touched-packages pipeline ran grep -oE '^packages/[^/]+/' under set
-euo pipefail. On a PR touching no package the grep matched nothing,
exited 1, and the command substitution aborted the job with a bare exit
1 and no output -- a false failure indistinguishable from a real missing
fragment. Guard the pipeline with || true, matching the has_* greps.

Fixes #635

Signed-off-by: Seth Fitzsimmons <seth@mojodna.net>
@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

🗺️ Schema reference docs preview is live!

🌍 Preview https://staging.overturemaps.org/schema/pr/636/schema/index.html
🕐 Updated Aug 05, 2026 16:11 UTC
📝 Commit 6178f62
🔧 env SCHEMA_PREVIEW true

Note

♻️ This preview updates automatically with each push to this PR.

@lowlydba John McCall (lowlydba) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest closing this in favor of #645 which handles this + other latent concerns with the fragment check that need to be fixed for progressing the automation broadly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automation 🦾 Change/enhance automation of a process

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG](ci) Changelog fragment check false-fails on PRs that touch no package

2 participants