Open srgoni opened 1 month ago
Node is a prerequisite for CDKTF whichever language you are writing in, as stated in the docs.
Interesting. I assumed that the language-specific libraries were all 100% transpiled and didn't require pulling in another language ecosystem (which I'd like to avoid if possible).
It's clear that the cdktf
CLI tool requires Node, but I'm not using that.
Expected Behavior
When executing a cdktf stack script written in Python directly, it should run without requiring any dependencies besides the cdktf Python modules and precompiled providers.
Actual Behavior
The script fails with a
FileNotFoundError: [Errno 2] No such file or directory: 'node'
error, indicating that the Python modules will always try to spawn an external Node.js interpreter.Steps to Reproduce
Versions
language: Python 3.11 cdktf-cli: N/A node: N/A cdktf: 0.20.7 constructs: 10.3.0 jsii: 1.98.0 terraform: 1.5.7 arch: amd64 os: Debian trixie
Providers
N/A, problem occurs without any providers.
Gist
https://gist.github.com/srgoni/3f1882ad95b2587c41b1e85ac0c65809
Possible Solutions
No response
Workarounds
No response
Anything Else?
I believe that this scenario used to work with previous cdktf versions, but I don't have a reproducible setup at hand.
Full stack trace:
References
No response
Help Wanted
Community Note