Skip to content

chore(flake): add nodejs to the dev shell - #440

Merged
noahpro99 merged 1 commit into
mainfrom
chore/flake-nodejs
Sep 23, 2026
Merged

noahpro99 merged 1 commit into
mainfrom
chore/flake-nodejs

Conversation

@noahpro99

Copy link
Copy Markdown
Contributor

prisma generate and uv run pyright . both fail inside nix develop on NixOS because neither tool can find a node binary.

The Python prisma package ships no CLI and no engines — prisma/cli/prisma.py npm-installs prisma@5.17.0 into ~/.cache/prisma-python/binaries/ and runs that JS CLI with node. nodePackages.prisma in the shell doesn't help: prisma-client-py insists on its own npm-pinned version. Without node on PATH it falls back to nodeenv, which then 404s fetching prisma engines for linux-nixos.

The engines were never the problem — the shellHook's PRISMA_*_BINARY exports already cover those. Only the interpreter was missing.

Verified inside nix develop with this change:

  • node v20.19.1
  • prisma generate ✔ Generated Prisma Client Python
  • uv run pyright . → 0 errors
  • uv run ruff check . → all checks passed
  • uv run black --check . → 16 files unchanged
  • uv run python generate_openapi.py ✓

So the README's check suite now runs natively in the dev shell.

I left uv and bun out deliberately: nixpkgs 24.11 ships an older uv that may not read the current uv.lock format, and a shell input would shadow a newer system uv.

prisma-client-py and pyright both shell out to node. Without it on PATH
they fall back to nodeenv, which can't fetch prisma engines for
linux-nixos, so 'prisma generate' and 'uv run pyright .' fail inside the
dev shell. With nodejs present, the shellHook's PRISMA_*_BINARY vars
supply the engines and the README check suite runs as documented.
@noahpro99
noahpro99 merged commit 44674c5 into main Sep 23, 2026
1 check passed
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

Successfully merging this pull request may close these issues.

1 participant