-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
derivation designIssues to consider for new versions of the derivation format (major or incremental)Issues to consider for new versions of the derivation format (major or incremental)featureFeature request or proposalFeature request or proposalfetchingNetworking with the outside (non-Nix) world, input lockingNetworking with the outside (non-Nix) world, input lockingscheduling
Description
Is your feature request related to a problem? Please describe.
Sometimes a fixed output derivation doesn't work. For example, a site may have gone offline.
However, the same content may be available in a different location, such as a mirror, web archive, or a peer to peer content addressable store such as IPFS.
Currently, only traditional mirrors lists can be used in anticipation of such failures.
Describe the solutions you'd like
"Inductive":
- Add a special field such as
__alternateDerivation - Only allow it when the output(s) are fixed
- Do not treat it as a dependency
- If the build fails, try the
__alternateDerivationinstead. It must produce an output with the samenameand hash.
"Algebraic":
- Add a new derivation
systemvalue, such asbuiltin:alternatives - Disallow the
builderattribute. - Require fixed outputs
- Instead only allow an
alternativeslist, referencing derivations that implement the fixed output derivation
Comparison
It feels more natural to have metadata to be specified in the latter "algebraic" design, although nothing stops us from doing it with the inductive syntax.
Uses of metadata:
- scheduling can deprioritize bad sources (e.g. domains that are down, protocols that don't work)
- users can configure to disallow certain protocols, etc
Additional context
Priorities
Add 👍 to issues you find important.
flandweber, misaka4a92 and hugosenari
Metadata
Metadata
Assignees
Labels
derivation designIssues to consider for new versions of the derivation format (major or incremental)Issues to consider for new versions of the derivation format (major or incremental)featureFeature request or proposalFeature request or proposalfetchingNetworking with the outside (non-Nix) world, input lockingNetworking with the outside (non-Nix) world, input lockingscheduling