Skip to content

Add back check-path job to workflow#3485

Merged
hathach merged 6 commits into
masterfrom
readd-ci-checkpath
Feb 10, 2026
Merged

Add back check-path job to workflow#3485
hathach merged 6 commits into
masterfrom
readd-ci-checkpath

Conversation

@hathach
Copy link
Copy Markdown
Owner

@hathach hathach commented Feb 7, 2026

The pull request reintroduces the check-path job to the path filter in the workflow. This ensures the workflow always runs to register the commit chain with membrowse.

Copilot AI review requested due to automatic review settings February 7, 2026 10:34
@hathach
Copy link
Copy Markdown
Owner Author

hathach commented Feb 7, 2026

@membrowse let me know if this could resolve the issue in #3483

Copy link
Copy Markdown

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

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: 4632441ae7

ℹ️ 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 49 to 52
set-matrix:
needs: [ check-paths ]
if: needs.check-paths.outputs.code_changed == 'true'
runs-on: ubuntu-latest
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 Allow doc-only pushes to reach membrowse chain

The new check-paths gating causes set-matrix (and therefore cmake and membrowse) to be skipped whenever code_changed is false. For pushes that only touch non-matching paths (e.g., docs), this means the workflow runs but does not execute the build or membrowse jobs, so the commit chain registration described in the comment never occurs. This regresses the intended behavior for doc-only pushes because membrowse depends on cmake and will be skipped entirely in that scenario.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the Build GitHub Actions workflow to always trigger on push/pull_request events (removing event-level paths filters) and reintroduces path-based gating via a dedicated check-paths job, with the intent of still supporting membrowse commit-chain registration.

Changes:

  • Removed on.push.paths and on.pull_request.paths filters so the workflow triggers for all pushes/PRs.
  • Added a check-paths job using dorny/paths-filter to detect whether “code” paths changed and exposed that as an output.
  • Gated selected jobs (set-matrix, build-os, zephyr) on code_changed == 'true' and added check-paths dependency wiring.
Comments suppressed due to low confidence (1)

.github/workflows/build.yml:302

  • hil-hfp now always runs for non-forked events once the workflow triggers (including doc-only pushes), since its if: condition doesn’t check needs.check-paths.outputs.code_changed. This can consume self-hosted capacity unnecessarily; gate it on code_changed == 'true' as well.
    needs: [ check-paths ]
    if: |
      github.repository_owner == 'hathach' &&
      !(github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork == true)
    runs-on: [ self-hosted, Linux, X64, hifiphile ]

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 49 to +51
set-matrix:
needs: [ check-paths ]
if: needs.check-paths.outputs.code_changed == 'true'
Copy link

Copilot AI Feb 7, 2026

Choose a reason for hiding this comment

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

set-matrix is skipped when code_changed is false, which causes the entire build chain (cmake -> membrowse) to be skipped as well. That contradicts the stated goal of always running this workflow to keep the membrowse commit chain updated on doc-only pushes; consider running the membrowse job unconditionally (passing code_changed through) and decoupling it from the cmake dependency for doc-only changes.

Copilot uses AI. Check for mistakes.
Comment thread .github/workflows/build.yml Outdated
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 7, 2026

Size Difference Report

Because TinyUSB code size varies by port and configuration, the metrics below represent the averaged totals across all example builds.

Note: If there is no change, only one value is shown.

Changes >1% in size

No entries.

Changes <1% in size

No entries.

No changes
file .text .rodata .data .bss size % diff
audio_device.c 2849 0 1248 1673 4518 +0.0%
cdc_device.c 1328 16 19 661 1988 +0.0%
cdc_host.c 6596 487 15 1539 8357 +0.0%
dcd_ch32_usbfs.c 1472 0 0 2444 3916 +0.0%
dcd_ch32_usbhs.c 1648 0 0 448 2096 +0.0%
dcd_ci_fs.c 1925 0 0 1290 3215 +0.0%
dcd_ci_hs.c 1762 0 0 1280 2530 +0.0%
dcd_da146xx.c 3067 0 0 144 3211 +0.0%
dcd_dwc2.c 4101 24 0 263 4387 +0.0%
dcd_eptri.c 2270 0 0 259 2529 +0.0%
dcd_khci.c 1953 0 0 1290 3243 +0.0%
dcd_lpc17_40.c 1470 0 0 648 1794 +0.0%
dcd_lpc_ip3511.c 1463 0 0 264 1639 +0.0%
dcd_mm32f327x_otg.c 1478 0 0 1290 2768 +0.0%
dcd_msp430x5xx.c 1796 0 0 176 1972 +0.0%
dcd_musb.c 2446 0 0 160 2606 +0.0%
dcd_nrf5x.c 2919 0 0 292 3211 +0.0%
dcd_nuc120.c 1093 0 0 78 1171 +0.0%
dcd_nuc121.c 1167 0 0 101 1268 +0.0%
dcd_nuc505.c 0 0 1529 157 1686 +0.0%
dcd_rp2040.c 859 20 604 655 2138 +0.0%
dcd_rusb2.c 2917 0 0 156 3073 +0.0%
dcd_samd.c 1032 0 0 266 1298 +0.0%
dcd_samg.c 1319 0 0 72 1391 +0.0%
dcd_stm32_fsdev.c 2557 0 0 291 2848 +0.0%
dfu_device.c 744 28 712 183 926 +0.0%
dfu_rt_device.c 156 0 134 0 156 +0.0%
dwc2_common.c 582 29 0 0 597 +0.0%
ecm_rndis_device.c 1037 0 1 2272 3310 +0.0%
ehci.c 2761 0 0 5970 7537 +0.0%
fsdev_common.c 180 0 0 0 180 +0.0%
hcd_ch32_usbfs.c 2484 0 0 498 2982 +0.0%
hcd_ci_hs.c 190 0 0 0 190 +0.0%
hcd_dwc2.c 4893 30 0 512 5434 +0.0%
hcd_khci.c 2442 0 0 449 2891 +0.0%
hcd_musb.c 3073 0 0 157 3230 +0.0%
hcd_pio_usb.c 262 0 240 0 502 +0.0%
hcd_rp2040.c 976 73 416 384 1849 +0.0%
hcd_rusb2.c 2923 0 0 245 3168 +0.0%
hcd_samd.c 2220 0 0 324 2544 +0.0%
hcd_stm32_fsdev.c 3282 0 1 420 3703 +0.0%
hid_device.c 1118 44 997 115 1233 +0.0%
hid_host.c 1206 0 0 1250 2456 +0.0%
hub.c 1235 8 8 29 1268 +0.0%
midi_device.c 1127 0 991 589 1714 +0.0%
midi_host.c 1353 7 7 3740 5097 +0.0%
msc_device.c 2503 108 2274 538 3041 +0.0%
msc_host.c 1589 0 0 394 1984 +0.0%
mtp_device.c 1689 22 1449 579 2275 +0.0%
ncm_device.c 1514 28 1408 5830 7358 +0.0%
ohci.c 1942 0 0 2414 4356 +0.0%
rp2040_usb.c 172 75 718 4 969 +0.0%
rusb2_common.c 160 0 16 0 176 +0.0%
tusb.c 429 0 368 3 430 +0.0%
tusb_fifo.c 843 0 477 0 838 +0.0%
typec_stm32.c 820 8 2 12 842 +0.0%
usbc.c 420 2 20 166 608 +0.0%
usbd.c 3190 57 89 276 3531 +0.0%
usbd_control.c 523 0 474 78 600 +0.0%
usbh.c 4395 60 63 954 5436 +0.0%
usbtmc_device.c 2176 24 69 291 2500 +0.0%
vendor_device.c 624 0 530 464 1087 +0.0%
video_device.c 4391 5 1851 472 4855 +0.0%
TOTAL 113111 1155 16730 45509 160706 +0.0%

