Is there an existing issue for this?
false
This is a CLI Docs Enhancement, not another kind of Docs Enhancement.
false
Description of Problem
The packument (package document) fetched during npm install is currently always the full/raw packument, not the minimized "corgi" version. Slack thread investigation shows that while gzip is used for audit endpoint responses, it is not consistently used for packument fetching. This means large packuments (e.g., for playwright) transfer similar data sizes whether raw or corgi, if gzipped. Currently, however, packument responses are typically uncompressed and only the full packument is used. This may lead to unnecessary data transfer, especially on large packages. The lack of gzip and not using the minimized corgi representation are both opportunities for improved efficiency.
Potential Solution
Either:
- Fix usage so npm install uses the minimized corgi packument (doc.min.json where appropriate), or
- Enable gzipping of packument fetch responses (by setting the right Accept-Encoding/request headers, and doc/unpacking correctly), as is done with audit endpoints.
Slack thread details the current evidence and code path for full packuments and gzip (see npm-registry-fetch and minipass-fetch layers for gzip handling). Either approach would reduce transfer size and could be a quick efficiency improvement for large packages.
Docs URL
#7126 ,
View original Slack conversation
Is there an existing issue for this?
false
This is a CLI Docs Enhancement, not another kind of Docs Enhancement.
false
Description of Problem
The packument (package document) fetched during npm install is currently always the full/raw packument, not the minimized "corgi" version. Slack thread investigation shows that while gzip is used for audit endpoint responses, it is not consistently used for packument fetching. This means large packuments (e.g., for playwright) transfer similar data sizes whether raw or corgi, if gzipped. Currently, however, packument responses are typically uncompressed and only the full packument is used. This may lead to unnecessary data transfer, especially on large packages. The lack of gzip and not using the minimized corgi representation are both opportunities for improved efficiency.
Potential Solution
Either:
Slack thread details the current evidence and code path for full packuments and gzip (see npm-registry-fetch and minipass-fetch layers for gzip handling). Either approach would reduce transfer size and could be a quick efficiency improvement for large packages.
Docs URL
#7126 ,
cli/workspaces/arborist/lib/arborist/build-ideal-tree.js
Line 1217 in d1ee8a5
View original Slack conversation