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
haskellPackages.niv: Try to fix build #117023
Conversation
Who knows maybe I screwed up building … @GrahamcOfBorg build niv |
For me, it builds
I can imagine this is an issue with propagation where some dependency of |
Might be worth trying diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix
index 7d71b9e77a1..70f38b3e7f9 100644
--- a/pkgs/development/haskell-modules/configuration-common.nix
+++ b/pkgs/development/haskell-modules/configuration-common.nix
@@ -946,9 +946,9 @@ self: super: {
# Generate shell completion.
cabal2nix = generateOptparseApplicativeCompletion "cabal2nix" super.cabal2nix;
- niv = generateOptparseApplicativeCompletion "niv" (super.niv.override ({
- # Needs override because of: https://github.com/nmattia/niv/issues/312
- optparse-applicative = super.optparse-applicative_0_15_1_0;
+ niv = generateOptparseApplicativeCompletion "niv" (super.niv.overrideScope (self: super: {
+ # Needs override because of: https://github.com/nmattia/niv/issues/312
+ optparse-applicative = super.optparse-applicative_0_15_1_0;
}));
ormolu = generateOptparseApplicativeCompletion "ormolu" super.ormolu;
stack = generateOptparseApplicativeCompletion "stack" super.stack; |
Yeah, that makes sense. It’s just that I have never witnessed a problem like this before. Normally we get the error about incompatible versions it does not silently choose the "wrong" one. |
Normally Haskell packages have pretty strict PVP-based upper bounds which leads to the whole mess that we can often unbreak a build by jailbreaking, but |
Aaaaah, that makes so much sense. |
@maralorn niv builds successfully with this: https://github.com/sternenseemann/nixpkgs//commit/0eb47060901 |
Thank you! I had actually tried it with overrideScope, saw how many rebuilds it required and decided "this must be the wrong solution". |
You can get it from cachix (if you have it) to verify https://app.cachix.org/cache/tmp |
It would be great if you could wait for ofborg. |
@SuperSandro2000 I think waiting for ofborg makes sense in most cases. But ofBorg should enable devs and no be a burden. In this case two people had tested this very small PR. OfBorg had made checks before my final force push. |
Please keep in mind that ofborg uses more restricted rules to eval and what locally passes does not always need to pass ofborg. |
Motivation for this change
niv is broken on master right now (compare nmattia/niv#312).
I need help on this one! /cc @peti @sternenseemann @cdepillabout
I am trying to fix this by overriding the optparse-applicative version to something older.
This should be total routine and a 5 minute job, but I have now tried for at least 30 minutes, but no matter what I do my override does not have any effect. It always tries to build with optparse-applicative-0.16.1 not with 0.15.1.
What I have tried:
This is either something really stupid from my side or something really tricky in mkDerivation …
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)