Skip to content

CI: scope PR pipelines, deduplicate feature pushes, cancel stale runs - #156

Merged
masarray merged 3 commits into
mainfrom
ci/targeted-pr-workflows-and-concurrency
Oct 14, 2026
Merged

masarray merged 3 commits into
mainfrom
ci/targeted-pr-workflows-and-concurrency

Conversation

@masarray

Copy link
Copy Markdown
Owner

Problem

GUI-only Workbench changes triggered unscoped BRCB, Control Interop, C++ CI, Dynamic RCB, Embedded, Security, Windows release packaging and duplicate push/PR events. Repeated small commits from PR #155 multiplied queued CI work.

Fix — one atomic commit

  • Six unscoped pipelines gain domain-specific pull_request.paths; unaffected by QML-only Workbench edits.
  • PR runs get workflow-specific PR concurrency groups with cancel-in-progress on PR events only; integrated main runs are not cancelled.
  • Feature branch push no longer duplicates PR CI for Qt Simulator, SCL-assisted Workbench/Connect, or Studio Qt; push-side integration remains on main.
  • Windows installer hardening runs on release-affecting PR paths, on relevant main pushes, or by explicit workflow_dispatch for exact-head release candidates. It is not run on every QML-only PR iteration.
  • New 2-minute CI Routing Policy workflow and deterministic no-dependency Python guard document/test the trigger invariants.
  • No protocol, firmware, application runtime, or C++/QML source changes.

Acceptance gates

  • Routing guard passes on the exact head.
  • Workflow YAML parses; changed-workflow CI executes successfully.
  • A QML-only PR head triggers IED Simulator Qt but not BRCB, Control Interop, Dynamic RCB, Embedded, Security, C++ CI, or Windows release package; SCL-assisted remains only when its C++ model files change.
  • Verify no missing required checks/rulesets before merge; Windows release package explicitly rechecked at release candidate stage.

Keep Draft until exact-head CI trigger checks are verified. This PR is intentionally separate from stacked Workbench PR #155 and must not be merged without review.

Stop unconditional embedded/control/BRCB/security/C++ matrices on Workbench-only PR changes. Keep full main integration checks, avoid push+PR duplication on feature branches, scope costly Windows release packaging, and add a lightweight CI routing policy gate plus documentation.
Limit four additional push gates to main and cancel superseded PR runs. Preserve on-branch ESP32-P4 test artifacts while coalescing same-branch push/PR runs through shared repository-scoped concurrency. Extend policy guard and documentation.
Use PR-number scoped run groups consistent with routing policy acceptance; preserve main integration runs.
@masarray
masarray marked this pull request as ready for review October 14, 2026 06:42
@masarray
masarray merged commit bb8bee4 into main Oct 14, 2026
33 of 36 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

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

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-14T06:46:47.860442Z cd64a28 Draft marked ready
ℹ️ 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.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cd64a284ba

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +38 to +39
group: esp32p4-smv-${{ github.event.pull_request.head.repo.full_name || github.repository }}-${{ github.event.pull_request.head.ref || github.ref_name }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Keep reusable firmware runs in a distinct concurrency group

When a PR changes ESP32-P4 firmware, both this standalone workflow and arstack-studio-release.yml trigger, with the latter invoking this file through workflow_call; both instances now resolve this group to the same repository-and-head value with cancellation enabled. GitHub documents that concurrency names are repository-wide and matching groups cancel the other run, so scheduling can cancel either the standalone firmware check or the release workflow's required firmware job, which then prevents its dependent Windows package from running. Include a caller/workflow discriminator while retaining branch deduplication. GitHub concurrency documentation

AGENTS.md reference: AGENTS.md:L249-L263

Useful? React with 👍 / 👎.

- "agent/phase-4d-c5-control-interoperability"
pull_request:
paths:
- 'tools/control_interop_probe/**'

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Include the top-level control probe sources in PR paths

For PRs that modify tools/control_interop_probe.cpp, tools/control_inventory_probe.cpp, or tools/control_ctlmodel_probe.cpp, this new filter does not trigger because tools/control_interop_probe/** covers the directory, while all three sources are sibling files under tools/; the workflow's CMake project explicitly compiles them and runs their offline self-tests. Add those source paths so direct harness changes still receive the specialized GCC/Clang/MSVC validation that this filter replaced.

AGENTS.md reference: AGENTS.md:L249-L263

Useful? React with 👍 / 👎.

branches: ["agent/phase-4d-d2-dynamic-rcb-live-trial"]
pull_request:
paths:
- 'tools/dynamic_rcb_trial/**'

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Include the top-level RCB trial sources in PR paths

For PRs changing tools/dynamic_rcb_trial.cpp or tools/static_rcb_trial.cpp, the workflow is now skipped because tools/dynamic_rcb_trial/** only covers the subdirectory, even though that subdirectory's CMake project builds both sibling source files and exercises their CLI contracts. Add the two top-level source paths so changes to the trial executables continue to run this dedicated cross-platform matrix.

AGENTS.md reference: AGENTS.md:L249-L263

Useful? React with 👍 / 👎.

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.

1 participant