matplotlib-haskell icon indicating copy to clipboard operation
matplotlib-haskell copied to clipboard

nix module not loading python correctly

Open patrickaldis opened this issue 2 years ago • 1 comments

currently have a file script.hs containing only the following:

#!/usr/bin/env nix-shell
#!nix-shell --pure -i runghc -p "haskellPackages.ghcWithPackages (pkgs: [ pkgs.matplotlib])"

import Graphics.Matplotlib
main = onscreen $ contourF (\a b -> sin (a*pi/180.0) + cos (b*pi/180.0)) (-100) 100 (-200) 200 10

However, the only output I get is:

env: 'python3': No such file or directory

Maybe my undestanding of setting up a nix environment is wrong? Appreciate any help

patrickaldis avatar Dec 21 '22 23:12 patrickaldis

I can also add python3 with matplotlib, scipy manually - and this works!, by just adding another package to nix-shell. But I was under the impression this was what the nix-shell was for (#9)

patrickaldis avatar Dec 23 '22 09:12 patrickaldis