NixOS Support
The bundled node fails to run on NixOS:
Could not start dynamically linked executable: /home/znd4/Projects/far.ai-interview/.direnv/python-3.11/lib/python3.11/site-packages/nodejs/bin/node
NixOS cannot run dynamically linked executables intended for generic\nlinux environments out of the box. For more information, see:
https://nix.dev/permalink/stub-ld
I'd understand closing this issue, but I thought I'd at least leave some breadcrumbs for future me / anyone else who wants to take a crack at packaging this really cool looking project for Nix:
- one of dream2nix's node packaging modules might be useful
- something simpler might work though :shrug:
Unfortunately, my node experience is pretty thin, so this might be tricky
can you please check if #323 fixes this?
pip install git+https://github.com/DetachHead/basedpyright@fa71759782c1d3b97eae50504711d670739208d7
(note that it will probably take several minutes to install due to #335)
By now I'm using https://github.com/leiserfg/leiserfg-overlay/blob/master/pkgs/basedpyright/default.nix
so that just patches it to use a different node binary. i don't know anything about nix but is it a problem with the node binary we're using that can be raised upstream at https://github.com/njzjz/nodejs-wheel?
In nixos libraries are not stored in the same path, so to make the regular node work I will need to patch the binary. That is doable but at that point I better replace it (as I did), which brings the plus of avoiding having another nodejs instead.
do you think that's a decent solution? we can add a "nixOS" section in the installation instructions that says to install it from your repo
I could add a flake to your repo if you like so, but it will have to be in the weekend.
sounds good, thanks
FWIW I have an open PR to bring basedpyright into nixpkgs based on the pyright package. nixos/nixpkgs#308503
@DetachHead then it's better to wait for the work from @kiike to be merged.
FYI, my PR, which brings basedpyright into NixOS, was merged four days ago. I guess it is already in the nixos-unstable repo, but probably won't have made it in time for the 24.05 release.
thanks! if you don't mind would you like to also write some installation instructions for nixOS?