Skip to content

Bump the wordpress-packages group across 1 directory with 4 updates and fix line-js errors#2461

Open
mukeshpanchal27 wants to merge 5 commits intotrunkfrom
fix/lint-js
Open

Bump the wordpress-packages group across 1 directory with 4 updates and fix line-js errors#2461
mukeshpanchal27 wants to merge 5 commits intotrunkfrom
fix/lint-js

Conversation

@mukeshpanchal27
Copy link
Copy Markdown
Member

@mukeshpanchal27 mukeshpanchal27 commented Apr 23, 2026

Bumps the wordpress-packages group with 4 updates in the / directory: @wordpress/e2e-test-utils-playwright, @wordpress/env, @wordpress/prettier-config and @wordpress/scripts.

Updates @wordpress/e2e-test-utils-playwright from 1.43.0 to 1.44.0

Changelog

Sourced from @​wordpress/e2e-test-utils-playwright's changelog.

1.44.0 (2026-04-15)

Commits
  • b862d8c chore(release): publish
  • a3c385b Update changelog files
  • bbb9ce0 Merge changes published in the Gutenberg plugin "release/23.0" branch
  • See full diff in compare view

Updates @wordpress/env from 11.3.0 to 11.4.0

Changelog

Sourced from @​wordpress/env's changelog.

11.4.0 (2026-04-15)

Bug Fixes

  • Fix WP-Cron, REST API loopback, and Site Health loopback failures when wp-env runs on a non-default port. Apache inside the WordPress container now also listens on the host-mapped port, so PHP loopback requests to WP_HOME succeed instead of being refused. (#20569)
Commits
  • b862d8c chore(release): publish
  • a3c385b Update changelog files
  • bbb9ce0 Merge changes published in the Gutenberg plugin "release/23.0" branch
  • See full diff in compare view

Updates @wordpress/prettier-config from 4.43.0 to 4.44.0

Changelog

Sourced from @​wordpress/prettier-config's changelog.

4.44.0 (2026-04-15)

Commits

Updates @wordpress/scripts from 31.8.0 to 32.0.0

Changelog

Sourced from @​wordpress/scripts's changelog.

32.0.0 (2026-04-15)

Breaking Changes

  • The bundled eslint dependency has been upgraded from v8 to v10 (#76654).
  • The lint-js script now uses flat config (eslint.config.*) by default. Legacy .eslintrc.* files are still detected as a fallback, but this support is deprecated and will be removed in a future version (#76654).
  • The default config shipped with wp-scripts has changed from config/.eslintrc.js to config/eslint.config.cjs (#76654).
Commits
  • b862d8c chore(release): publish
  • a3c385b Update changelog files
  • bbb9ce0 Merge changes published in the Gutenberg plugin "release/23.0" branch
  • See full diff in compare view

@mukeshpanchal27 mukeshpanchal27 self-assigned this Apr 23, 2026
@mukeshpanchal27 mukeshpanchal27 added [Type] Bug An existing feature is broken Infrastructure Issues for the overall performance plugin infrastructure no milestone PRs that do not have a defined milestone for release labels Apr 23, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 69.33%. Comparing base (097e644) to head (3d99ad9).
⚠️ Report is 12 commits behind head on trunk.

Additional details and impacted files
@@            Coverage Diff             @@
##            trunk    #2461      +/-   ##
==========================================
+ Coverage   69.17%   69.33%   +0.16%     
==========================================
  Files          90       90              
  Lines        8243     7749     -494     
==========================================
- Hits         5702     5373     -329     
+ Misses       2541     2376     -165     
Flag Coverage Δ
multisite 69.33% <ø> (+0.16%) ⬆️
single 35.73% <ø> (+0.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@westonruter
Copy link
Copy Markdown
Member

Why is this needed?

@mukeshpanchal27
Copy link
Copy Markdown
Member Author

Why is this needed?

I check lint-js on local and get errors on .min files so just try to reproduce it on GHA will revert that once fixed.

@westonruter
Copy link
Copy Markdown
Member

Curious. Minified JS files should be excluded from linting:

'/**/*.min.js',

@mukeshpanchal27 mukeshpanchal27 changed the title Add build step before JS linting in workflow Bump the wordpress-packages group across 1 directory with 4 updates and fix line-js errors Apr 24, 2026
@mukeshpanchal27 mukeshpanchal27 marked this pull request as ready for review April 24, 2026 04:32
@github-actions
Copy link
Copy Markdown

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 props-bot label.

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: mukeshpanchal27 <mukesh27@git.wordpress.org>
Co-authored-by: westonruter <westonruter@git.wordpress.org>

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

@mukeshpanchal27 mukeshpanchal27 requested a review from b1ink0 April 24, 2026 04:39
Comment thread eslint.config.js
@@ -0,0 +1,71 @@
/**
* ESLint flat config (ESLint 8+)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So 8+ includes 10?

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates WordPress tooling dependencies and migrates the project’s JS linting setup to ESLint flat config, alongside cleanup of previously required inline ESLint disable directives.

Changes:

  • Bump @wordpress/* devDependencies (notably @wordpress/scripts to v32) and refresh package-lock.json.
  • Replace legacy .eslintrc.js with a new eslint.config.js flat configuration.
  • Remove several inline ESLint disable comments related to no-console, camelcase, and an unused rule suppression.

Reviewed changes

Copilot reviewed 5 out of 10 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
package.json Bumps @wordpress/* tooling dependencies (incl. @wordpress/scripts major upgrade).
package-lock.json Updates lockfile to reflect new WordPress tooling and ESLint dependency tree.
eslint.config.js Adds ESLint flat config to replace legacy .eslintrc usage.
.eslintrc.js Removes deprecated legacy ESLint config.
webpack.config.js Removes an inline ESLint disable related to console usage.
plugins/optimization-detective/detect.js Removes inline ESLint disables for console logging in logger.
bin/validate-json.js Removes file-level no-console disable and a rule suppression near timeout handling.
bin/plugin/lib/logger.js Removes inline no-console suppression for console.log.
bin/plugin/commands/changelog.js Removes inline camelcase suppressions for GitHub API fields.
bin/plugin/cli.js Removes inline no-console suppression for error reporting.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread eslint.config.js
Comment on lines +5 to +9

const importPlugin = require( 'eslint-plugin-import' );
const jsdocPlugin = require( 'eslint-plugin-jsdoc' );

module.exports = [
Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eslint.config.js currently defines a standalone flat config but does not extend the base WordPress ESLint configuration previously provided by @wordpress/scripts. This likely drops a large set of WordPress rules/overrides and makes the header comment (“Based on WordPress coding standards”) inaccurate. Consider importing/spreading the config shipped by @wordpress/scripts (config/eslint.config.*) and then layering the few local rule/override tweaks on top (import/no-unresolved ignore + view-transitions definedTypes).

Suggested change
const importPlugin = require( 'eslint-plugin-import' );
const jsdocPlugin = require( 'eslint-plugin-jsdoc' );
module.exports = [
const wordpressScriptsConfig = require( '@wordpress/scripts/config/eslint.config' );
const importPlugin = require( 'eslint-plugin-import' );
const jsdocPlugin = require( 'eslint-plugin-jsdoc' );
module.exports = [
...wordpressScriptsConfig,

Copilot uses AI. Check for mistakes.
Comment thread eslint.config.js
Comment on lines +22 to +41
{
files: [ '**/*.js' ],
plugins: {
import: importPlugin,
jsdoc: jsdocPlugin,
},
languageOptions: {
ecmaVersion: 2020,
sourceType: 'module',
globals: {
// Browser
window: 'readonly',
document: 'readonly',
navigator: 'readonly',
console: 'readonly',
// WordPress
wp: 'readonly',
wpApiSettings: 'readonly',
},
},
Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This config applies browser globals (window/document/wp) and sourceType: 'module' to all **/*.js, including Node/CommonJS scripts in bin/** and build tooling like webpack.config.js. That can mask environment-specific issues and, if you later re-enable no-undef via a base config, will start flagging CommonJS globals (require/module) incorrectly. Consider splitting into separate overrides for Node/tooling vs browser code (and set appropriate globals/sourceType/ecmaVersion for each).

Copilot uses AI. Check for mistakes.
Comment thread eslint.config.js
Comment on lines +6 to +8
const importPlugin = require( 'eslint-plugin-import' );
const jsdocPlugin = require( 'eslint-plugin-jsdoc' );

Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eslint.config.js directly require()s eslint-plugin-import and eslint-plugin-jsdoc, but they are not listed in this repo’s devDependencies (they appear to be transitive via @wordpress/scripts). Because ESLint loads the config at runtime, relying on transitive/hoisted dependencies can break installs if the dependency tree or package manager behavior changes. Prefer extending the @wordpress/scripts config (which wires plugins internally) or add these plugins explicitly to devDependencies.

Copilot uses AI. Check for mistakes.
Comment thread package.json
Comment on lines +19 to +22
"@wordpress/e2e-test-utils-playwright": "^1.44.0",
"@wordpress/env": "^11.4.0",
"@wordpress/prettier-config": "^4.44.0",
"@wordpress/scripts": "^32.0.0",
Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bumping @wordpress/scripts to v32 pulls in ESLint v10, which (per package-lock) requires Node ^20.19.0 || ^22.13.0 || >=24. The repo’s engines.node currently allows >=20.10.0, so installs/linting may fail or warn on Node 20.10–20.18. Consider updating the Node engine (and any CI/.nvmrc versions) to meet the new minimum required by the updated tooling.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Infrastructure Issues for the overall performance plugin infrastructure no milestone PRs that do not have a defined milestone for release [Type] Bug An existing feature is broken

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants