Skip to content

Build: Remove patch-package - #83982

Merged
manzoorwanijk merged 1 commit into
trunkfrom
build/remove-patch-package
Oct 1, 2026
Merged

manzoorwanijk merged 1 commit into
trunkfrom
build/remove-patch-package

Conversation

@manzoorwanijk

Copy link
Copy Markdown
Member

What?

Follow up to #83847 and #83132

Removes patch-package from the root dev dependencies and the postinstall script, along with the empty patches/ directory.

Why?

The last patch was removed in #83132, so patch-package has had nothing to apply. Since #83847 switched to install-strategy=linked, it would not work anyway: it patches the hoisted node_modules/<pkg> path, which no longer holds the real package.

How?

  • Drop the dependency and the patch-package && prefix from postinstall in package.json.
  • Delete patches/README.md.
  • Drop patches/** from the npm cache key in .github/setup-npm/action.yml and the stale comment in .github/setup-node/action.yml.
  • Lockfile regenerated with npm 11.

The patch-package example in the iframe migration guide stays, since it targets third-party block authors.

Testing Instructions

  1. npm install completes and postinstall only runs agents:setup.
  2. CI passes.

Use of AI Tools

Authored with Claude Code, reviewed by me.

No patches remain and patch-package does not work with install-strategy=linked.
@manzoorwanijk manzoorwanijk added the [Type] Code Quality Issues or PRs that relate to code quality label Oct 1, 2026
@manzoorwanijk
manzoorwanijk marked this pull request as ready for review October 1, 2026 11:51
@manzoorwanijk
manzoorwanijk requested a review from desrosj as a code owner October 1, 2026 11:51
@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

🤖 PR meta 🤖

🎉 Props

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: manzoorwanijk <manzoorwanijk@git.wordpress.org>
Co-authored-by: ciampo <mciampini@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Updated as activity occurs, without notifying anyone named here. Add the props-bot label to refresh.

📦 Bundle size

Size Change: 0 B

Total Size: 8.25 MB

fb8bbe9 Run

⚡ Performance

Show the results

Client side metrics exclude the server response time.

front-end-block-theme

Metric b7d33e2 trunk % Change
timeToFirstByte 59.5 ms +8.07% -6.22% 56.55 ms +11.49% -1.68% 5.22%
largestContentfulPaint 94 ms +12.77% -6.38% 94 ms +4.26% -6.38% 0%
lcpMinusTtfb 33.95 ms +8.98% -2.06% 32.95 ms +15.17% -1.97% 3.03%
wpBeforeTemplate 28.76 ms +17% -2.57% 28.43 ms +17.9% -0.7% 1.16%
wpTemplate 25.11 ms +3.46% -6.45% 24.34 ms +3.49% -2.55% 3.16%
wpTotal 55.69 ms +7.49% -6.36% 52.85 ms +11.71% -1.42% 5.37%
wpMemoryUsage 7.62 MB +0% -0% 7.59 MB +0% -0% 0.46%
wpDbQueries 17 +0% -0% 17 +0% -0% 0%

front-end-classic-theme

Metric b7d33e2 trunk % Change
timeToFirstByte 43.45 ms +4.03% -1.73% 47.2 ms +7.2% -1.69% -7.94%
largestContentfulPaint 92 ms +4.35% -0% 100 ms +8% -0% -8%
lcpMinusTtfb 49.25 ms +2.84% -3.05% 53.9 ms +3.53% -1.3% -8.63%
wpBeforeTemplate 26.55 ms +8.74% -1.39% 26.28 ms +3.04% -2.89% 1.03%
wpTemplate 13.68 ms +3.14% -0.95% 17.88 ms +5.98% -1.45% -23.49%
wpTotal 40.58 ms +4.24% -2% 44.03 ms +7.9% -1.48% -7.84%
wpMemoryUsage 6.11 MB +0% -0% 6.20 MB +0% -0% -1.57%
wpDbQueries 10 +0% -0% 14 +0% -0% -28.57%

media-processing

Metric b7d33e2 trunk % Change
mediaProcessingJpeg 399.22 ms +0.23% -1.55% 398.78 ms +0.53% -0.21% 0.11%
mediaProcessingAvif 6038.17 ms +0.31% -0.09% 6048.41 ms +0.18% -0.23% -0.17%
mediaProcessingJpegToAvif 4165.56 ms +0.09% -0.12% 4180.89 ms +0.5% -0.29% -0.37%

media-upload

Metric b7d33e2 trunk % Change
jpegUploadProcessing 1680.68 ms +15.55% -16.31% 1414.33 ms +1.99% -0.45% 18.83%
pngUploadProcessing 170.34 ms +7.5% -2.05% 184.46 ms +25.79% -7.86% -7.65%
largeJpegUploadProcessing 1415.84 ms +0.65% -0.9% 1405.92 ms +0.74% -0.71% 0.71%
multipleImageUploadProcessing 1577.73 ms +2.36% -1.14% 1568.75 ms +1.84% -0.82% 0.57%

post-editor

Metric b7d33e2 trunk % Change
serverResponse 518.07 ms +5.85% -4.68% 516.56 ms +4.29% -6.89% 0.29%
firstPaint 237.82 ms +16.31% -10.45% 241.69 ms +29.29% -3.67% -1.6%
domContentLoaded 1128.52 ms +2.36% -1.73% 1107.9 ms +2.23% -1.72% 1.86%
loaded 1129.8 ms +2.39% -1.75% 1109.09 ms +2.22% -1.68% 1.87%
firstContentfulPaint 461.48 ms +1.54% -3.63% 453.34 ms +2.72% -2.42% 1.8%
firstBlock 3337.38 ms +1.34% -1.02% 3340.77 ms +1.26% -1.23% -0.1%
type 18.11 ms +5.63% -3.7% 19.46 ms +5.91% -4.83% -6.94%
typeWithoutInspector 18.98 ms +2.11% -6.74% 18.44 ms +1.84% -2.66% 2.93%
typeWithTopToolbar 23.82 ms +5.25% -8.27% 24 ms +3.46% -3.04% -0.75%
typeContainer 9.33 ms +5.89% -16.08% 8.76 ms +3.65% -2.74% 6.51%
focus 74.06 ms +23.35% -6.85% 76.35 ms +21.64% -5.11% -3%
firstFocus 208.8 ms +0% -0% 190.01 ms +0% -0% 9.89%
selectAll 533.03 ms +6.8% -1.51% 546.92 ms +2.77% -0.59% -2.54%
listViewOpen 63.33 ms +13.5% -1.47% 63.71 ms +13.91% -3.58% -0.6%
inserterOpen 23.33 ms +19.67% -3.94% 22.17 ms +20.39% -8.21% 5.23%
inserterHover 2.15 ms +19.07% -13.95% 2.27 ms +7.05% -13.22% -5.29%
inserterSearch 8.15 ms +7.61% -8.47% 8 ms +4.62% -6.25% 1.88%
loadPatterns 659.22 ms +1.4% -1.25% 667 ms +5.09% -4.89% -1.17%
wpTotal 507.98 ms +6% -4.73% 506.4 ms +4.45% -6.94% 0.31%
wpMemoryUsage 13.17 MB +0% -0% 13.13 MB +0% -0% 0.25%
wpDbQueries 54 +0% -1.85% 54 +0% -1.85% 0%

site-editor

Metric b7d33e2 trunk % Change
serverResponse 504.79 ms +6.51% -5.51% 492.8 ms +5.65% -5.14% 2.43%
firstPaint 238.96 ms +61.58% -18.35% 239.92 ms +5.57% -5.58% -0.4%
domContentLoaded 1169.66 ms +1.86% -1.16% 1153.97 ms +1.22% -1.5% 1.36%
loaded 1170.86 ms +1.86% -1.14% 1155.34 ms +1.2% -1.49% 1.34%
firstContentfulPaint 476.57 ms +2.87% -8.84% 452.63 ms +3.31% -1.18% 5.29%
firstBlock 4335.44 ms +1.62% -1.31% 4215.54 ms +1.32% -0.71% 2.84%
type 18.53 ms +2.75% -4.86% 19.14 ms +3.29% -6.22% -3.19%
navigate 123.4 ms +15.74% -1.04% 120.62 ms +13.62% -9.61% 2.3%
loadPatterns 1426.01 ms +11.62% -5.93% 1379.08 ms +7.67% -6.29% 3.4%
loadPages 1083.28 ms +2.38% -1.08% 1079.4 ms +1.75% -0.41% 0.36%
wpTotal 495.12 ms +6.63% -5.7% 483.13 ms +5.85% -5.29% 2.48%
wpMemoryUsage 12.14 MB +0% -0% 12.11 MB +0% -0% 0.3%
wpDbQueries 43 +2.33% -0% 43 +2.33% -0% 0%

fb8bbe9 Run

🏁 Flaky tests

Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.

should cut and paste individual blocks with collapsed selection in /test/e2e/specs/editor/various/copy-cut-paste.spec.js, passed after 1 failed attempt.
Error: expect(string).toMatchSnapshot(expected) failed

  @@ -1,3 +1,3 @@
   <!-- wp:paragraph -->
  -<p>2Cut - collapsed selection</p>
  +<p>2</p>
   <!-- /wp:paragraph -->


    at /home/runner/work/gutenberg/gutenberg/test/e2e/specs/editor/various/copy-cut-paste.spec.js:45:49

fb8bbe9 Run

@manzoorwanijk
manzoorwanijk merged commit 71c69de into trunk Oct 1, 2026
119 checks passed
@manzoorwanijk
manzoorwanijk deleted the build/remove-patch-package branch October 1, 2026 14:16
@github-actions github-actions Bot added this to the Gutenberg 24.2 milestone Oct 1, 2026
@aduth

aduth commented Oct 1, 2026

Copy link
Copy Markdown
Member

Nice! 🎉 I've long awaited this day 😄

Hopefully we can get rid of the postinstall altogether some day soon. With Claude recently adding support for AGENTS.md, one can hope they'll soon also add support for .agents/skills, which is the root motivation behind the remaining postinstall task.

widoz pushed a commit to widoz/gutenberg that referenced this pull request Oct 2, 2026
Co-authored-by: manzoorwanijk <manzoorwanijk@git.wordpress.org>
Co-authored-by: ciampo <mciampini@git.wordpress.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Type] Code Quality Issues or PRs that relate to code quality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants