Skip to content

Reduce disk churn for ESLint upgrades #14098

@TimvdLippe

Description

@TimvdLippe

The version of ESLint you are using.
7.19.0 and earlier upgrades to, for example, 7.13.0

The problem you want to solve.
ESLint upgrades cause significant file changes in node_modules. We have hit this problem multiple times, some statistics:

  • 7.14.0 -> 7.19.0 (5 minor versions)
3796 files changed, 162528 insertions(+), 5876 deletions(-)

https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2692306

  • 6.8.0 -> 7.13.0 (1 major version, 13 minor versions)
8913 files changed, 125261 insertions (+), 241831 deletions (-)

https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2534873

  • 6.0.1 -> 6.8.0 (7 minor versions)
634 files changed, 47325 insertions (+), 9376 deletions (-)

https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2137384

As an effect of these ESLint upgrades, checking out repositories becomes a lot slower and disk churn increases significantly for all contributors and bots.

Please note that we are required to check in our node_modules for security and stability reasons. We are not allowed to make calls to external repositories in our testing infrastructure, which means we have to include the files in our repository. That said, even if you wouldn't check in your files, the effects on files changed and disk operations remain. E.g. if you gitignore your node_modules, ESLint upgrades would still cause significant disk churn.

Your take on the correct solution to problem.
Reduce the disk churn either by dropping dependencies that cause excessive disk usage and drop dependencies that are commonly duplicated in node_modules trees. For example, in nearly all of our upgrades, we are observing multiple copies of lodash in among others @eslint/eslintrc or AST-like packages like es-abstract.

Are you willing to submit a pull request to implement this change?
I don't think this is something I can do as an external contributor, but feel free to led me/the community know if there are dependencies that could be pruned and usages can be migrated to reduce overall disk usage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    StaleacceptedThere is consensus among the team that this change meets the criteria for inclusionarchived due to ageThis issue has been archived; please open a new issue for any further discussioncoreRelates to ESLint's core APIs and featuresenhancementThis change enhances an existing feature of ESLint

    Type

    No type

    Projects

    Status

    Complete

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions