Skip to content

CI: make code path notification rules match, and read every changed file - #6971

Merged
patmmccann merged 3 commits into
prebid:masterfrom
patmmccann:agent/fix-codepath-notification-matching
Nov 23, 2026
Merged

patmmccann merged 3 commits into
prebid:masterfrom
patmmccann:agent/fix-codepath-notification-matching

Conversation

@patmmccann

Copy link
Copy Markdown
Collaborator

Stacked on #6969. Merge #6969 first: this branch is based on it, so the diff here also shows its commit until it merges. The only new commit is "CI: make code path notification rules match, and read every changed file".

Diagnosis

The rules in .github/workflows/scripts/codepath-notification are regexes that all start with /, for example /dev-docs/bidders/rubicon. The PR files API returns names without a leading slash, for example dev-docs/bidders/rubicon.md. The script tests each rule against that name, so no rule has ever matched.

Example: #6924 changed only dev-docs/bidders/rubicon.md, which has a rule. Its run (41342348848) logged:

Changed files: [ 'dev-docs/bidders/rubicon.md' ]
No matches found. Exiting successfully.

#6926 (dev-docs/bidders/kargo.md, run 41341722524) logged the same.

The script also read only the first page of the files API (30 files).

Fix

  • Test the rules against the file name with a leading / added, so a leading / in a rule means the repository root. Existing rules work unchanged, and so would rules written without the slash. Rules are still unanchored regexes, as in Prebid.js: /dev-docs/bidders/ix also matches ix-server.md, and /dev-docs/bidders/msft matches msftstaila.md. Both are those vendors' own pages. The header of codepath-notification now says this.
  • Follow the files API's Link: rel="next" header, with per_page=100, as Prebid.js's send-notification-on-change.js does.

Email grouping and sending are unchanged: one email per address, listing its matching files.

Testing

I ran the script in a vm with axios and nodemailer stubbed. The checks:

Dry run on real PRs

I ran the new matcher on the complete file lists of all 220 PRs opened from 2026-09-21 to 2026-11-16 (8 weeks), with the rules on this branch. Nothing was sent.

PR Contact Files Runs
#6760 kraken@kargo.com kargo.md 1
#6761 kraken@kargo.com kargo.md 1
#6770 connect@adspiro.io ad_spiro.md 4
#6781 header-bidding@pubmatic.com pubmatic.md 3
#6791 pdu-supply-prebid@indexexchange.com ix-server.md, ix.md 1
#6862 kraken@kargo.com kargo.md 3
#6903 prebid@openx.com openxoutstream.md (deleted) 2
#6907 pdu-supply-prebid@indexexchange.com ix.md 2
#6914 prebid@microsoft.com msftstaila.md 5
#6924 header-bidding@magnite.com rubicon.md 2
#6926 kraken@kargo.com kargo.md 1

"Runs" counts the notification runs for each PR. The workflow runs on every push (opened, synchronize, reopened), and each run sends again.

Email volume

There are 10 rules, so one run can email at most 10 addresses, even if a PR touches every bidder page. Prebid.js's version has no guard. I don't think this needs a limit on the number of contacts. The bigger source of repeat emails is re-sending on every push. If that becomes a problem, the workflow could notify only on opened and reopened, or skip a PR that was already notified. I left this alone for you to decide.

Note

Vendors listed in codepath-notification will start receiving emails after this merges. At the rate above, that is a few emails a week.

🤖 Generated with Claude Code

patmmccann and others added 2 commits November 16, 2026 17:23
…e Qwen smoke test

- code-path-changes.yml runs on workflow_run after a new unprivileged
  "PR info" workflow, from the default branch. The PR number from the
  artifact is checked against the triggering commit by a trusted-pr action.
  Secrets are only in the notification step's env; dependencies are pinned
  and installed outside the checkout; Node 24.
- send-notification-on-change.js escapes PR file names in the email HTML
  and fails the run when an email can't be sent.
- bounded-qwen-smoke.yml runs on pull_request, for same-repo branches only.

Follows prebid/Prebid.js#16201.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The rules in codepath-notification start with / (/dev-docs/bidders/rubicon),
but the PR files API returns names without one (dev-docs/bidders/rubicon.md),
so no rule ever matched. Test the rules against the file name with a leading /,
so they match from the repository root.

Also follow the files API's Link rel="next" header with per_page=100, like
Prebid.js does, so PRs with more than 30 files are fully checked.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@netlify

netlify Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

👷 Deploy request for prebid-docs-preview pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 55db8f1

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-16T23:19:02.023175Z 644b587 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@muuki88

muuki88 commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Hi @chatgpt-codex-connector

Can you resolve the merge conflicts?

@chatgpt-codex-connector

Copy link
Copy Markdown

To use Codex here, create a Codex account and connect to github.

Keep the current bounded Qwen review workflow from master and preserve the notification path matching and pagination changes.
@patmmccann
patmmccann merged commit b20c83d into prebid:master Nov 23, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants