!lTqhfnNvIkcEackxxk:matrix.org

Nix Bindings

94 Members
Nix C API https://github.com/NixOS/nix/blob/master/doc/manual/src/c-api.md, language-specific bindings, and their use cases (currently broken link: https://nixos.org/manual/nix/unstable/c-api)22 Servers

Load older messages


SenderMessageTime
16 Mar 2026
@purepani:matrix.orgpurepani changed their display name from purepanid to purepani.05:55:51
31 Mar 2026
@cry64:matrix.org_cry64 joined the room.00:21:45
1 Apr 2026
@me:linj.techlinj Are string arguments guaranteed to be copied? For example, the doc of nix_store_open says its uri argument is copied. But the doc of its params argument does not mention if params is copied or not. 14:28:43
@me:linj.techlinj * Are string arguments guaranteed to be copied? For example, the doc of nix_store_open says its uri argument is copied. But the doc of its params argument does not mention if params is copied or not. 14:32:36
17 Apr 2026
@c4lliope:matrix.orgc4lliope set a profile picture.08:36:56
@c4lliope:matrix.orgc4lliope changed their profile picture.08:41:48
2 May 2026
@yorickvp:matrix.orgyorickvpthey're copied in practice. would be good to document08:05:00
23 May 2026
@inclyc:matrix.orgYingchi Long changed their profile picture.11:24:33
26 May 2026
@perryhq:matrix.orgperry joined the room.05:29:31
@phanirithvij:matrix.orgphanirithvij/loudgolem changed their display name from loudgolem to phanirithvij.11:41:27
1 Jun 2026
@lillecarl:matrix.orglillecarl joined the room.13:43:36
22 Jun 2026
@ttrss:matrix.orgttrss joined the room.11:59:35
@ttrss:matrix.orgttrss

Hi, im using the nixops4 rust bindings crate and im trying to set the "tarball-ttl" option like this,

            settings::set("tarball-ttl", "0")
                .context("failed to set the tarball-ttl nix option")?;

but unfortunately i get error: failed to initialize evaluator: failed to set the tarball-ttl nix option: Setting not found. Is nix::fetchers::Settings
in libfetchers not being registered? Does anyone know what could be going on?

12:08:19
@ttrss:matrix.orgttrss *

Hi, im using the nixops4 rust bindings crate and im trying to set the "tarball-ttl" option like this,

            settings::set("tarball-ttl", "0")
                .context("failed to set the tarball-ttl nix option")?;

but unfortunately i get error: failed to initialize evaluator: failed to set the tarball-ttl nix option: Setting not found. Is nix::fetchers::Settings in libfetchers not being registered? Does anyone know what could be going on?

12:08:46
20 Jul 2026
@llamato:matrix.orgLlamato joined the room.20:58:18
25 Jul 2026
@hio1998:matrix.orgHalil Ibrahim joined the room.08:33:46
27 Jul 2026
@rasmata:matrix.org@rasmata:matrix.org joined the room.00:55:35
@rasmata:matrix.org@rasmata:matrix.org left the room.00:55:46
6 Aug 2026
@phanirithvij:matrix.orgphanirithvij/loudgolem changed their display name from phanirithvij to phanirithvij/loudgolem.07:28:45
@maybemarisa:matrix.marisa.jetztMaybeMarisa 🏳️‍⚧️ joined the room.11:43:00
7 Aug 2026
@lillecarl:matrix.orglillecarlI've vibed these pretty hard, but https://github.com/lillecarl/nanopynix 09:15:42
@lillecarl:matrix.orglillecarl* I've vibed these pretty hard, but https://github.com/lillecarl/nanopynix is binding Python to C++ Nix with nanobind. Has both inproc and rpc "mode" for both eval, store, flake and friends, run through ASan and TSan in CI. Supports Python primops, Python stores and yadayada09:17:34
@lillecarl:matrix.orglillecarlBuilds and tests against 2.31, 2.34, 2.35 and git/2.36 😄 09:22:53
@lillecarl:matrix.orglillecarl

https://asciinema.org/a/5RRpZt6LwneIuwSs I'm using the bindings to build an alternative Nix CLI as well, here's a demo of the REPL. It's using prompt-toolkit for the editing experience, tree-sitter-nix for highlights and triggering autocompletion.
The idea is that I think it's a shame that "doing cool things" with Nix is locked behind the C++ gate, by driving Nix from Python it opens the door for many more developers to build tooling and workflows around Nix and nixpkgs 😄

nix run github:lillecarl/nanopynix/develop#pynix -- repl --flake github:nixos/nixpkgs
10:23:42
@raf:notashelf.devrafwhy not help improve the C API?19:56:25
@raf:notashelf.devrafI've made a pretty nice nix REPL using my rust bindings for it19:56:43
@raf:notashelf.devrafI think it's got a lot of unrealized potential19:56:51
8 Aug 2026
@lillecarl:matrix.orglillecarl raf: I'm more interested in building now than later, C++ has everything now and nanobind exists. I don't care about ABI compatibility 00:26:46
@lillecarl:matrix.orglillecarl * raf: I'm more interested in building now than later, C++ has everything now and nanobind exists. I don't care about ABI 00:37:38
13 Aug 2026
@soispha:vhack.euSoispha changed their display name from Benedikt to Soispha.15:23:58

There are no newer messages yet.


Back to Room ListRoom Version: 10