-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Theme: Ensure build artifacts are synced in version control #73894
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Size Change: 0 B Total Size: 2.58 MB ℹ️ View Unchanged
|
This reverts commit 2109745.
|
The example problematic code fails as expected (see action run logs), reverted in 619e9e0: |
| "other:changelog": "node ./bin/plugin/cli.js changelog", | ||
| "other:check-licenses": "concurrently \"node ./bin/check-licenses.mjs\" \"wp-scripts check-licenses --dev\"", | ||
| "preother:check-local-changes": "npm run docs:build", | ||
| "preother:check-local-changes": "npm run docs:build && npm run --workspace @wordpress/theme build", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this be enough? Is it possible the check is green but something gets merged in the meantime that results in this broken in trunk again?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can't imagine a scenario where that would happen. The build artifacts are deterministic based on the source tokens, so the result from the build script should always be what we want to exist in trunk. Same as how we think about the npm run docs:build and npm install commands.
tyxla
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! 🚢
What?
Updates the existing "Check local changes" continuous integration step to validate correctness of the
@wordpress/themepackage built artifacts.Why?
Prior to these changes, there were no assurances that the files generated from the package build were accurate. Since the artifacts are tracked in version control, the changes here provide assurances that they are in sync with the source files.
Testing Instructions
Validate that the temporary test commit in this branch produces an expected build failure, and that the build failure goes away after the temporary change is reverted.