-
-
Notifications
You must be signed in to change notification settings - Fork 15.4k
haskellPackages.update-nix-fetchgit fixes #102997
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.update-nix-fetchgit fixes #102997
Conversation
I also think that this is a pretty motivating example for #100732 |
8db9533
to
b6ec634
Compare
This is ready to go now that 0.2.3 is in haskell-updates |
If I add myself to pkgs/development/haskell-modules/configuration-hackage2nix.yaml as a maintainer for this package will that work considering that @sorki is already a maintainer? |
b6ec634
to
fee272a
Compare
fee272a
to
1333ab8
Compare
I would prefer if we avoid use of allowInconsistentDependencies in Nixpkgs at all costs. This "feature" is a dangerous hack that's very likely to produce broken binaries. |
Ah, I assumed it would fail at compile time.
Might be sufficient to disable tests instead.
I initially wrote it without allow inconsistent, but it was 3 or 4 extra
lines of overrides in overrides.
…On Sat, Nov 7, 2020, 12:03 AM Peter Simons ***@***.***> wrote:
I would prefer if we avoid use of allowInconsistentDependencies in Nixpkgs
at all costs. This "feature" is a dangerous hack that's very likely to
produce broken binaries.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#102997 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGRJXBBNFDSFGM6GB746FTSOQM6DANCNFSM4TMJKIOA>
.
|
a7d0cd6
to
d1e684c
Compare
1333ab8
to
7ed7a4e
Compare
@peti I have removed the use of |
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.
Looks pretty good other than the overrideScope
thing.
tasty-hunit = self.tasty-hunit.override { inherit tasty; }; | ||
}; | ||
}) (drv: { | ||
buildTools = drv.buildTools or [ ] ++ deps ++ [ pkgs.makeWrapper ]; |
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.
Is this correct? Does update-nix-fetchgit
really need git
and nix
as a buildtool?
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.
They're used for the tests. A fake git repo and nix store are created to test updating expressions based on the result of nix-prefetch-git
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.
They're used for the tests.
In that case, I imagine they should probably go in testToolDepends
?
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.
Ah of course, thanks. I've added this now, along with addTestToolDepends
to lib.nix
8715e0a
to
aad8e23
Compare
Fix versions of dependencies Generate shell completions Wrap executable so that required executables are in PATH Make sure necessary executables for tests are present during build
aad8e23
to
cb08206
Compare
addTestToolDepend = drv: x: addTestToolDepends drv [x]; | ||
addTestToolDepends = drv: xs: overrideCabal drv (drv: { testToolDepends = (drv.testToolDepends or []) ++ xs; }); |
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.
Great, thanks for adding this :-)
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.
It not being there was the reason I didn't use it!
Looks good, and this builds on my machine. Thanks! |
Thanks! |
Motivation for this change
Necessary fixes for update-nix-fetchgit (a very useful tool for nix dev I think, https://asciinema.org/a/fJesaOF7jGKjYcLtUCsOqrZX6 !)
This was written against update-nix-fetchgit 0.2.3 which has yet to make it onto the haskell-updates branch (should happen next time the versions are bumped though).
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)