Skip to content
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

[7.17] Upgrade ESLint to v8 (#162309) #163792

Draft
wants to merge 9 commits into
base: 7.17
Choose a base branch
from

Conversation

watson
Copy link
Contributor

@watson watson commented Aug 14, 2023

This is a manual backport of "Upgrade ESLint to v8" (PR #162309). To avoid conflicts, this PR also backports the following 3 commits from main:

Updated direct dependencies

Package From To Changes
@types/eslint 7.28.0 8.44.2
eslint 7.32.0 8.46.0 CHANGELOG.md
eslint-config-prettier 7.2.0 9.0.0 CHANGELOG.md
eslint-import-resolver-node 0.3.6 0.3.9 CHANGELOG.md
eslint-import-resolver-webpack 0.13.2 0.13.4 CHANGELOG.md
eslint-module-utils 2.6.2 2.8.0 CHANGELOG.md
eslint-plugin-ban 1.5.2 1.6.0 diff
eslint-plugin-cypress 2.12.1 2.14.0 Release notes
eslint-plugin-import 2.24.2 2.28.0 CHANGELOG.md
eslint-plugin-jsx-a11y 6.4.1 6.7.1 CHANGELOG.md
eslint-plugin-mocha 10.0.3 10.1.0 CHANGELOG.md
eslint-plugin-no-unsanitized 3.1.5 4.0.2 diff

Note to reviewers

The vast majority of files touched by this PR is changes to the import order due to minor fixes in the import/order rule.

In reality there are so many differences between main and 7.17, that the commit for "Upgrade ESLint to v8" couldn't easily be backported. It was quicker to copy over what made sense manually, and recreate the rest. The main changes are (besides the 3 commits above), in the following separate commits in this PR for easier reviewing:

@watson watson added release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting labels Aug 14, 2023
@watson watson self-assigned this Aug 14, 2023
@watson watson changed the title [precommit] stop failing on warnings [7.17] Upgrade eslint to v8 (#162309) Aug 14, 2023
Comment on lines -1681 to -1682
...require('eslint-config-prettier/react').rules,
...require('eslint-config-prettier/@typescript-eslint').rules,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

These two rule-sets are now included in the base rule-set, so no need to manually require them anymore

@@ -6,7 +6,7 @@
const semver = require('semver');
const { kibanaPackageJson: PKG } = require('@kbn/dev-utils');

const eslintConfigPrettierTypescriptEslintRules = require('eslint-config-prettier/@typescript-eslint').rules;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The @typescript-eslint rule-set is now included in the base rule-set

@watson watson added backport and removed release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting labels Aug 14, 2023
@watson watson changed the title [7.17] Upgrade eslint to v8 (#162309) [7.17] Upgrade ESLint to v8 (#162309) Aug 14, 2023
@watson watson mentioned this pull request Aug 14, 2023
@kibana-ci
Copy link
Collaborator

kibana-ci commented Aug 14, 2023

💔 Build Failed

Failed CI Steps

Test Failures

  • [job] [logs] OSS Accessibility Tests / a11y tests using flights sample data Dashboard dashboard
  • [job] [logs] OSS Accessibility Tests / a11y tests using flights sample data Dashboard dashboard
  • [job] [logs] Default Accessibility Tests / Kibana overview Kibana overview
  • [job] [logs] Default Accessibility Tests / Kibana overview Kibana overview

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
maps 744 743 -1
securitySolution 2568 2509 -59
total -60

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
apm 2.4MB 2.4MB +13.0B
dashboard 181.5KB 181.5KB +7.0B
maps 2.6MB 2.6MB -85.0B
mapsEms 180.4KB 180.4KB +20.0B
ml 3.3MB 3.3MB +13.0B
monitoring 454.2KB 454.2KB +13.0B
osquery 948.7KB 948.7KB +20.0B
security 518.1KB 518.1KB +38.0B
securitySolution 4.7MB 4.6MB -42.2KB
snapshotRestore 259.3KB 259.3KB +13.0B
spaces 166.4KB 166.5KB +40.0B
visTypeVega 1.7MB 1.7MB +20.0B
total -42.1KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
dashboard 169.2KB 169.2KB +13.0B
fleet 108.8KB 108.8KB +13.0B
indexManagement 37.0KB 37.0KB +13.0B
kibanaUtils 68.4KB 68.4KB +13.0B
spaces 20.2KB 20.2KB +6.0B
telemetry 25.2KB 25.2KB +13.0B
upgradeAssistant 19.8KB 19.8KB +13.0B
total +84.0B

History

  • 💔 Build #150003 failed afa11796d20f77c6c3058858b1670bddc1cb703f

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @watson

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants