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
Make ValidPath (nar) hash
optional if ca
field is present
#4059
base: master
Are you sure you want to change the base?
Make ValidPath (nar) hash
optional if ca
field is present
#4059
Conversation
And after much labor fix all test failures
…dresses-in-path-info
I'm not convinced this is a good idea. It seems that it makes everything way messier. I mean, it's basically a regression: NAR hashes used to be optional which meant that there lots of places where you could end up with a zero hash in your database. |
702fd80
to
04ecf5c
Compare
hash
optional if ca
field is presenthash
optional if ca
field is present
There might be other ways of accomplishing my goal, such as an alternative to To reiterate, I want to keep the requirement the database are narinfo files have this info. I suppose even having remote store / legacy ssh store continue to require NAR hashes is workable too. It just means one would have to talk to these new CA-only store directly and not via a remote store protocol. |
…dresses-in-path-info
…dresses-in-path-info
I marked this as stale due to inactivity. → More info |
I closed this issue due to inactivity. → More info |
We port the
These
data type from Haskell to C++ to maintain the invariant that we must have at least one of a CA or nar hash. This ensures that we can always validate the store entry.Additionally, we also insure that the
LocalStore
andBinaryCacheStore
always have NAR hashes, which makes this feature easier to undo without breaking data in the wild.LocalStore
andBinaryCacheStore
sound like all the "base" stores we have today, so what's the prupose? The intended use-case for this feature would be novel stores that serve data by CA, such aHashedMirrorStore
to replace the hashed mirrors mechanism, IPFS store, or software archive stores.CC @nlewo
This PR is pretty noisy. Most of it is just replacing
.field
with various accessor methods.Fix #3640