Merge releases/v4 into releases/v3#3778
Conversation
Bumps [fast-xml-parser](https://github.com/NaturalIntelligence/fast-xml-parser) from 5.5.6 to 5.5.7. - [Release notes](https://github.com/NaturalIntelligence/fast-xml-parser/releases) - [Changelog](https://github.com/NaturalIntelligence/fast-xml-parser/blob/master/CHANGELOG.md) - [Commits](NaturalIntelligence/fast-xml-parser@v5.5.6...v5.5.7) --- updated-dependencies: - dependency-name: fast-xml-parser dependency-version: 5.5.7 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com>
Mergeback v4.34.1 refs/heads/releases/v4 into main
…-parser-5.5.7 Bump fast-xml-parser from 5.5.6 to 5.5.7
…um-git-version Reduce the minimum Git version required for overlay
Fix warning for PAT-like token with username
…r-3536e7c6f0 Bump the npm-minor group with 5 updates
Bumps [yaml](https://github.com/eemeli/yaml) from 2.8.2 to 2.8.3. - [Release notes](https://github.com/eemeli/yaml/releases) - [Commits](eemeli/yaml@v2.8.2...v2.8.3) --- updated-dependencies: - dependency-name: yaml dependency-version: 2.8.3 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
Bump yaml from 2.8.2 to 2.8.3
Update default bundle to 2.25.1
Merge main into releases/v4
This reverts commit 95a5620.
This reverts commit 97fd992.
|
Pushed a commit to rebuild the Action. Please mark the PR as ready for review to trigger PR checks. |
There was a problem hiding this comment.
Pull request overview
This PR merges changes from releases/v4 into releases/v3, bringing over improvements to diff-informed analysis/overlay behavior, release tooling/scripts, and several dependency/version updates needed for the v3 release line.
Changes:
- Persist PR diff ranges during
initand reuse them inanalyzeand overlay change-file computation. - Lower the minimum Git version required for overlay analysis by switching
git ls-filesOID collection to--stage. - Replace/augment release & required-checks tooling with TypeScript scripts under
pr-checks/, plus related config/docs/workflow updates.
Reviewed changes
Copilot reviewed 39 out of 47 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/testing-utils.ts | Enhances test logger utilities (message matching, negative assertions) and refactors getRecordingLogger. |
| src/start-proxy.ts | Fixes PAT-with-username warning logic by restructuring the condition. |
| src/start-proxy.test.ts | Expands credentials warning coverage and introduces a shared AVA macro pattern. |
| src/overlay/index.ts | Merges diff-range file paths into overlay changed-file list; adds diff-range JSON reading/conversion logic. |
| src/overlay/index.test.ts | Adds tests for overlay changes merging and source-root-relative conversion behavior. |
| src/init-action.ts | Computes and persists PR diff ranges during init for later reuse. |
| src/git-utils.ts | Lowers overlay Git minimum to 2.11.0 and updates OID collection to parse git ls-files --stage. |
| src/git-utils.test.ts | Updates tests for new git ls-files --stage output parsing. |
| src/diff-informed-analysis-utils.ts | Centralizes diff-range JSON path and hardens JSON parsing with error handling. |
| src/defaults.json | Bumps default bundle/CLI versions to 2.25.1 (and shifts prior versions accordingly). |
| src/config-utils.test.ts | Updates overlay fallback test to reflect the new minimum Git version (2.11.0). |
| src/analyze.ts | Switches diff-informed analysis setup to read precomputed diff ranges rather than recomputing. |
| src/analyze-action.ts | Updates analyze flow to call the new setupDiffInformedQueryRun(logger) signature. |
| src/actions-util.ts | Adds a shared helper for locating pr-diff-range.json in the temp directory. |
| pr-checks/sync-checks.ts | New TS tool to sync required checks using the GitHub API and exclusions config. |
| pr-checks/sync-checks.test.ts | Unit tests for required-check exclusion filtering logic. |
| pr-checks/release-branches.ts | New TS tool to compute backport source/targets based on tags and support policy. |
| pr-checks/release-branches.test.ts | Unit tests for backport-branch computation and input validation. |
| pr-checks/package.json | Adds dependencies needed for the new pr-checks scripts and bumps yaml. |
| pr-checks/excluded.yml | New config file defining which checks should be excluded from “required checks”. |
| pr-checks/config.ts | Centralizes pr-checks constants (oldest supported major version, exclusions path). |
| pr-checks/checks/rubocop-multi-language.yml | Updates pinned ruby/setup-ruby SHA/version used by the check. |
| package.json | Bumps action version to 3.35.0 and updates dev dependency versions. |
| package-lock.json | Updates lockfile for dependency bumps (but currently has inconsistent version metadata). |
| eslint.config.mjs | Tightens extraneous-dependency checks for pr-checks and adjusts config structure. |
| CONTRIBUTING.md | Updates contributor instructions to reference the new TS required-checks tool and config location. |
| CHANGELOG.md | Adds v3.35.0 entry including Git minimum reduction and default bundle update. |
| .vscode/tests.code-snippets | Adds a VS Code snippet for an AVA test macro template. |
| .github/workflows/script/update-required-checks.sh | Removes the legacy shell script now replaced by TS tooling. |
| .github/releases.ini | Removes legacy support-policy config file (moved to pr-checks config). |
| .github/actions/release-initialise/action.yml | Ensures Node is set up (with npm cache) for release workflows/actions. |
| .github/actions/release-branches/release-branches.py | Removes legacy Python backport-branch computation script. |
| .github/actions/release-branches/action.yml | Switches release-branches action to run the TS implementation via tsx. |
| .github/workflows/__rubocop-multi-language.yml | Generated workflow update reflecting new ruby/setup-ruby pin (not reviewed). |
| lib/* | Generated build artifacts updated (not reviewed). |
| let diffRanges: Array<{ path: string }>; | ||
| try { | ||
| diffRanges = JSON.parse(contents) as Array<{ path: string }>; | ||
| } catch (e) { | ||
| logger.warning( | ||
| `Failed to parse diff ranges JSON file at ${jsonFilePath}: ${e}`, | ||
| ); |
There was a problem hiding this comment.
After JSON.parse, diffRanges is assumed to be Array<{path: string}> (uses .length, .map). If the file is malformed but still valid JSON (e.g. an object, or array entries without a string path), this will throw later and can break overlay generation. Add runtime validation (array + string path) and fall back to []/warning on invalid shape.
| const check = (val: string) => | ||
| typeof messageOrRegExp === "string" | ||
| ? val.includes(messageOrRegExp) | ||
| : messageOrRegExp.test(val); |
There was a problem hiding this comment.
hasLoggedMessage uses RegExp.test(). If callers pass a global/sticky regex (e.g. /foo/g), test() mutates lastIndex, which can make subsequent checks incorrect/flaky. Consider normalizing by resetting lastIndex to 0 before testing, or by using a non-global copy of the regex.
Merging b8bb9f2 into
releases/v3.Conductor for this PR is @oscarsj.
Contains the following pull requests:
release-branches.pyandupdate-required-checks.shto TypeScript #3575 (@mbg)Please do the following:
releases/v3branch.Create a merge commitis selected rather thanSquash and mergeorRebase and merge.