question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Excess RewritePackageJson trees observed

See original GitHub issue

When building a large app, with many nested addons we have observed excess RewritePackageJSON tree’s.

Observed in the wild, rather than 9,933 broccoli nodes, we see in excess of 87,000 nodes.

This appears to severely impact build performance.

I believe, the fix may be that v2Trees creation of it’s new RewritePackageJson to go through throughTreeCache if possible.

It may also be the case, that the entire result of v2Tree should in some circumstances go through the cache as well.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:12 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
tmquinncommented, Jul 30, 2019

Starting on this…

1reaction
ef4commented, Jul 25, 2019

Sigh. Yes, ember-cli’s super-linear build costs as the number of addons grows strikes again.

I know @stefanpenner knows this already, but for interested readers: ember-cli doesn’t just build each addon, it builds each addon for each time that addon is consumed by another package (meaning the app or another addon). This causes build costs to grow super-linearly as you add more addons and they depend on each other. Embroider’s compat layer faithfully reproduces this expensive behavior because it has to. Whereas our new V2-formatted addons skip all that and build costs grow linearly in the number of addons, rather than super-linearly.

I agree, we can run the whole v2Tree through throughTreeCache, making a new embroider-specific category for it that won’t collide with any existing category.

This would be a good PR for you or someone on your team, because you should be able to see an immediate performance impact in that giant app.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Problem with package.json? · Issue #2524 - GitHub
Steps to reproduce: Run NPM install from path that package.json is located. Expected behavior: Everything should install smoothly. Observed ...
Read more >
But what the hell is package-lock.json?
In projectclone1 I have same package.json and package-lock.json as the original project (which means I did not change anything manually) and ...
Read more >
npm - NPM5, What is the difference of package-lock.json with ...
Describe a single representation of a dependency tree such that teammates, deployments, and continuous integration are guaranteed to install ...
Read more >
How to Upgrade Dependencies in Your package.json
The Powerful Solution. As we have observed, npm update will not upgrade to the latest major version. It makes sense since major releases...
Read more >
Modules: Packages | Node.js v19.3.0 Documentation
A package is a folder tree described by a package.json file. The package consists of the folder containing the package.json file and all...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found