From 9f6ed7042986693eb76f338697ec446d1c69c88c Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 6 Oct 2025 16:04:58 +0200 Subject: [PATCH 1/7] release notes: 2.32.0 --- doc/manual/rl-next/c-api-byidx.md | 7 -- doc/manual/rl-next/c-api-lazy-accessors.md | 16 --- .../rl-next/cached-substituted-inputs.md | 10 -- doc/manual/rl-next/derivation-json.md | 15 --- doc/manual/rl-next/dropped-compat.md | 6 - doc/manual/rl-next/faster-nix-flake-check.md | 9 -- .../rl-next/http-binary-cache-compression.md | 19 --- doc/manual/rl-next/shorter-build-dir-names.md | 6 - doc/manual/source/SUMMARY.md.in | 1 + doc/manual/source/release-notes/rl-2.32.md | 112 ++++++++++++++++++ 10 files changed, 113 insertions(+), 88 deletions(-) delete mode 100644 doc/manual/rl-next/c-api-byidx.md delete mode 100644 doc/manual/rl-next/c-api-lazy-accessors.md delete mode 100644 doc/manual/rl-next/cached-substituted-inputs.md delete mode 100644 doc/manual/rl-next/derivation-json.md delete mode 100644 doc/manual/rl-next/dropped-compat.md delete mode 100644 doc/manual/rl-next/faster-nix-flake-check.md delete mode 100644 doc/manual/rl-next/http-binary-cache-compression.md delete mode 100644 doc/manual/rl-next/shorter-build-dir-names.md create mode 100644 doc/manual/source/release-notes/rl-2.32.md diff --git a/doc/manual/rl-next/c-api-byidx.md b/doc/manual/rl-next/c-api-byidx.md deleted file mode 100644 index 9b5bb3fcb..000000000 --- a/doc/manual/rl-next/c-api-byidx.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -synopsis: "C API: `nix_get_attr_name_byidx`, `nix_get_attr_byidx` take a `nix_value *` instead of `const nix_value *`" -prs: [13987] ---- - -In order to accommodate a more optimized internal representation of attribute set merges these functions require -a mutable `nix_value *` that might be modified on access. This does *not* break the ABI of these functions. diff --git a/doc/manual/rl-next/c-api-lazy-accessors.md b/doc/manual/rl-next/c-api-lazy-accessors.md deleted file mode 100644 index bd0604f0d..000000000 --- a/doc/manual/rl-next/c-api-lazy-accessors.md +++ /dev/null @@ -1,16 +0,0 @@ ---- -synopsis: "C API: Add lazy attribute and list item accessors" -prs: [14030] ---- - -The C API now includes lazy accessor functions for retrieving values from lists and attribute sets without forcing evaluation: - -- `nix_get_list_byidx_lazy()` - Get a list element without forcing its evaluation -- `nix_get_attr_byname_lazy()` - Get an attribute value by name without forcing evaluation -- `nix_get_attr_byidx_lazy()` - Get an attribute by index without forcing evaluation - -These functions are useful when forwarding unevaluated sub-values to other lists, attribute sets, or function calls. They allow more efficient handling of Nix values by deferring evaluation until actually needed. - -Additionally, bounds checking has been improved for all `_byidx` functions to properly validate indices before access, preventing potential out-of-bounds errors. - -The documentation for `NIX_ERR_KEY` error handling has also been clarified to specify when this error code is returned. \ No newline at end of file diff --git a/doc/manual/rl-next/cached-substituted-inputs.md b/doc/manual/rl-next/cached-substituted-inputs.md deleted file mode 100644 index b0b53a213..000000000 --- a/doc/manual/rl-next/cached-substituted-inputs.md +++ /dev/null @@ -1,10 +0,0 @@ ---- -synopsis: "Substituted flake inputs are no longer re-copied to the store" -prs: [14041] ---- - -Since 2.25, Nix would fail to store a cache entry for substituted flake inputs, -which in turn would cause them to be re-copied to the store on initial -evaluation. Caching these inputs results in a near doubling of a performance in -some cases — especially on I/O-bound machines and when using commands that -fetch many inputs, like `nix flake archive/prefetch-inputs` diff --git a/doc/manual/rl-next/derivation-json.md b/doc/manual/rl-next/derivation-json.md deleted file mode 100644 index be7ab1cfe..000000000 --- a/doc/manual/rl-next/derivation-json.md +++ /dev/null @@ -1,15 +0,0 @@ ---- -synopsis: Derivation JSON format now uses store path basenames (no store dir) only -prs: [13980] -issues: [13570] ---- - -Experience with many JSON frameworks (e.g. nlohmann/json in C++, Serde in Rust, and Aeson in Haskell), has shown that the use of the store dir in JSON formats is an impediment to systematic JSON formats, -because it requires the serializer/deserializer to take an extra paramater (the store dir). - -We ultimately want to rectify this issue with all (non-stable, able to be changed) JSON formats. -To start with, we are changing the JSON format for derivations because the `nix derivation` commands are ---- in addition to being formally unstable ---- less widely used than other unstable commands. - -See the documentation on the [JSON format for derivations](@docroot@/protocols/json/derivation.md) for further details. diff --git a/doc/manual/rl-next/dropped-compat.md b/doc/manual/rl-next/dropped-compat.md deleted file mode 100644 index d6cc7704a..000000000 --- a/doc/manual/rl-next/dropped-compat.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -synopsis: "Removed support for daemons and clients older than Nix 2.0" -prs: [13951] ---- - -We have dropped support in the daemon worker protocol for daemons and clients that don't speak at least version 18 of the protocol. This first Nix release that supports this version is Nix 2.0, released in February 2018. diff --git a/doc/manual/rl-next/faster-nix-flake-check.md b/doc/manual/rl-next/faster-nix-flake-check.md deleted file mode 100644 index c195023c3..000000000 --- a/doc/manual/rl-next/faster-nix-flake-check.md +++ /dev/null @@ -1,9 +0,0 @@ ---- -synopsis: "`nix flake check` now skips derivations that can be substituted" -prs: [13574] ---- - -Previously, `nix flake check` would evaluate and build/substitute all -derivations. Now, it will skip downloading derivations that can be substituted. -This can drastically decrease the time invocations take in environments where -checks may already be cached (like in CI). diff --git a/doc/manual/rl-next/http-binary-cache-compression.md b/doc/manual/rl-next/http-binary-cache-compression.md deleted file mode 100644 index 88f1de6d9..000000000 --- a/doc/manual/rl-next/http-binary-cache-compression.md +++ /dev/null @@ -1,19 +0,0 @@ ---- -synopsis: "HTTP binary caches now support transparent compression for metadata" -prs: [] ---- - -HTTP binary cache stores can now compress `.narinfo`, `.ls`, and build log files before uploading them, -reducing bandwidth usage and storage requirements. The compression is applied transparently using the -`Content-Encoding` header, allowing compatible clients to automatically decompress the files. - -Three new configuration options control this behavior: -- `narinfo-compression`: Compression method for `.narinfo` files -- `ls-compression`: Compression method for `.ls` files -- `log-compression`: Compression method for build logs in `log/` directory - -Example usage: -``` -nix copy --to 'http://cache.example.com?narinfo-compression=gzip&ls-compression=gzip' /nix/store/... -nix store copy-log --to 'http://cache.example.com?log-compression=br' /nix/store/... -``` diff --git a/doc/manual/rl-next/shorter-build-dir-names.md b/doc/manual/rl-next/shorter-build-dir-names.md deleted file mode 100644 index e87fa5d04..000000000 --- a/doc/manual/rl-next/shorter-build-dir-names.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -synopsis: "Temporary build directories no longer include derivation names" -prs: [13839] ---- - -Temporary build directories created during derivation builds no longer include the derivation name in their path to avoid build failures when the derivation name is too long. This change ensures predictable prefix lengths for build directories under `/nix/var/nix/builds`. \ No newline at end of file diff --git a/doc/manual/source/SUMMARY.md.in b/doc/manual/source/SUMMARY.md.in index 8fed98c2c..25e68811d 100644 --- a/doc/manual/source/SUMMARY.md.in +++ b/doc/manual/source/SUMMARY.md.in @@ -138,6 +138,7 @@ - [Contributing](development/contributing.md) - [Releases](release-notes/index.md) {{#include ./SUMMARY-rl-next.md}} + - [Release 2.32 (2025-10-06)](release-notes/rl-2.32.md) - [Release 2.31 (2025-08-21)](release-notes/rl-2.31.md) - [Release 2.30 (2025-07-07)](release-notes/rl-2.30.md) - [Release 2.29 (2025-05-14)](release-notes/rl-2.29.md) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md new file mode 100644 index 000000000..5c1c314db --- /dev/null +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -0,0 +1,112 @@ +# Release 2.32.0 (2025-10-06) + +- C API: `nix_get_attr_name_byidx`, `nix_get_attr_byidx` take a `nix_value *` instead of `const nix_value *` [#13987](https://github.com/NixOS/nix/pull/13987) + + In order to accommodate a more optimized internal representation of attribute set merges these functions require + a mutable `nix_value *` that might be modified on access. This does *not* break the ABI of these functions. + +- C API: Add lazy attribute and list item accessors [#14030](https://github.com/NixOS/nix/pull/14030) + + The C API now includes lazy accessor functions for retrieving values from lists and attribute sets without forcing evaluation: + + - `nix_get_list_byidx_lazy()` - Get a list element without forcing its evaluation + - `nix_get_attr_byname_lazy()` - Get an attribute value by name without forcing evaluation + - `nix_get_attr_byidx_lazy()` - Get an attribute by index without forcing evaluation + + These functions are useful when forwarding unevaluated sub-values to other lists, attribute sets, or function calls. They allow more efficient handling of Nix values by deferring evaluation until actually needed. + + Additionally, bounds checking has been improved for all `_byidx` functions to properly validate indices before access, preventing potential out-of-bounds errors. + + The documentation for `NIX_ERR_KEY` error handling has also been clarified to specify when this error code is returned. + +- Substituted flake inputs are no longer re-copied to the store [#14041](https://github.com/NixOS/nix/pull/14041) + + Since 2.25, Nix would fail to store a cache entry for substituted flake inputs, + which in turn would cause them to be re-copied to the store on initial + evaluation. Caching these inputs results in a near doubling of a performance in + some cases — especially on I/O-bound machines and when using commands that + fetch many inputs, like `nix flake archive/prefetch-inputs` + +- Derivation JSON format now uses store path basenames (no store dir) only [#13570](https://github.com/NixOS/nix/issues/13570) [#13980](https://github.com/NixOS/nix/pull/13980) + + Experience with many JSON frameworks (e.g. nlohmann/json in C++, Serde in Rust, and Aeson in Haskell), has shown that the use of the store dir in JSON formats is an impediment to systematic JSON formats, + because it requires the serializer/deserializer to take an extra paramater (the store dir). + + We ultimately want to rectify this issue with all (non-stable, able to be changed) JSON formats. + To start with, we are changing the JSON format for derivations because the `nix derivation` commands are + --- in addition to being formally unstable + --- less widely used than other unstable commands. + + See the documentation on the [JSON format for derivations](@docroot@/protocols/json/derivation.md) for further details. + +- Removed support for daemons and clients older than Nix 2.0 [#13951](https://github.com/NixOS/nix/pull/13951) + + We have dropped support in the daemon worker protocol for daemons and clients that don't speak at least version 18 of the protocol. This first Nix release that supports this version is Nix 2.0, released in February 2018. + +- `nix flake check` now skips derivations that can be substituted [#13574](https://github.com/NixOS/nix/pull/13574) + + Previously, `nix flake check` would evaluate and build/substitute all + derivations. Now, it will skip downloading derivations that can be substituted. + This can drastically decrease the time invocations take in environments where + checks may already be cached (like in CI). + +- HTTP binary caches now support transparent compression for metadata + + HTTP binary cache stores can now compress `.narinfo`, `.ls`, and build log files before uploading them, + reducing bandwidth usage and storage requirements. The compression is applied transparently using the + `Content-Encoding` header, allowing compatible clients to automatically decompress the files. + + Three new configuration options control this behavior: + - `narinfo-compression`: Compression method for `.narinfo` files + - `ls-compression`: Compression method for `.ls` files + - `log-compression`: Compression method for build logs in `log/` directory + + Example usage: + ``` + nix copy --to 'http://cache.example.com?narinfo-compression=gzip&ls-compression=gzip' /nix/store/... + nix store copy-log --to 'http://cache.example.com?log-compression=br' /nix/store/... + ``` + +- Temporary build directories no longer include derivation names [#13839](https://github.com/NixOS/nix/pull/13839) + + Temporary build directories created during derivation builds no longer include the derivation name in their path to avoid build failures when the derivation name is too long. This change ensures predictable prefix lengths for build directories under `/nix/var/nix/builds`. + + +## Contributors + + +This release was made possible by the following 32 contributors: + +- Farid Zakaria [**(@fzakaria)**](https://github.com/fzakaria) +- dram [**(@dramforever)**](https://github.com/dramforever) +- Ephraim Siegfried [**(@EphraimSiegfried)**](https://github.com/EphraimSiegfried) +- Robert Hensing [**(@roberth)**](https://github.com/roberth) +- Taeer Bar-Yam [**(@Radvendii)**](https://github.com/Radvendii) +- Emily [**(@emilazy)**](https://github.com/emilazy) +- Jens Petersen [**(@juhp)**](https://github.com/juhp) +- Bernardo Meurer [**(@lovesegfault)**](https://github.com/lovesegfault) +- Jörg Thalheim [**(@Mic92)**](https://github.com/Mic92) +- Leandro Emmanuel Reina Kiperman [**(@kip93)**](https://github.com/kip93) +- Marie [**(@NyCodeGHG)**](https://github.com/NyCodeGHG) +- Ethan Evans [**(@ethanavatar)**](https://github.com/ethanavatar) +- Yaroslav Bolyukin [**(@CertainLach)**](https://github.com/CertainLach) +- Matej Urbas [**(@urbas)**](https://github.com/urbas) +- Jami Kettunen [**(@JamiKettunen)**](https://github.com/JamiKettunen) +- Clayton [**(@netadr)**](https://github.com/netadr) +- Grégory Marti [**(@gmarti)**](https://github.com/gmarti) +- Eelco Dolstra [**(@edolstra)**](https://github.com/edolstra) +- rszyma [**(@rszyma)**](https://github.com/rszyma) +- Philip Wilk [**(@philipwilk)**](https://github.com/philipwilk) +- John Ericson [**(@Ericson2314)**](https://github.com/Ericson2314) +- Tom Westerhout [**(@twesterhout)**](https://github.com/twesterhout) +- Tristan Ross [**(@RossComputerGuy)**](https://github.com/RossComputerGuy) +- Sergei Zimmerman [**(@xokdvium)**](https://github.com/xokdvium) +- Jean-François Roche [**(@jfroche)**](https://github.com/jfroche) +- Seth Flynn [**(@getchoo)**](https://github.com/getchoo) +- éclairevoyant [**(@eclairevoyant)**](https://github.com/eclairevoyant) +- Glen Huang [**(@hgl)**](https://github.com/hgl) +- osman - オスマン [**(@osbm)**](https://github.com/osbm) +- David McFarland [**(@corngood)**](https://github.com/corngood) +- Cole Helbling [**(@cole-h)**](https://github.com/cole-h) +- Sinan Mohd [**(@sinanmohd)**](https://github.com/sinanmohd) +- Philipp Otterbein From c1761b867b5ba1df81c5c2e87a05131bca9ce459 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 6 Oct 2025 16:11:15 +0200 Subject: [PATCH 2/7] Contributors --- .../data/release-credits-email-to-handle.json | 23 ++++++++++++++++++- .../data/release-credits-handle-to-name.json | 21 ++++++++++++++++- 2 files changed, 42 insertions(+), 2 deletions(-) diff --git a/maintainers/data/release-credits-email-to-handle.json b/maintainers/data/release-credits-email-to-handle.json index ea37afb90..0dbbf8fa6 100644 --- a/maintainers/data/release-credits-email-to-handle.json +++ b/maintainers/data/release-credits-email-to-handle.json @@ -203,5 +203,26 @@ "ConnorBaker01@Gmail.com": "ConnorBaker", "jsoo1@asu.edu": "jsoo1", "hsngrmpf+github@gmail.com": "DavHau", - "matthew@floxdev.com": "mkenigs" + "matthew@floxdev.com": "mkenigs", + "taeer@bar-yam.me": "Radvendii", + "beme@anthropic.com": "lovesegfault", + "osbm@osbm.dev": "osbm", + "jami.kettunen@protonmail.com": "JamiKettunen", + "ephraim.siegfried@hotmail.com": "EphraimSiegfried", + "rszyma.dev@gmail.com": "rszyma", + "tristan.ross@determinate.systems": "RossComputerGuy", + "corngood@gmail.com": "corngood", + "jfroche@pyxel.be": "jfroche", + "848000+eclairevoyant@users.noreply.github.com": "eclairevoyant", + "petersen@redhat.com": "juhp", + "dramforever@live.com": "dramforever", + "me@glenhuang.com": "hgl", + "philip.wilk@fivium.co.uk": "philipwilk", + "me@nycode.dev": "NyCodeGHG", + "14264576+twesterhout@users.noreply.github.com": "twesterhout", + "sinan@sinanmohd.com": "sinanmohd", + "42688647+netadr@users.noreply.github.com": "netadr", + "matej.urbas@gmail.com": "urbas", + "ethanalexevans@gmail.com": "ethanavatar", + "greg.marti@gmail.com": "gmarti" } \ No newline at end of file diff --git a/maintainers/data/release-credits-handle-to-name.json b/maintainers/data/release-credits-handle-to-name.json index e2510548d..8abffc65c 100644 --- a/maintainers/data/release-credits-handle-to-name.json +++ b/maintainers/data/release-credits-handle-to-name.json @@ -177,5 +177,24 @@ "avnik": "Alexander V. Nikolaev", "DavHau": null, "aln730": "AGawas", - "vog": "Volker Diels-Grabsch" + "vog": "Volker Diels-Grabsch", + "corngood": "David McFarland", + "twesterhout": "Tom Westerhout", + "JamiKettunen": "Jami Kettunen", + "dramforever": "dram", + "philipwilk": "Philip Wilk", + "netadr": "Clayton", + "NyCodeGHG": "Marie", + "jfroche": "Jean-Fran\u00e7ois Roche", + "urbas": "Matej Urbas", + "osbm": "osman - \u30aa\u30b9\u30de\u30f3", + "rszyma": null, + "eclairevoyant": "\u00e9clairevoyant", + "Radvendii": "Taeer Bar-Yam", + "sinanmohd": "Sinan Mohd", + "ethanavatar": "Ethan Evans", + "gmarti": "Gr\u00e9gory Marti", + "lovesegfault": "Bernardo Meurer", + "EphraimSiegfried": "Ephraim Siegfried", + "hgl": "Glen Huang" } \ No newline at end of file From 0376112a512b7fb8d283e613d6ed6419e741c189 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 6 Oct 2025 16:11:24 +0200 Subject: [PATCH 3/7] Organize release notes --- doc/manual/source/release-notes/rl-2.32.md | 60 ++++++++++------------ 1 file changed, 28 insertions(+), 32 deletions(-) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md index 5c1c314db..885e86631 100644 --- a/doc/manual/source/release-notes/rl-2.32.md +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -1,10 +1,26 @@ # Release 2.32.0 (2025-10-06) +## Incompatible changes + +- Removed support for daemons and clients older than Nix 2.0 [#13951](https://github.com/NixOS/nix/pull/13951) + + We have dropped support in the daemon worker protocol for daemons and clients that don't speak at least version 18 of the protocol. This first Nix release that supports this version is Nix 2.0, released in February 2018. + +- Derivation JSON format now uses store path basenames only [#13570](https://github.com/NixOS/nix/issues/13570) [#13980](https://github.com/NixOS/nix/pull/13980) + + Experience with many JSON frameworks (e.g. nlohmann/json in C++, Serde in Rust, and Aeson in Haskell) has shown that the use of the store directory in JSON formats is an impediment to systematic JSON formats, because it requires the serializer/deserializer to take an extra paramater (the store directory). + + We ultimately want to rectify this issue with all JSON formats to the extent allowed by our stability promises. To start with, we are changing the JSON format for derivations because the `nix derivation` commands are — in addition to being formally unstable — less widely used than other unstable commands. + + See the documentation on the [JSON format for derivations](@docroot@/protocols/json/derivation.md) for further details. + - C API: `nix_get_attr_name_byidx`, `nix_get_attr_byidx` take a `nix_value *` instead of `const nix_value *` [#13987](https://github.com/NixOS/nix/pull/13987) In order to accommodate a more optimized internal representation of attribute set merges these functions require a mutable `nix_value *` that might be modified on access. This does *not* break the ABI of these functions. +## New features + - C API: Add lazy attribute and list item accessors [#14030](https://github.com/NixOS/nix/pull/14030) The C API now includes lazy accessor functions for retrieving values from lists and attribute sets without forcing evaluation: @@ -19,37 +35,6 @@ The documentation for `NIX_ERR_KEY` error handling has also been clarified to specify when this error code is returned. -- Substituted flake inputs are no longer re-copied to the store [#14041](https://github.com/NixOS/nix/pull/14041) - - Since 2.25, Nix would fail to store a cache entry for substituted flake inputs, - which in turn would cause them to be re-copied to the store on initial - evaluation. Caching these inputs results in a near doubling of a performance in - some cases — especially on I/O-bound machines and when using commands that - fetch many inputs, like `nix flake archive/prefetch-inputs` - -- Derivation JSON format now uses store path basenames (no store dir) only [#13570](https://github.com/NixOS/nix/issues/13570) [#13980](https://github.com/NixOS/nix/pull/13980) - - Experience with many JSON frameworks (e.g. nlohmann/json in C++, Serde in Rust, and Aeson in Haskell), has shown that the use of the store dir in JSON formats is an impediment to systematic JSON formats, - because it requires the serializer/deserializer to take an extra paramater (the store dir). - - We ultimately want to rectify this issue with all (non-stable, able to be changed) JSON formats. - To start with, we are changing the JSON format for derivations because the `nix derivation` commands are - --- in addition to being formally unstable - --- less widely used than other unstable commands. - - See the documentation on the [JSON format for derivations](@docroot@/protocols/json/derivation.md) for further details. - -- Removed support for daemons and clients older than Nix 2.0 [#13951](https://github.com/NixOS/nix/pull/13951) - - We have dropped support in the daemon worker protocol for daemons and clients that don't speak at least version 18 of the protocol. This first Nix release that supports this version is Nix 2.0, released in February 2018. - -- `nix flake check` now skips derivations that can be substituted [#13574](https://github.com/NixOS/nix/pull/13574) - - Previously, `nix flake check` would evaluate and build/substitute all - derivations. Now, it will skip downloading derivations that can be substituted. - This can drastically decrease the time invocations take in environments where - checks may already be cached (like in CI). - - HTTP binary caches now support transparent compression for metadata HTTP binary cache stores can now compress `.narinfo`, `.ls`, and build log files before uploading them, @@ -71,10 +56,21 @@ Temporary build directories created during derivation builds no longer include the derivation name in their path to avoid build failures when the derivation name is too long. This change ensures predictable prefix lengths for build directories under `/nix/var/nix/builds`. +## Performance improvements + +- Substituted flake inputs are no longer re-copied to the store [#14041](https://github.com/NixOS/nix/pull/14041) + + Since 2.25, Nix would fail to store a cache entry for substituted flake inputs, which in turn would cause them to be re-copied to the store on initial evaluation. Caching these inputs results in a near doubling of performance in some cases — especially on I/O-bound machines and when using commands that fetch many inputs, like `nix flake [archive|prefetch-inputs]`. + +- `nix flake check` now skips derivations that can be substituted [#13574](https://github.com/NixOS/nix/pull/13574) + + Previously, `nix flake check` would evaluate and build/substitute all + derivations. Now, it will skip downloading derivations that can be substituted. + This can drastically decrease the time invocations take in environments where + checks may already be cached (like in CI). ## Contributors - This release was made possible by the following 32 contributors: - Farid Zakaria [**(@fzakaria)**](https://github.com/fzakaria) From f4e44040d4c92d4ca87601c437922962dffae548 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 6 Oct 2025 16:26:29 +0200 Subject: [PATCH 4/7] Release note for external derivation builders --- doc/manual/source/release-notes/rl-2.32.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md index 885e86631..c2f0eb27f 100644 --- a/doc/manual/source/release-notes/rl-2.32.md +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -56,6 +56,12 @@ Temporary build directories created during derivation builds no longer include the derivation name in their path to avoid build failures when the derivation name is too long. This change ensures predictable prefix lengths for build directories under `/nix/var/nix/builds`. +- External derivation builders [#14145](https://github.com/NixOS/nix/pull/14145) + + These are helper programs that Nix calls to perform derivations for specified system types, e.g. by using QEMU to emulate a different type of platform. For more information, see the [`external-builders` setting](../command-ref/conf-file.md#conf-external-builders). + + This is currently an experimental feature. + ## Performance improvements - Substituted flake inputs are no longer re-copied to the store [#14041](https://github.com/NixOS/nix/pull/14041) From 776038f842d5b4844f9f3411a698733b1d1c0547 Mon Sep 17 00:00:00 2001 From: Bernardo Meurer Costa Date: Mon, 6 Oct 2025 17:09:34 +0000 Subject: [PATCH 5/7] docs(release-notes): note fix for fetchTarball/fetchurl substitution --- doc/manual/source/release-notes/rl-2.32.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md index c2f0eb27f..04f06e6b1 100644 --- a/doc/manual/source/release-notes/rl-2.32.md +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -75,6 +75,10 @@ This can drastically decrease the time invocations take in environments where checks may already be cached (like in CI). +- `fetchTarball` and `fetchurl` now correctly substitute (#14138) + + At some point we stopped substituting calls to `fetchTarball` and `fetchurl` with a set `narHash` to avoid incorrectly substituting things in `fetchTree`, even though it would be safe to substitute when calling the legacy `fetch{Tarball,url}`. This fixes that regression where it is safe. + ## Contributors This release was made possible by the following 32 contributors: From 8f71ef7edee5876af20df403d38d5ef7c4d81008 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Mon, 6 Oct 2025 19:27:30 +0200 Subject: [PATCH 6/7] Update doc/manual/source/release-notes/rl-2.32.md Co-authored-by: Taeer Bar-Yam --- doc/manual/source/release-notes/rl-2.32.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md index 04f06e6b1..d85a4c2ea 100644 --- a/doc/manual/source/release-notes/rl-2.32.md +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -78,7 +78,9 @@ - `fetchTarball` and `fetchurl` now correctly substitute (#14138) At some point we stopped substituting calls to `fetchTarball` and `fetchurl` with a set `narHash` to avoid incorrectly substituting things in `fetchTree`, even though it would be safe to substitute when calling the legacy `fetch{Tarball,url}`. This fixes that regression where it is safe. +- Started moving AST allocations into a bump allocator [#14088](https://github.com/NixOS/nix/issues/14088) + This leaves smaller, immutable structures in the AST. So far this saves about 2% memory on a NixOS config evaluation. ## Contributors This release was made possible by the following 32 contributors: From 0068ee6ca72b0596b67117823e2c73343bade0c0 Mon Sep 17 00:00:00 2001 From: Sergei Zimmerman Date: Mon, 6 Oct 2025 22:16:21 +0300 Subject: [PATCH 7/7] Release note for attrset optimization --- doc/manual/source/release-notes/rl-2.32.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/doc/manual/source/release-notes/rl-2.32.md b/doc/manual/source/release-notes/rl-2.32.md index d85a4c2ea..3a925198d 100644 --- a/doc/manual/source/release-notes/rl-2.32.md +++ b/doc/manual/source/release-notes/rl-2.32.md @@ -64,6 +64,16 @@ ## Performance improvements +- Optimize memory usage of attribute set merges [#13987](https://github.com/NixOS/nix/pull/13987) + + [Attribute set update operations](@docroot@/language/operators.md#update) have been optimized to + reduce reallocations in cases when the second operand is small. + + For typical evaluations of nixpkgs this optimization leads to ~20% less memory allocated in total + without significantly affecting evaluation performance. + + See [eval-attrset-update-layer-rhs-threshold](@docroot@/command-ref/conf-file.md#conf-eval-attrset-update-layer-rhs-threshold) + - Substituted flake inputs are no longer re-copied to the store [#14041](https://github.com/NixOS/nix/pull/14041) Since 2.25, Nix would fail to store a cache entry for substituted flake inputs, which in turn would cause them to be re-copied to the store on initial evaluation. Caching these inputs results in a near doubling of performance in some cases — especially on I/O-bound machines and when using commands that fetch many inputs, like `nix flake [archive|prefetch-inputs]`.