Skip to content

[BUG] In v9, installing from packages directly from Github via SSH is so much slower than before #7130

@andrew-paterson

Description

@andrew-paterson

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

After upgrading to NPM 9.8.1, installing a package from the NPM registry seems faster, but installing it from Github via SSH is way slower. For a single package, it went from 80s to 3 minutes. I've outlined the results of installing a single package (ember-changeset) both from the NPM registry and from Github, and in each case given the results for NPM 9.8.1 and 6.14.18.

The pattern is consistent. Since upgrading to npm 9, bigger applications that have multiple Github-hosted packages have gone from taking close to 6 minutes for an install to about 26 minutes.

Is there anything that I can do to improve this?

From the NPM registry

"devDependencies": { "ember-changeset": "4.1.2" }

(NPM 6.14.18, Node 14.21.3) => added 704 packages from 333 contributors and audited 704 packages in 28.717s

(NPM 9.8.1, Node 18.18.0) => added 566 packages, and audited 777 packages in 8s

Directly from Github via SSH

"devDependencies": { "ember-changeset": "git+ssh://[email protected]:poteto/ember-changeset.git#4528b9ce580e85fdb3d032b52546be73d184b73c" }

(NPM 6.14.18, Node 14.21.3) => added 704 packages from 333 contributors and audited 704 packages in 79.362s

(NPM 9.8.1, Node 18.18.0) => added 566 packages, and audited 777 packages in 3m

Environment

  • npm: 9.8.1
  • Node.js: 18.18.0
  • OS Name: Ubuntu 22
  • System Model Name: MSI

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bugthing that needs fixingNeeds Triageneeds review for next stepsRelease 9.xwork is associated with a specific npm 9 release

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions