chore(ci): gate behavior and superdoc tests on changed paths - #3031
Merged
Conversation
Add a detect job (dorny/paths-filter, SHA-pinned) to ci-behavior.yml and ci-superdoc.yml that flags whether the PR touches paths relevant to each suite. Downstream jobs gate on the detect output; merge_group and workflow_dispatch always run the full suite. The validate sentinel passes when detect says "skip" so the required check still reports green, but treats any other skipped/failed/cancelled downstream job as a failure (catches accidental matrix or dependency skips, not just job failures). Removes ci-superdoc.yml's workflow-level paths-ignore, which could leave its required check pending forever on docs/sibling-package-only PRs.
- Add pull-requests: read to detect job so dorny/paths-filter can list changed files via the GitHub API on PR events (workflow-level token was scoped to contents: read only). - Behavior filter: add tsconfig.base.json, tsconfig.references.json, vite.sourceResolve.ts (build inputs). - SuperDoc filter: add apps/cli/** (cli-tests), packages/collaboration-yjs/** (coverage build), packages/docx-evidence-contracts/** (root typecheck references), plus tsconfig.base.json, tsconfig.references.json, vite.sourceResolve.ts, vitest.baseConfig.ts, eslint.config.mjs. - Validate sentinels now fail fast when detect itself failed or was cancelled, instead of treating empty outputs as 'no relevant paths'.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e752a50794
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
- Behavior matrix now runs chromium + firefox + webkit whenever the detect gate says the suite is relevant. merge_queue is not enabled, so the merge_group fallback never fires today; if the suite runs at all, it should give us cross-browser coverage at PR time. - Behavior filter: widen packages/document-api/src/** to packages/document-api/** so package.json/exports changes also trigger (the harness imports the package, not just src). - SuperDoc filter: add patches/**, .prettierrc, .prettierignore. Patches are wired through patchedDependencies in both package.json and pnpm-workspace.yaml, so a bad patch breaks pnpm install. The prettier configs are read by `pnpm run format --check`.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Today behavior tests run on every PR regardless of paths, and ci-superdoc.yml uses workflow-level paths-ignore, which can leave its required check pending forever on docs-only PRs. This adds a detect job (dorny/paths-filter, SHA-pinned) per workflow that flags whether the PR touches paths relevant to each suite, gates downstream jobs on the result, and keeps the required validate sentinels reporting in every case.