hathach and others added 2 commits February 7, 2026 18:00
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@michael-membrowse
Copy link
Copy Markdown
Contributor

@membrowse let me know if this could resolve the issue in #3483

The membrowse job currently has needs: cmake, but when code_changed is false, the dependency chain (set-matrix
cmake) gets skipped, which causes membrowse to also be skipped.

This breaks the commit chain tracking for MemBrowse on push events (even doc-only pushes should register with MemBrowse).

Suggested fix - restore the original logic with always() and event checks:

membrowse:
  needs: [check-paths, cmake]
  if: |
    always() && !cancelled() && (
      github.event_name == 'push' ||
      github.event_name == 'release' ||
      github.event_name == 'workflow_dispatch' ||
      (github.event_name == 'pull_request' && needs.check-paths.outputs.code_changed == 'true')
    )
  permissions:
    contents: read
    actions: read
  uses: ./.github/workflows/membrowse-report.yml
  with:
    code_changed: ${{ needs.check-paths.outputs.code_changed == 'true' || github.event_name == 'release' || github.event_name == 'workflow_dispatch'
}}
  secrets: inherit

Key changes:

  1. Add check-paths to needs so we can access its output
  2. Add always() && !cancelled() so the job runs even when cmake is skipped
  3. Explicit event checks: always run on push/release/workflow_dispatch, but only run on PR if code changed
  4. Pass actual code_changed value instead of hardcoded true

@hathach
Copy link
Copy Markdown
Owner Author

hathach commented Feb 9, 2026

@copilot update using suggestion below

@membrowse let me know if this could resolve the issue in #3483

The membrowse job currently has needs: cmake, but when code_changed is false, the dependency chain (set-matrixcmake) gets skipped, which causes membrowse to also be skipped.

This breaks the commit chain tracking for MemBrowse on push events (even doc-only pushes should register with MemBrowse).

Suggested fix - restore the original logic with always() and event checks:

membrowse:
  needs: [check-paths, cmake]
  if: |
    always() && !cancelled() && (
      github.event_name == 'push' ||
      github.event_name == 'release' ||
      github.event_name == 'workflow_dispatch' ||
      (github.event_name == 'pull_request' && needs.check-paths.outputs.code_changed == 'true')
    )
  permissions:
    contents: read
    actions: read
  uses: ./.github/workflows/membrowse-report.yml
  with:
    code_changed: ${{ needs.check-paths.outputs.code_changed == 'true' || github.event_name == 'release' || github.event_name == 'workflow_dispatch'
}}
  secrets: inherit

Key changes:

  1. Add check-paths to needs so we can access its output
  2. Add always() && !cancelled() so the job runs even when cmake is skipped
  3. Explicit event checks: always run on push/release/workflow_dispatch, but only run on PR if code changed
  4. Pass actual code_changed value instead of hardcoded true

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 9, 2026

@hathach I've opened a new pull request, #3488, to work on those changes. Once the pull request is ready, I'll request review from you.

Copilot AI and others added 2 commits February 9, 2026 12:18
Co-authored-by: hathach <249515+hathach@users.noreply.github.com>
Fix membrowse job to run on all pushes for commit chain tracking
@michael-membrowse
Copy link
Copy Markdown
Contributor

@hathach I've opened a new pull request, #3488, to work on those changes. Once the pull request is ready, I'll request review from you.

@hathach I don't know if you noticed, but the copilot merged it's pull request into this pull request. So to get the changes to master, this pull request needs to be merged :)

@hathach
Copy link
Copy Markdown
Owner Author

hathach commented Feb 10, 2026

@hathach I've opened a new pull request, #3488, to work on those changes. Once the pull request is ready, I'll request review from you.

@hathach I don't know if you noticed, but the copilot merged it's pull request into this pull request. So to get the changes to master, this pull request needs to be merged :)

yeah, pr to pr is intended

@hathach hathach merged commit 207396b into master Feb 10, 2026
201 checks passed
@hathach hathach deleted the readd-ci-checkpath branch February 10, 2026 03:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants