-
-
Notifications
You must be signed in to change notification settings - Fork 15.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gns3: Fix python package not being pinned #77701
Conversation
Due to NixOS#44426 the correct psutils package is not picked up, this commit changes the code so the correct version is always picked.
Thank you :) I learnt a lot from your commit! :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @Alan01252 thanks for your PR :)
I've added an extra commit (will be squashed before merging) that tries to get rid of some redundancy (though not all of it, atm it would also make sense to move defaultOverrides
into default.nix
but I'm not sure if this will always be the case). I also took care of some minor style and copy&paste issues.
I've dropped the aiohttp
pinning as I couldn't reproduce any issues. Does your overlay also override aiohttp
or are you using a different channel? On the most recent nixos-unstable channel I currently get the expected version:
$ nix-build -A python3Packages.aiohttp
/nix/store/xw8zl3qcl8zha6wi7fns5rzmz2p1mqim-python3.7-aiohttp-3.6.2
I'm using stable and just had this as an override which is why I had to pin aiohttp, and copy that config over from the latest unstable to get it to build on my machine. Trying to upgrade just aiohttp package from unstable and get it working with this code warped my mind a little bit and I wasn't able to figure it out. |
@Alan01252 ok, I see. I suggest that we drop the As for your use-case: If you use channels you could try something like this in your NixOS configuration (untested but looks fine - source): { config, pkgs, ... }:
let
unstable = import <nixos-unstable> {};
in {
environment.systemPackages = [ unstable.packagehere ];
} Or if you use a local git checkout the following should work: { config, pkgs, ... }:
let
unstable = import /path/to/nixpkgs {};
in {
environment.systemPackages = [ unstable.packagehere ]; # Or maybe unstable.pkgs.packagehere
} Maybe also interesting (but most likely without the With nix-shell and nix-env this is possible as well (I can also post an example if you want). Hope this helps. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The current state LGTM, so I'll already merge it, but of course I'm still open to discussing additional changes, if you want to change something else (e.g. regarding the aiohttp
pining) ;)
Anyway, thanks for the PR :) The current pinning should now work as expected when using overlays.
No this is great thank you. The problem I was having is I wanted "stable" python but "unstable" aiohttp and that combination I just could not figure out. I should probably just move to unstable python. ` security.wrappers.gns3server = { security.wrappers.ubridge = { In my configuration to make this work |
Due to #44426 the correct psutils
package is not picked up, this commit changes the code so the correct
version is always picked
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)