nix-serve does not build on unstable, because of missing pkgs.nix.libs.nix-perl-bindings attribute #1007
Labels
No labels
Affects/CppNix
Affects/Nightly
Affects/Only nightly
Affects/Stable
Area/build-packaging
Area/cli
Area/evaluator
Area/fetching
Area/flakes
Area/language
Area/lix ci
Area/nix-eval-jobs
Area/profiles
Area/protocol
Area/releng
Area/remote-builds
Area/repl
Area/repl/debugger
Area/store
bug
Context
contributors
Context
drive-by
Context
maintainers
Context
RFD
crash 💥
Cross Compilation
devx
docs
Downstream Dependents
E/easy
E/hard
E/help wanted
E/reproducible
E/requires rearchitecture
Feature/S3
imported
Language/Bash
Language/C++
Language/NixLang
Language/Python
Language/Rust
Needs Langver
OS/Linux
OS/macOS
performance
regression
release-blocker
stability
Status
blocked
Status
invalid
Status
postponed
Status
wontfix
testing
testing/flakey
Topic/Large Scale Installations
ux
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
lix-project/lix#1007
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Describe the bug
The following expression fails to build:
full trace
This happens in my much more convoluted infra repo too and over there I'm using the lix main and the module (
5e2412ea7eandlix-project/nixos-module@3f09a5eb77respectively), so with it yielding the exact same error I'm reasonably sure that this is a build failure due to a nixpkgs change which looks like the fix needs to be implemented in lix (though I've 100% lost track of the intricacies of the entangled web of packages).Steps To Reproduce
one-liner
Expected behavior
nix-serve should be able to build with Lix.
This is especially true since lixPackageSets.latest.nix-serve-ng is currently marked broken in nixos-unstable.
nix --versionoutputAdditional context
This isn't especially urgent for me at least, and nixos-unstable is, well, unstable.
However with November and thus 25.11 around the corner, this web of dependencies is probably better dealt with earlier than later.
Related older issue which had pretty much the same problem:
And please let this issue not be a duplicate for a change, I promise I tried to search the issues 🙃
The reason that #971 was closed with "I'm wasting my time here" is that the cppnix people changed the perl api and then updated nix-serve to match so it no longer works on lix. I'm not thinking about the merits of their change; it may have been good, but I'm not going to go change our perl apis around to support legacy software with known superior alternatives.
You can run an older version of nix-serve against the lix perl bindings if you'd like.
I think the rust nix cache thing has a fork with lix support.
As a general rule, neither the perl nor the c++ apis of lix have any stability guarantees at all and there will never be a goal that our internal APIs are compatible with cppnix. Changes can be sent for review and if they have merit, they may be accepted, but compatibility of internal APIs is not considered.
I have no issue with the won't fix here, and I personally think the reason is more than justified.
However this isn't about changed APIs, rather than the location of the passthru attr has been changed starting with CppNix 2.26.
Instead of exposing lix.perl-bindings software like nix-serve now expects lix.libs.nix-perl-bindings.
more one-liners
Running this against nixpkgs with the Lix overlay (meaning that Lix actually has lix.perl-bindings, which is not merged upstream, as per the below link) fails with the trace as per the OP:
Only moving the bindings to the new passthru path builds:
I just found the nixpkgs PR for getting the former into nixpkgs, however this attribute is also exposed by Lix when pulled in as a flake, the overlay, or the module, so to fix compatibility with nixos-unstable (or rather anything post-CppNix-2.25) the path would need changing in this repo too (unless that one's set in the module, I'm not sure).
That is unless Lix wants to carry forward the diverging passthru attr, which I guess is fine, though it'll push the change down into the packaging of individual packages using the bindings (and potentially other libs) even if those packages themselves are written to be compatible with either.
If you disagree with that assessment, feel free to close the issue again, I only reopened it based on the assumption that it was closed because it looked like an actual API change.
Edit: more infos including references to the commits in nixpkgs changing this are found in the linked PR
Okay, 20 minutes later and two attempts at writing an overlay and deploying software later I come to the conclusion that I'll just close this issue since nix-serve-ng somehow works with all the Lix overlays and modules stacked on top, and the bindings are largely irrelevant anyway since Hydra will probably move to the Lix repo eventually.
The upstream implications are discussed in the nixpkgs PR.
hm. that's not really sensical for us to use as a name because we will not have any other libs in that set because the stuff cppnix did to their derivation to overcomplicate it is not something we're planning to copy. maybe we could have an alias, but the thing is that having the nix level stuff be api compatible is kind of pointless if once you actually build it, it blows up at runtime immediately because the perl api is incompatible as well.
i think strategically we don't want to be chasing cppnix and having api compatibility at a Nix level isn't really useful because we need different versions of the software that link against lix to deal with the c++/perl api differences, which ought to have their own derivations because cppnix is off doing their own thing to their package and nix api which we don't want to chase either.