To enter a shell with python 3 + funcy, I do:
nix-shell -p 'python3.withPackages(ps:[ps.funcy])'
What would be the equivalent in modern nix? None of these work:
➤ nix shell nixpkgs --expr 'python3.withPackages(ps: [ps.funcy])'
error: undefined variable 'python3'
at «string»:1:1:
1| python3.withPackages(ps: [ps.funcy])
| ^
➤ nix shell -f '<nixpkgs>' --expr 'python3.withPackages(ps: [ps.funcy])'
error: '--file' and '--expr' are exclusive
Try 'nix --help' for more information.
➤ nix shell 'nixpkgs#python3.withPackages(ps: [ps.funcy])'
error: 'nixpkgs#python3.withPackages(ps: [ps.funcy])' is not a valid URL