-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Error: No valid exports main found for '\node_modules\uuid' #2090
Comments
Hi @Bruxo00, Would you mind including the code snippet which is failing? Just confirming, have you already installed googleapis before running the code sample? Would you also mind trying running rm |
Hi @sofisl, thanks for the tips. I had already tried that, reinstalled everything multiple times. In my case, the steps to reproduce the issue are:
Then I import googleapis on my file
Run the file
And it throws the error. |
Ok, just tried the same steps on my Linux machine and it works... Don't know if this is a specific problem of my computer or if it doesn't work in every Windows machine... Gonna try in my laptop that also has Windows installed and I'm gonna see if it does the same. Btw my Linux machine has:
|
Tried on my laptop and it worked. Updated NodeJS on this machine to v14.2.0 and now it's working fine. |
I can also reproduce this bug, with a slightly different error message, but the stack is otherwise the same.
Node v13.1.0 my index.js and package.json: const {google} = require('googleapis'); {
"name": "cruxapinode",
"main": "index.js",
"dependencies": {
"googleapis": "^52.1.0"
}
} node index.js |
Ah. uuid doesn't support node v13. uuidjs/uuid#466 (comment) works fine on node 14.4.0. sgtm. |
Environment details
googleapis
version: 50.0.0Steps to reproduce
const { google } = require('googleapis');
When trying to use the youtube upload sample, it throws this error:
The text was updated successfully, but these errors were encountered: