Closed matsumonkie closed 3 years ago
The failing build can be found here if it helps to reproduce
I believe the issue comes from https://github.com/nh2/static-haskell-nix/blob/master/static-stack2nix-builder/stack2nix-script.nix#L88 I'm a beginner at nix though, so not quite sure :-S
So I've been investigating a little bit more and it turns out that the issue comes from stack2nix :-( I'll close this issue!
You don't need to close the issue because it's with stack2nix
, because I essentially maintain that too.
What you see seems to be this: https://stackoverflow.com/questions/57516944/stack-new-command-failing-to-download-build-plan-for-lts-14-1
But it doesn't tell what the actual problem is. Newer stack
seems to fix it, but it may not be easy to upgrade stack2nix to use a newer Stack immediately.
So it would be good to know if indeed we could fix it in stack2nix
by removing double slashes, if that is the problem.
I think I found it:
https://github.com/commercialhaskell/lts-haskell/issues/247#issuecomment-608669620
leading via https://github.com/commercialhaskell/stack/issues/5204#issuecomment-591354784 to https://www.stackage.org/blog/2020/02/discontinuing-legacy-snapshots:
you will not be able to use Stack 1.9 or earlier with newer nightly or LTS 15 snapshots
This means we need to upgrade stack2nix
to work with Stack 2 (currently it depends on Stack 1.9).
Or alternatively switch from stack2nix
to haskell.nix
, if it works well enough.
Both are no trivial tasks though.
Yeah, it seems indeed quite hard :-( I've kind of given up trying to make it work with stack2nix and am actually trying to use the same technique postgres. Not completely sure how great it is since my nix knowledge is still quite low though ? (would love your opinion whether postgres' solution is right or not!)
Good luck in trying to fix stack2nix
for newer version!
This was fixed with PR #98, with commit 66fce684a20451514cb68d71bcb62fb246cb2080, which updates stack2nix
to a version with Stack2 support.
Hello! First things first, thanks a lot for this work, it might help me a lot.
I'm trying to build a static binary from a stack project based. My project is using stack lts-15.13 with gh883. When I try to build the adapted default.nix, stack2nix fails with a 404:
It seems the issue comes from
path = "/fpco/lts-haskell/master//lts-15.13.yaml"
and the double slash. So my question is, islts-15.13
supported ?