-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GetRequiredPlugins
may hang if CWD contains large numbers of files or has circularities
#2928
Comments
Symlinks aside (and that's something we should look into), I do wonder if instead of crawling every folder from the root, we should instead just look for a top level |
I am not sure if this is related, but I get it to hang on:
You can reproduce this by running: EDIT: Turns out its not reproducible, without some of my uncommitted local files after all. curl https://install.meteor.com/ | sh
meteor create --minimal mymeteor-app
cd mymeteor-app
meteor npm install @empirica/meteor-deploy
npx meteor-deploy init Then: pulumi stack select Then: npx meteor-deploy stack configure aws-ecs-ec2 --instanceType t2.medium
pulumi up --logtostderr -v=9 |
It would be great if there at least was some explicit control of which plugins are to be installed. This implicit GetRequiredPlugins that does some very opinionated parsing of package.json files and directory structures only works on two assumptions:
So I am favour of simplifying it and remove this routine that is always going to be error-prone. I have lost many hours trying to find the issue for this. It might not be a frequent issue, but when it does strike, it is severe in the sense that it is quite hard to troubleshoot. It would be much nicer to just explictly list the needed plugins in the Pulumi.yaml. It would also be much faster. |
I just got bit by this. I had an odd setup like this: tree -F -P 'package.json' -L 3
./
├── package.json
├── projects/
│ ├── my_project/
│ │ ├── node_modules/
│ │ ├── package.json
└─── node_modules/ In the root In the project When I run
I’m not much of an expert with npm so maybe I’m doing something wrong here, but whatever it is, if I’ve done it, then it’s likely that someone else will, at some point. So it’d be good if |
When using the Node SDK, this call crawls the CWD looking for
node_modules
folders to find required plugins and SxS versions of@pulumi/pulumi
. If the number of files rooted at the CWD is significant, this can cause the call to hang (potentially indefinitely if there are circularities in symlinks).The text was updated successfully, but these errors were encountered: