Repository navigation
Conversation
|
This pull request is automatically being deployed by Amplify Hosting (learn more). |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 46833d8cab
ℹ️ 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".
| const [command, tag, flag] = process.argv.slice(2); | ||
| if (command === 'pack') packCandidates(CANDIDATES, JSON.parse(process.env.CHANGED_PACKAGES || '[]')); | ||
| else if (command === 'publish') publishCandidates(CANDIDATES, tag, flag === '--dry-run'); |
There was a problem hiding this comment.
Reject invalid publish arguments instead of failing open
When an authenticated operator invokes consumer-builds:publish with a missing tag or a misspelled/unsupported third argument (for example, next --dryrun), this dispatch fails open: the missing tag is coerced to the valid string undefined, while every flag except exact --dry-run becomes dryRun=false, so npm can perform a real publish. I checked npm publish --help, which lists [--tag <tag>] ... [--dry-run], and a dry run with --tag undefined reports Publishing ... with tag undefined; reject absent tags and unknown flags before calling publishCandidates.
Useful? React with 👍 / 👎.
COMPLETES
Adds the requested consumer bundler release checks as a follow-up to #751. No separate issue was supplied.
This pull request addresses
A package can pass the repo's Webpack build and still fail when a host app uses another bundler. The wellness media regression is one example. We need to check consumer builds before publishing a release, and make each bundler check configurable.
Dependency: merge #751 first. This branch starts from
nextatc298215cand includes only the workflow, fixtures, tests, and documentation. It does not include the media fix. Currentnextfails the new Vite check as expected.by making the following changes
nextand for release checks.tooling/consumer-builds/config.jsonfile for both paths. Webpack, Vite, Parcel, Rollup, and esbuild are enabled by default. Set a bundler'senabledflag tofalseto omit its check. Invalid flags and disabling all five fail validation.@webex/test-fixturesfrom npm publishing.ai-docs/CONSUMER_BUILDS.mddocument and its spec index links.Change Type
The following scenarios were tested
nextcandidate: Vite rejected the exact!!./emit-wellness-asset.cjs!./WellnessBreakSound.mp3request. Webpack passed. This proves that a passing repository Webpack build does not cover the regression.645707ff: all five consumers passed their builds and browser startup checks. Each result matched the SHA-256 hashes for the same nine archives. No source changes from fix(cc-widgets): restore bundler compatibility for wellness media #751 were added to this branch.falseremoved it from the matrix, and a direct Parcel invocation failed before installation. Restored all five default flags.actionlint, Prettier checks, immutable install after edits, staged secret-pattern scan, andgit diff --check.nextdist tag. An already-published legacy version was rejected as expected. No package was published.Browser: Playwright 1.64.0 and Chromium 156.0.8078.4. These checks cover the fixture and pinned versions. They do not cover all consumer configurations, development servers, media playback, CSP policies, or authenticated agent sessions. GitHub Actions execution has not yet been verified. The existing fork PR CI also needs a code owner to add the
validatedlabel.Testing and configuration:
ai-docs/CONSUMER_BUILDS.md.Rollback: revert this workflow change. To omit one bundler check, change its config flag.
The GAI Coding Policy And Copyright Annotation Best Practices
Checklist before merging
nextconsumer candidate must remain failing until fix(cc-widgets): restore bundler compatibility for wellness media #751 merges. GitHub checks are pending.Make sure to have followed the contributing guidelines before submitting.