Comments (8)
https://github.com/BeeeQueue/qnm-repro
If you install using npm it shows 700~ deps, and if you remove node_modules
and install using pnpm it shows 8
from qnm.
Thanks @BeeeQueue.
You are right. While I made qnm not crash on pnpm repositories, what it does is just list the top-level modules within the node_modules
.
pnpm works differently from npm/yarn in a way that it'll create links for every package, and it will place its own dependencies as its siblings
Today, qnm's algorithm is to run on a workspace and analyze it from top to bottom, it doesn't try to go "up" in the directory structure like Node's resolution algorithm does.
This is the reason you see only 8 dependencies when running qnm today.
qnm was created because, for years, package managers compromised on correctness for install size by hoisting packages, which created many problems that needed to be debugged. As I'm not a pnpm
user myself, it would be very interesting for me to know what kind of things pnpm
users need to debug, and what information they expect to get from qnm.
Once I'll understand the need, it would be possible to implement a solution for it.
from qnm.
It's an internal repo, unfortunately, and I can't promise that I'll remember to create a public repro 😄. But you're awesome for adding pnpm support so quickly!
from qnm.
Hey @borekb and thanks for opening this issue!
I've looked into this use case and added support for both yarn-3 with pnpm
linker, pnpm
and the case of circular symlinks.
on qnm version 2.10.0
Please let me know if it works for you
from qnm.
Wow that was fast!
I tried in our repo which uses Yarn workspaces and it failed after about 1 minute with this error:
FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory
I guess Yarn workspaces might be the problem. I don't really have a non-workspaces project I could test right now but still appreciate your super-fast reaction!
from qnm.
Hey @borekb, thanks for testing it!
Actually, qnm supports yarn workspaces, I'm not sure what is the issue 🤷♂️
I'd love to debug it though, so if you can find a repo that reproduces it be happy to debug it.
from qnm.
The pnpm support seems to only recognize the top-level dependencies from my testing of running qnm
in any repo using pnpm
from qnm.
@BeeeQueue can you create a repro and describe what do you expect to see in oppose to what qnm shows today? I believe it could help shape the output according to what's relevant for the use case
from qnm.
Related Issues (20)
- FR: Support for monorepos within subdirectory? HOT 15
- Dedupe the reasons for a module to be installed
- Use Ellipsis when there are more than 3 reasons for having a module HOT 1
- ENAMETOOLONG: name too long, scandir xxx HOT 1
- Bring back shell autocompletions HOT 1
- Should this work in Windows Anaconda? HOT 3
- What does count actually mean? HOT 3
- Option `--disable-colors` seems not to be working HOT 1
- fish completions command error HOT 1
- find version in node javascript HOT 1
- Recently changed dependencies HOT 5
- Add a way to include bundled dependencies HOT 5
- Mark a dependency with (resolutions) in case it's affected by yarn's resolutions
- Mark a dependency with (overrides) in case it's affected by npm's overrides
- Idea: Display nohoist indication for packages that affected by the nohoist configuration HOT 1
- Support parsing yarn 3 lock files
- Bug: qnm spawns check.js which eats CPU HOT 3
- Windows: Unable to use on scoped packages HOT 3
- Scoped packages should be displayed using `/` separator, regardless of OS HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qnm.