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

Prebuild binary missing for platform linux #3641

Open
1 task
Rom888 opened this issue Jun 4, 2024 · 1 comment
Open
1 task

Prebuild binary missing for platform linux #3641

Rom888 opened this issue Jun 4, 2024 · 1 comment
Labels
bug Something isn't working cdktf-cli priority/important-longterm Medium priority, to be worked on within the following 1-2 business quarters.

Comments

@Rom888
Copy link

Rom888 commented Jun 4, 2024

Expected Behavior

No error

Actual Behavior

pnpm add --global [email protected]

 WARN  6 deprecated subdependencies found: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Packages: +260
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Progress: resolved 1069, reused 1068, downloaded 0, added 0, done
.pnpm/@[email protected]/node_modules/@cdktf/node-.pnpm/@[email protected]/node_modules/@cdktf/node-pty-prebuilt-multiarch: Running install script, failed in 554ms
.../@cdktf/node-pty-prebuilt-multiarch install$ node scripts/check-prebuild.j…
│ Prebuild binary missing for platform linux
│ prebuild-install warn install No prebuilt binaries found (target=22.2.0 run…
│ node:events:498
│       throw er; // Unhandled 'error' event
│       ^
│ Error: spawn node-gyp ENOENT
│     at ChildProcess._handle.onexit (node:internal/child_process:286:19)
│     at onErrorNT (node:internal/child_process:484:16)
│     at process.processTicksAndRejections (node:internal/process/task_queues…
│ Emitted 'error' event on ChildProcess instance at:
│     at ChildProcess._handle.onexit (node:internal/child_process:292:12)
│     at onErrorNT (node:internal/child_process:484:16)
│     at process.processTicksAndRejections (node:internal/process/task_queues…
│   errno: -2,
│   code: 'ENOENT',
│   syscall: 'spawn node-gyp',
│   path: 'node-gyp',
│   spawnargs: [ 'rebuild' ]
│ }
│ Node.js v22.2.0
└─ Failed in 554ms at /home/rom/.local/share/pnpm/global/5/.pnpm/@[email protected]/node_modules/@cdktf/node-pty-prebuilt-multiarch
 ELIFECYCLE  Command failed with exit code 1.

Steps to Reproduce

pnpm add --global [email protected]

Versions

language: typescript
cdktf-cli: 0.20.7
node: 22.2.0
terraform: 1.8.4
arch: amd64
os: ubuntu 23.10

Providers

No response

Gist

No response

Possible Solutions

No response

Workarounds

No response

Anything Else?

No response

References

No response

Help Wanted

  • I'm interested in contributing a fix myself

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
@Rom888 Rom888 added bug Something isn't working new Un-triaged issue labels Jun 4, 2024
@ansgarm
Copy link
Member

ansgarm commented Jun 10, 2024

Hi @Rom888 👋

Thank you for raising this. It seems like you are using Node.js v22, for which we don't have prebuild bindings at this time at all in the cdktf/node-pty-prebuilt-multiarch library. The simplest fix would be to use Node.js v20 for the CDKTF CLI.

That said, the package should build the binaries during post-install as a fallback but it seems like pnpm didn't run the postinstall script? We don't officially support pnpm at this time, so you might need to adjust some settings for it or use npm to install the CDKTF CLI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cdktf-cli priority/important-longterm Medium priority, to be worked on within the following 1-2 business quarters.
Projects
None yet
Development

No branches or pull requests

2 participants