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

yarn install throw error because oxide-node-api-shim a non-existing file #10534

Closed
alaadahmed opened this issue Feb 8, 2023 · 22 comments
Closed

Comments

@alaadahmed
Copy link

alaadahmed commented Feb 8, 2023

Maintainer's note: This issue has been fixed in v3.2.6.


Tailwind: v3.2.5
Node: v19.6.0
Yarn: v1.22.19

When trying to install new Tailwind version 3.2.5 using Yarn, I get that error:
error Package "" refers to a non-existing file '"/Users/akoraie/MyApp/assets/oxide-node-api-shim"'.

@brydonm
Copy link

brydonm commented Feb 8, 2023

+1 to this

error Package "" refers to a non-existing file '"/home/runner/work/.../oxide-node-api-shim"'.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
Error: Process completed with exit code 1.

@anarkrypto
Copy link

Here is the error: https://github.com/tailwindlabs/tailwindcss/blob/master/package-lock.stable.json#L12

A relative path for development was submitted in the production code @RobinMalfait

@RobinMalfait
Copy link
Member

@anarkrypto that's not for development, that was intentionally and npm is fine with it. But yarn and pnpm are not happy about it.

I'm looking into this!

@JoaoOtavioS

This comment was marked as off-topic.

@beingmerry
Copy link

beingmerry commented Feb 8, 2023

Workaround for newbies like me:
pnpm install -D [email protected]
then modify version in package.json to have the ^ operator:
..., "tailwindcss": "^3.2.4", ...

Edit: looks like updating to npm latest (9.4.2) will also fix the issue:
npm install -g npm@latest

@irunatbullets
Copy link

irunatbullets commented Feb 8, 2023

@anarkrypto that's not for development, that was intentionally and npm is fine with it. But yarn and pnpm are not happy about it.

I'm looking into this!

I'm using npm 9.3.1 and am getting the same error as above.

Edit: updated to npm 9.4.2 and it works.

@IvandeWolf
Copy link

IvandeWolf commented Feb 8, 2023

Also got the same error but updating npm (running npm install -g npm@latest) fixed it for me.

So I updated to npm version 9.4.2

@eswat2

This comment was marked as off-topic.

@NGrPXL

This comment was marked as off-topic.

@isaniomoraes

This comment was marked as off-topic.

@eswat2

This comment was marked as off-topic.

@woubuc
Copy link

woubuc commented Feb 8, 2023

Same issue with pnpm. Updating to latest pnpm version didn't fix it. Pinned tailwindcss to the previous version (3.2.4) in package.json for now.

Specific pnpm error message:

ERR_PNPM_LINKED_PKG_DIR_NOT_FOUND  Could not install from "[project dir]\oxide-node-api-shim" as it does not exist.

@crswll
Copy link

crswll commented Feb 8, 2023

A fix is coming just relax.

@adamwathan
Copy link
Member

We're aware of and acknowledge the problem folks, no need to reply with any "yep broken for me too" stuff. Yes it's broken, we know 😅

New release will be out any minute but like any other package you can always install the last working version by specifying the version number:

npm install -D [email protected]

@fwilliamconceicao
Copy link

In my case, this isn't happening to yarn, it's on NPM in a code build on an AWS instance. On my localhost works fine.

If it'll help you out, here's the stack trace:



[Container] 2023/02/08 16:45:24 Waiting for agent ping
--
2 | [Container] 2023/02/08 16:45:25 Waiting for DOWNLOAD_SOURCE
3 | [Container] 2023/02/08 16:45:27 Phase is DOWNLOAD_SOURCE
4 | [Container] 2023/02/08 16:45:27 CODEBUILD_SRC_DIR=/codebuild/output/src862329067/src
5 | [Container] 2023/02/08 16:45:27 YAML location is /codebuild/readonly/buildspec.yml
6 | [Container] 2023/02/08 16:45:27 Setting HTTP client timeout to higher timeout for S3 source
7 | [Container] 2023/02/08 16:45:27 Processing environment variables
8 | [Container] 2023/02/08 16:45:27 No runtime version selected in buildspec.
9 | [Container] 2023/02/08 16:45:29 Moving to directory /codebuild/output/src862329067/src
10 | [Container] 2023/02/08 16:45:29 Configuring ssm agent with target id: codebuild:5e44c94d-3258-46da-b037-e976c26e5641
11 | [Container] 2023/02/08 16:45:29 Successfully updated ssm agent configuration
12 | [Container] 2023/02/08 16:45:29 Registering with agent
13 | [Container] 2023/02/08 16:45:29 Phases found in YAML: 2
14 | [Container] 2023/02/08 16:45:29  PRE_BUILD: 1 commands
15 | [Container] 2023/02/08 16:45:29  BUILD: 1 commands
16 | [Container] 2023/02/08 16:45:29 Phase complete: DOWNLOAD_SOURCE State: SUCCEEDED
17 | [Container] 2023/02/08 16:45:29 Phase context status code:  Message:
18 | [Container] 2023/02/08 16:45:29 Entering phase INSTALL
19 | [Container] 2023/02/08 16:45:29 Phase complete: INSTALL State: SUCCEEDED
20 | [Container] 2023/02/08 16:45:29 Phase context status code:  Message:
21 | [Container] 2023/02/08 16:45:29 Entering phase PRE_BUILD
22 | [Container] 2023/02/08 16:45:29 Running command npm install
23 | npm WARN deprecated [email protected]: This SVGO version is no longer supported. Upgrade to v2.x.x.
24 | npm WARN deprecated [email protected]: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-terser
25 | npm WARN deprecated [email protected]: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
26 | npm WARN deprecated [email protected]: Please use @jridgewell/sourcemap-codec instead
27 | npm WARN deprecated [email protected]: Use your platform's native performance.now() and performance.timeOrigin.
28 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
29 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
30 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14.16"} (current: {"node":"12.22.12","npm":"6.14.16"})
31 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
32 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
33 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
34 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
35 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
36 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
37 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
38 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
39 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
40 | npm WARN notsup Unsupported engine for @jest/[email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
41 | npm WARN notsup Not compatible with your version of node/npm: @jest/[email protected]
42 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
43 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
44 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
45 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
46 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
47 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
48 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
49 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
50 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
51 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
52 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
53 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
54 | npm WARN notsup Unsupported engine for @jest/[email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
55 | npm WARN notsup Not compatible with your version of node/npm: @jest/[email protected]
56 | npm WARN notsup Unsupported engine for @jest/[email protected]: wanted: {"node":"^14.15.0 \|\| ^16.10.0 \|\| >=18.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
57 | npm WARN notsup Not compatible with your version of node/npm: @jest/[email protected]
58 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14.16"} (current: {"node":"12.22.12","npm":"6.14.16"})
59 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
60 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14.16"} (current: {"node":"12.22.12","npm":"6.14.16"})
61 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
62 | npm WARN notsup Unsupported engine for @rollup/[email protected]: wanted: {"node":">=14.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
63 | npm WARN notsup Not compatible with your version of node/npm: @rollup/[email protected]
64 | npm WARN notsup Unsupported engine for @rollup/[email protected]: wanted: {"node":">=14.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
65 | npm WARN notsup Not compatible with your version of node/npm: @rollup/[email protected]
66 | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.3.2 (node_modules/chokidar/node_modules/fsevents):
67 | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
68 | npm WARN notsup Unsupported engine for @remix-run/[email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
69 | npm WARN notsup Not compatible with your version of node/npm: @remix-run/[email protected]
70 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
71 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
72 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14.0.0"} (current: {"node":"12.22.12","npm":"6.14.16"})
73 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
74 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
75 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
76 | npm WARN notsup Unsupported engine for [email protected]: wanted: {"node":">=14"} (current: {"node":"12.22.12","npm":"6.14.16"})
77 | npm WARN notsup Not compatible with your version of node/npm: [email protected]
78 | npm WARN notsup Unsupported engine for @csstools/[email protected]: wanted: {"node":"^14 \|\| >=16"} (current: {"node":"12.22.12","npm":"6.14.16"})
79 | npm WARN notsup Not compatible with your version of node/npm: @csstools/[email protected]
80 | npm WARN notsup Unsupported engine for @csstools/[email protected]: wanted: {"node":"^14 \|\| ^16 \|\| >=18"} (current: {"node":"12.22.12","npm":"6.14.16"})
81 | npm WARN notsup Not compatible with your version of node/npm: @csstools/[email protected]
82 |  
83 | npm ERR! code ENOLOCAL
84 | npm ERR! Could not install from "node_modules/tailwindcss/oxide-node-api-shim" as it does not contain a package.json file.
85 |  
86 | npm ERR! A complete log of this run can be found in:
87 | npm ERR!     /root/.npm/_logs/2023-02-08T16_46_07_500Z-debug.log
88 |  
89 | [Container] 2023/02/08 16:46:07 Command did not exit successfully npm install exit status 1
90 | [Container] 2023/02/08 16:46:07 Phase complete: PRE_BUILD State: FAILED
91 | [Container] 2023/02/08 16:46:07 Phase context status code: COMMAND_EXECUTION_ERROR Message: Error while executing command: npm install. Reason: exit status 1


@RobinMalfait
Copy link
Member

A new version has just been released (3.2.6)!

Try it with your favorite tool:

  • npm install tailwindcss@latest
  • pnpm add tailwindcss@insiders
  • yarn add tailwindcss@insiders
  • ...

Let me know if more errors occur while installing.

@difhel
Copy link

difhel commented Feb 8, 2023

Really? I just want to run npx create-react-app --template typescript. It gives me that error. There is no information in the internet about this problem, and I dont need tailwindcss at all. But your bug affected common-use command at least for an hour.
There is no way to run this command using another version of tailwindcss (for ex. 3.2.4 where this problem dont occur).
Dont you want to test your releases before publishing to npm??

@adamwathan
Copy link
Member

Dont you want to test your releases before publishing to npm??

Of course! This one was tricky because the issue only appears when installing Tailwind from npm and specifically has to do with how yarn and pnpm try to resolve file: dependencies when installing. Couldn't have really known about the issue without publishing first. Fixed it as fast as we could.

@difhel
Copy link

difhel commented Feb 8, 2023

Okay. I'm sorry, I was too mad with you. It's very hard when you're new to NodeJS and encounter such problems at first steps. I'm not sure I can really understand what the problem is, but I believe that you fixed it asap. Thanks for answer!

@ioanabrooks
Copy link

@adamwathan Is it possible to mark tailwindcss as an optional dependency of CRA? See facebook/create-react-app#12046. That way CRA doesn't break in case of issues like this for users that don't need tailwind with their CRA :) ?

@adamwathan
Copy link
Member

@adamwathan Is it possible to mark tailwindcss as an optional dependency of CRA? See facebook/create-react-app#12046. That way CRA doesn't break in case of issues like this for users that don't need tailwind with their CRA :) ?

Hey! Better to ask the CRA team about that, I don’t have any ability to make changes there.

@fwilliamconceicao
Copy link

I confirm that is working fine now, at least here on my side with my localhost and my ECS instance on AWS.

Thank you.

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