Skip to content

fix: ESLint 10 CI lint failures#161

Merged
HollowMan6 merged 2 commits into
dependabot/npm_and_yarn/main/eslint-10.0.1from
copilot/sub-pr-159
Feb 27, 2026
Merged

fix: ESLint 10 CI lint failures#161
HollowMan6 merged 2 commits into
dependabot/npm_and_yarn/main/eslint-10.0.1from
copilot/sub-pr-159

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 27, 2026

Is your PR related to an issue? Please describe.
No.

Describe what problem you have solved or what feature you have added.
CI lint job was failing after bumping ESLint 9→10 due to three breaking changes:

  • Node.js version (npm-lint.yml): ESLint 10 requires ^20.19.0 || ^22.13.0 || >=24; CI was pinned to Node 18. Updated to Node 20.
  • Missing @eslint/js dep (package.json): ESLint 10 unbundled @eslint/js into a standalone package. Added it explicitly.
  • no-useless-assignment error (extension.js:635): This rule was promoted into js.configs.recommended in ESLint 10. Fixed the useless initializer:
    // before
    let stateConf = false;  // immediately overwritten in both if/else branches
    
    // after
    let stateConf;

Additional context
All pre-existing no-shadow warnings are unrelated and unchanged.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

…ssignment error

Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>
Copilot AI changed the title [WIP] Update eslint from 9.39.2 to 10.0.1 fix: ESLint 10 CI lint failures Feb 27, 2026
@HollowMan6 HollowMan6 marked this pull request as ready for review February 27, 2026 13:30
Copilot AI review requested due to automatic review settings February 27, 2026 13:30
@HollowMan6 HollowMan6 merged commit 4b50aab into dependabot/npm_and_yarn/main/eslint-10.0.1 Feb 27, 2026
1 check passed
@HollowMan6 HollowMan6 deleted the copilot/sub-pr-159 branch February 27, 2026 13:30
Copy link
Copy Markdown

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

This PR fixes CI lint failures after upgrading to ESLint 10 by aligning the repo’s tooling dependencies and CI runtime with ESLint 10’s new requirements.

Changes:

  • Add @eslint/js as an explicit dependency to satisfy ESLint 10’s unbundling.
  • Update the GitHub Actions lint workflow to use Node 20 (instead of 18).
  • Remove a useless assignment flagged by ESLint 10 (no-useless-assignment) in the GNOME extension code.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.

File Description
package.json Adds @eslint/js dependency required by the existing flat config import.
package-lock.json Locks @eslint/js and associated metadata for reproducible installs.
customize-ibus@hollowman.ml/extension.js Removes an initializer that is immediately overwritten, satisfying ESLint 10’s recommended rules.
.github/workflows/npm-lint.yml Bumps CI Node version to address ESLint 10 engine requirements.

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

- uses: actions/setup-node@v6
with:
node-version: 18
node-version: 20
Copy link

Copilot AI Feb 27, 2026

Choose a reason for hiding this comment

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

node-version: 20 may still install a Node 20.x release below ESLint 10's required engine (^20.19.0 || ^22.13.0 || >=24 as recorded in the lockfile), which can make the workflow flaky depending on what version setup-node resolves. Consider pinning the workflow to a minimum compatible version (e.g. 20.19.0 or 22.13.0) to match ESLint's engine requirement deterministically.

Suggested change
node-version: 20
node-version: '20.19.0'

Copilot uses AI. Check for mistakes.
HollowMan6 added a commit that referenced this pull request Feb 27, 2026
* chore(deps): bump eslint from 9.39.2 to 10.0.1

Bumps [eslint](https://github.com/eslint/eslint) from 9.39.2 to 10.0.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Commits](eslint/eslint@v9.39.2...v10.0.1)

---
updated-dependencies:
- dependency-name: eslint
  dependency-version: 10.0.1
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix: ESLint 10 CI lint failures (#161)

* Initial plan

* fix: update Node.js to 20 in CI, add @eslint/js dep, fix no-useless-assignment error

Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>

* fix: update ESLint scanning workflow to use project's ESLint 10 (#162)

* Initial plan

* fix: update ESLint scanning workflow to use project's ESLint 10

Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: HollowMan6 <43995067+HollowMan6@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants