Skip to content

Commit 543c846

Browse files
Merge branch 'trunk' into fix/broaden-dip-header-scope
2 parents c01143d + 5e8ec8f commit 543c846

25 files changed

Lines changed: 3718 additions & 2399 deletions

‎.github/pull_request_template.md‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,13 @@ Trac ticket: <!-- insert a link to the WordPress Trac ticket here -->
2323

2424
<!--
2525
You are free to use artificial intelligence (AI) tooling to contribute, but you must disclose what tooling you are using and to what extent a pull request has been authored by AI. It is your responsibility to review and take responsibility for what AI generates. See the WordPress AI Guidelines: <https://make.wordpress.org/ai/handbook/ai-guidelines/>.
26+
27+
Example disclosure:
28+
29+
AI assistance: Yes
30+
Tool(s): GitHub Copilot, ChatGPT
31+
Model(s): GPT-5.1
32+
Used for: Initial code skeleton and test suggestions; final implementation and tests were reviewed and edited by me.
2633
-->
2734

2835
---

‎.github/workflows/reusable-coding-standards-php.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
run: echo "date=$(/bin/date -u --date='last Mon' "+%F")" >> "$GITHUB_OUTPUT"
6666

6767
- name: Cache PHPCS scan cache
68-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
68+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
6969
with:
7070
path: |
7171
.cache/phpcs-src.json

‎.github/workflows/reusable-javascript-type-checking-v1.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ jobs:
5353
run: npm ci --ignore-scripts
5454

5555
- name: Cache TypeScript build info
56-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
56+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
5757
with:
5858
path: |
5959
*.tsbuildinfo
@@ -65,7 +65,7 @@ jobs:
6565
run: npm run typecheck:js
6666

6767
- name: "Save result cache"
68-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
68+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
6969
if: ${{ !cancelled() }}
7070
with:
7171
path: |

‎.github/workflows/reusable-php-compatibility.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
run: echo "date=$(/bin/date -u --date='last Mon' "+%F")" >> "$GITHUB_OUTPUT"
6464

6565
- name: Cache PHP compatibility scan cache
66-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
66+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
6767
with:
6868
path: .cache/phpcompat.json
6969
key: ${{ runner.os }}-date-${{ steps.get-date.outputs.date }}-php-${{ inputs.php-version }}-phpcompat-cache-${{ hashFiles('**/composer.json', 'phpcompat.xml.dist') }}

‎.github/workflows/reusable-phpstan-static-analysis-v1.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ jobs:
8787
run: npm run build:dev
8888

8989
- name: Cache PHP Static Analysis scan cache
90-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
90+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
9191
with:
9292
path: .cache # This is defined in the base.neon file.
9393
key: "phpstan-result-cache-${{ github.run_id }}"
@@ -99,7 +99,7 @@ jobs:
9999
run: composer run phpstan -- -vvv --error-format=checkstyle | cs2pr --errors-as-warnings --graceful-warnings
100100

101101
- name: "Save result cache"
102-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
102+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
103103
if: ${{ !cancelled() }}
104104
with:
105105
path: .cache

‎.github/workflows/reusable-phpunit-tests-v1.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ jobs:
121121

122122
- name: Cache Composer dependencies
123123
if: ${{ env.COMPOSER_INSTALL == true }}
124-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
124+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
125125
env:
126126
cache-name: cache-composer-dependencies
127127
with:

‎.github/workflows/reusable-phpunit-tests-v2.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ jobs:
118118
run: echo "composer_dir=$(composer config cache-files-dir)" >> "$GITHUB_OUTPUT"
119119

120120
- name: Cache Composer dependencies
121-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
121+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7 # v5.0.4
122122
env:
123123
cache-name: cache-composer-dependencies
124124
with:

‎.github/workflows/reusable-phpunit-tests-v3.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ jobs:
237237

238238
- name: Upload test coverage report to Codecov
239239
if: ${{ inputs.coverage-report }}
240-
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5.5.2
240+
uses: codecov/codecov-action@1af58845a975a7985b0beb0cbe6fbbb71a41dbad # v5.5.3
241241
with:
242242
token: ${{ secrets.CODECOV_TOKEN }}
243243
files: wp-code-coverage${{ inputs.multisite && '-multisite' || '-single' }}-${{ github.sha }}.xml

‎Gruntfile.js‎

Lines changed: 50 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -41,20 +41,30 @@ module.exports = function(grunt) {
4141
'wp-admin/css/colors/**/*.css',
4242
],
4343

44-
// All built js files, in /src or /build.
44+
// Built js files, in /src or /build.
4545
jsFiles = [
4646
'wp-admin/js/',
4747
'wp-includes/js/',
48-
'wp-includes/blocks/**/*.js',
49-
'wp-includes/blocks/**/*.js.map',
48+
],
49+
50+
// All files copied from the Gutenberg repository.
51+
gutenbergFiles = [
52+
'wp-includes/assets',
53+
'wp-includes/build',
54+
'wp-includes/js/dist',
55+
'wp-includes/css/dist',
56+
'wp-includes/blocks/**/*',
57+
'!wp-includes/blocks/index.php',
58+
'wp-includes/icons',
5059
],
5160

5261
// All files built by Webpack, in /src or /build.
62+
// Webpack only builds Core-specific media files and development scripts.
63+
// Blocks, packages, script modules, and vendors come from the Gutenberg build.
5364
webpackFiles = [
54-
'wp-includes/assets/*',
55-
'wp-includes/css/dist',
56-
'!wp-includes/assets/script-loader-packages.min.php',
57-
'!wp-includes/assets/script-modules-packages.min.php',
65+
'wp-includes/js/media-*.js',
66+
'wp-includes/js/media-*.min.js',
67+
'wp-includes/js/dist/development',
5868
],
5969

6070
// All workflow files that should be deleted from non-default branches.
@@ -229,13 +239,16 @@ module.exports = function(grunt) {
229239
js: jsFiles.map( function( file ) {
230240
return setFilePath( WORKING_DIR, file );
231241
} ),
242+
243+
// Clean files built by Webpack.
232244
'webpack-assets': webpackFiles.map( function( file ) {
233245
return setFilePath( WORKING_DIR, file );
234246
} ),
235-
'interactivity-assets': [
236-
WORKING_DIR + 'wp-includes/js/dist/interactivity.asset.php',
237-
WORKING_DIR + 'wp-includes/js/dist/interactivity.min.asset.php',
238-
],
247+
248+
// Clean files built by the tools/gutenberg scripts.
249+
gutenberg: gutenbergFiles.map( function( file ) {
250+
return setFilePath( WORKING_DIR, file );
251+
}),
239252
dynamic: {
240253
dot: true,
241254
expand: true,
@@ -627,7 +640,13 @@ module.exports = function(grunt) {
627640
files: [ {
628641
expand: true,
629642
cwd: 'gutenberg/build/modules',
630-
src: [ '**/*', '!**/*.map' ],
643+
src: [
644+
'**/*',
645+
'!**/*.map',
646+
// Skip non-minified VIPS files — they are ~16MB of inlined WASM
647+
// with no debugging value over the minified versions.
648+
'!vips/!(*.min).js',
649+
],
631650
dest: WORKING_DIR + 'wp-includes/js/dist/script-modules/',
632651
} ],
633652
},
@@ -1594,7 +1613,25 @@ module.exports = function(grunt) {
15941613
args: [ 'tools/gutenberg/download.js' ],
15951614
opts: { stdio: 'inherit' }
15961615
}, function( error ) {
1597-
done( ! error );
1616+
if ( error ) {
1617+
done( false );
1618+
return;
1619+
}
1620+
/*
1621+
* Build block editor files into the src directory every time assets
1622+
* are downloaded. This prevents failures when running from src
1623+
* without running `build:dev` after those files were removed from
1624+
* version control in https://core.trac.wordpress.org/changeset/61438.
1625+
*
1626+
* See https://core.trac.wordpress.org/ticket/64393.
1627+
*/
1628+
grunt.util.spawn( {
1629+
grunt: true,
1630+
args: [ 'build:gutenberg', '--dev' ],
1631+
opts: { stdio: 'inherit' }
1632+
}, function( buildError ) {
1633+
done( ! buildError );
1634+
} );
15981635
} );
15991636
} );
16001637

@@ -1806,7 +1843,6 @@ module.exports = function(grunt) {
18061843
'clean:webpack-assets',
18071844
'webpack:prod',
18081845
'webpack:dev',
1809-
'clean:interactivity-assets',
18101846
] );
18111847

18121848
grunt.registerTask( 'build:js', [

0 commit comments

Comments
 (0)