unofficial mirror of 
 help / color / mirror / code / Atom feed
From: "John Ericson" <>
To:, "Ludovic Courtès" <>,
	"Christopher Baines" <>
Cc: "Florian Klink" <>,
	"Valentin Gagarin" <>,
	"Maxim Cournoyer" <>
Subject: Ensuring daemon interop, maybe also store layer standardization?
Date: Thu, 16 Nov 2023 14:23:29 -0500	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

[-- Attachment #1: Type: text/plain, Size: 5475 bytes --]

On Thu, Nov 16, 2023, at 10:14 AM, Ludovic Courtès wrote:
> My take is that the daemon rewrite in Guix will aim for 100%
> compatibility at the protocol level (in fact part of what’s needed is
> already available as (guix …) modules), probably with just the same
> feature set.  Christopher Baines may have clearer ideas.


I am glad that Florian already emailed about this, I had similar thoughts.

I have long been a proponent of ensuring interoperability in the "store layer" between Nix, Guix, Tvix, and anyone else that wants to have an implementation. (To me, the daemon is just one possible implementation, an RPC bridge to another implementation.) There are some good developments on the Nix side in this space I've been meaning to email this mailing list about. Glad the recent guix-daemon work and ensuing discussion are finally getting me to do so! Here they are:
 • RFC 134 this is the linchpin holding a few things together on the Nix side. Nix gone back and forth over the years emphasizing the degree to which the store layer beneath the Nix language is self-contained and can be used/understood on its own. With that RFC we're finally committing to "show off the store layer" as official policy.
 • there is a new top-level section of the Nix manual that is commentating the store-layer. Expect it to grow rapidly in the coming months as new information is written, and existing information that belongs here but is tagging along elsewhere is moved here.
 • Unit tests with external data "golden masters" for serializes for the daemon protocol, and derivation ATerm format (Since the Guix fork I've tried to systematize the daemon protocol with bidirectional serializers for explicit data types, which the RPC layer uses.) The test data is separate files with the explicit intention of making them easy to reuse in other implementations :), as opposed to just in-code string/binary literals which would be very inconvenient for them.
 • making sure the JSON derivation format is round-tripable with a new command, for ease of use and in hopes that we might someday ditch "ATerm" for the on-disk format for everyone's benefit.
 • C bindings for the Nix store. Perhaps this isn't so important now that you all are going for the full rewrite, but I saw Maxim's early email about creating guile bindings for a gradual rewrite. The C bindings are explicitly made with the idea of making other langauge bindings easier (e.g., Still mentioning this in case it is useful as a "Plan B".
Furthermore, I hope that beyond merely ensuring some interop with what we have already, we work to further keep things in sync and hopefully converging (where was have diverging new features like Blake hashing in Guix and content-addressed derivations in Nix) going forward. To that end, I would love to set up an implementation-agnostic standard, maybe even an IETF standard (!).

I think while we all have different ideas (and should continue to have different ideas!) on what the user-facing package language looks like, we do essential agree on what this store interface looks like. It is a "narrow waist" which can be implemented numerous different ways, and used in numerous different high level packaging paradigms. It is this quality that makes it so worthy of standardization.

> I’m interested in hearing how you view content-addressing and its use.
> In Guix there’s one proposal based on ERIS:
> Previously there was an experiment to implement what you described at
> “partial substitution”:

I have been talking a lot to Florian about these things too. Long ago I emailed Ludo and some others about the IPFS & Nix work. Since then RFC 133 was accepted,, which prepares the way for a lot of that, and more recently (merged) has begun the implementation.

It sounds like this ERIS plan and Tvix's content addressing are fairly similar --- use improved content addressing "underneath the hood". The thing I have been working on is trying to expose content-addressing all the way into the store path for end-to-end trustlessless.

I think for build artifacts, either way is fine. But for source code the end-to-end trustlessness is nice for treating things like Software Heritage as a substituter of last resort. (I made forto spit out raw git objects for, but the pipelining latency issues mean something like SWH's "Vault API" is probably better.)


That's a big wall of text, but glad it's all out there. Stuff is really cooking in all our ecosystems these days, and I'm very excited for where things are going!


[-- Attachment #2: Type: text/html, Size: 7344 bytes --]

  reply	other threads:[~2023-11-16 21:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-30 21:02 Nix Daemon protocol post / Tvix Florian Klink
2023-11-16 15:14 ` Ludovic Courtès
2023-11-16 19:23   ` John Ericson [this message]
2023-11-16 20:52     ` Ensuring daemon interop, maybe also store layer standardization? Florian Klink

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).