Skip to content
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

ReferenceError: primordials is not defined #59

Open
sagunji opened this issue Mar 11, 2021 · 4 comments
Open

ReferenceError: primordials is not defined #59

sagunji opened this issue Mar 11, 2021 · 4 comments

Comments

@sagunji
Copy link

sagunji commented Mar 11, 2021

After installing the package, I tried running the command parker spinner.css but I got a reference error. Here is the full message:

fs.js:35
} = primordials;
    ^

ReferenceError: primordials is not defined
    at fs.js:35:5
    at req_ (C:\Users\DELL\AppData\Roaming\nvm\v12.16.1\node_modules\parker\node_modules\natives\index.js:143:24)
    at Object.req [as require] (C:\Users\DELL\AppData\Roaming\nvm\v12.16.1\node_modules\parker\node_modules\natives\index.js:55
:10)
    at Object.<anonymous> (C:\Users\DELL\AppData\Roaming\nvm\v12.16.1\node_modules\parker\node_modules\graceful-fs\fs.js:1:37) 
    at Module._compile (internal/modules/cjs/loader.js:1158:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10)
    at Module.load (internal/modules/cjs/loader.js:1002:32)
    at Function.Module._load (internal/modules/cjs/loader.js:901:14)
    at Module.require (internal/modules/cjs/loader.js:1044:19)
    at require (internal/modules/cjs/helpers.js:77:18)

I have:
node v12.16.1
npm 6.13.4

@ssteigen
Copy link

I'm also having this issue.

@sedimentation-fault
Copy link

Me too has this issue. node.js v.14.17.6.

fs.js:45
} = primordials;
    ^

ReferenceError: primordials is not defined
    at fs.js:45:5
    at req_ (/usr/lib64/node_modules/parker/node_modules/natives/index.js:143:24)
    at Object.req [as require] (/usr/lib64/node_modules/parker/node_modules/natives/index.js:55:10)
    at Object.<anonymous> (/usr/lib64/node_modules/parker/node_modules/graceful-fs/fs.js:1:37)
    at Module._compile (internal/modules/cjs/loader.js:1072:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1101:10)
    at Module.load (internal/modules/cjs/loader.js:937:32)
    at Function.Module._load (internal/modules/cjs/loader.js:778:12)
    at Module.require (internal/modules/cjs/loader.js:961:19)
    at require (internal/modules/cjs/helpers.js:92:18)

@sedimentation-fault
Copy link

sedimentation-fault commented Oct 14, 2023

Now I see in /usr/lib64/node_modules/parker/node_modules/graceful-fs/package.json

"version": "3.0.12"

and remember the innocent-looking warning I got from node.js upon installation:

npm install -g parker
npm WARN deprecated [email protected]: This module relies on Node.js's internals and will break at some point. Do not use it, and update to [email protected].
...

But why didn't node.js do this itself? What is the purpose of offloading dependency tracking to some tool, only to have to track individual version dependencies manually afterwards? I don't get it...

@sedimentation-fault
Copy link

Solution

Since the author did not yet accept the pull request of @dsiddy above, we have to take matters in our own hands... 😒

Step 1: Upgrade graceful-fs

npm install -g graceful-fs
+ [email protected]
added 1 package in 0.349s

Step 2: Rename parker's own old graceful-fs version

mv /usr/lib64/node_modules/parker/node_modules/graceful-fs /usr/lib64/node_modules/parker/node_modules/graceful-fs-3.0.2-deprecated

Step 3: Be happy

😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants