diff --git a/doc/release-notes/rl-2605.section.md b/doc/release-notes/rl-2605.section.md index e429d0aeb599..4dde72103dfb 100644 --- a/doc/release-notes/rl-2605.section.md +++ b/doc/release-notes/rl-2605.section.md @@ -135,6 +135,8 @@ - `pulsar` has finally migrated from electron v12 to v30, backup `~/.pulsar` before upgrading. See [Pulsar on Electron 30: what it means for you](https://blog.pulsar-edit.dev/posts/20251202-savetheclocktower-pulsar-on-electron-30/). +- `mactracker` has been updated to major version 8, which now [requires macOS 11 Big Sur or later](https://mactracker.ca/releasenotes-mac.html#:~:text=System%20requirements%20updated%20to%20macOS%2011%20Big%20Sur%20and%20later). The previous version supported Mac OS X 10.6.8 or later. + - `bartender` has been updated to major version 6. This removes support for MacOS Sonoma (and adds support for Tahoe). For more information, see [the release notes](https://www.macbartender.com/Bartender6/release_notes/) or [the Bartender 6 support page](https://www.macbartender.com/Bartender6/support/). - `lima` has been updated from `1.x` to `2.x`. This major update includes several breaking changes, such as `/tmp/lima` no longer being mounted by default. diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 92b2414814fb..ab3230b9685a 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -14476,6 +14476,12 @@ githubId = 913109; name = "Emil Fresk"; }; + korkutkardes7 = { + email = "korkutkardes7@hotmail.com"; + github = "KorkutKardes7"; + githubId = 148012191; + name = "Korkut Kardeşseven"; + }; kornholi = { email = "kornholijo@gmail.com"; github = "kornholi"; diff --git a/nixos/modules/services/monitoring/grafana.nix b/nixos/modules/services/monitoring/grafana.nix index 0d6c7eb055d4..40eca66a2afb 100644 --- a/nixos/modules/services/monitoring/grafana.nix +++ b/nixos/modules/services/monitoring/grafana.nix @@ -2091,7 +2091,7 @@ in set -o errexit -o pipefail -o nounset -o errtrace shopt -s inherit_errexit - exec ${cfg.package}/bin/grafana server -homepath ${cfg.dataDir} -config ${configFile} + exec ${lib.getExe cfg.package} server -homepath ${cfg.dataDir} -config ${configFile} ''; serviceConfig = { WorkingDirectory = cfg.dataDir; diff --git a/pkgs/applications/editors/emacs/make-emacs.nix b/pkgs/applications/editors/emacs/make-emacs.nix index 583ff9eb5f3b..8a39e96f900e 100644 --- a/pkgs/applications/editors/emacs/make-emacs.nix +++ b/pkgs/applications/editors/emacs/make-emacs.nix @@ -244,13 +244,10 @@ stdenv.mkDerivation (finalAttrs: { nativeBuildInputs = [ makeWrapper pkg-config - ] - ++ lib.optionals (variant == "macport") [ texinfo ] ++ lib.optionals srcRepo [ autoreconfHook - texinfo ] ++ lib.optionals (withPgtk || withX && (withGTK3 || withXwidgets)) [ wrapGAppsHook3 ]; diff --git a/pkgs/applications/editors/emacs/sources.nix b/pkgs/applications/editors/emacs/sources.nix index 47af77ac4703..fb9d9697cd85 100644 --- a/pkgs/applications/editors/emacs/sources.nix +++ b/pkgs/applications/editors/emacs/sources.nix @@ -121,9 +121,16 @@ in name = "inhibit-lexical-cookie-warning-67916.patch"; path = ./inhibit-lexical-cookie-warning-67916-30.patch; }) - # tree-sitter 0.26 compatibility fix, from FreeBSD - # https://cgit.freebsd.org/ports/plain/editors/emacs/files/patch-src_treesit.c - ./tree-sitter-0.26.patch + (fetchpatch { + # tree-sitter 0.26 compatibility fix, see https://bugs.gentoo.org/970856 + url = "https://gitweb.gentoo.org/proj/emacs-patches.git/plain/emacs/30.2/01_all_treesit-0.26.patch?id=d0f47979806d9be5a190fdb4ffa1bde439b2d616"; + hash = "sha256-3pWeRxjAhr3ntBR3xDhoDUZDjU6xICU23NUpb/Vl6R4="; + }) + (fetchpatch { + # tree-sitter 0.26 compatibility fix, see https://bugs.gentoo.org/971731 + url = "https://gitweb.gentoo.org/proj/emacs-patches.git/plain/emacs/30.2/02_all_ts-query-pred.patch?id=86190bf195b3e17108372d8ad89eb57037180dd2"; + hash = "sha256-0GPyfKLSaB09a8hamrSf6lx4Qk8Big4AKMOivkN1wEM="; + }) ]; }); @@ -139,6 +146,16 @@ in url = "https://cgit.git.savannah.gnu.org/cgit/emacs.git/patch/?id=8f535370b9efbc91673b20c6987a5cae4f6dc562"; hash = "sha256-ny44eIi8DUa9pQhVGzhGz4H6FXU4+ki86SITLXhkwpw="; }) + (fetchpatch { + # tree-sitter 0.26 compatibility fix, see https://bugs.gentoo.org/970856 + url = "https://gitweb.gentoo.org/proj/emacs-patches.git/plain/emacs/30.2/01_all_treesit-0.26.patch?id=d0f47979806d9be5a190fdb4ffa1bde439b2d616"; + hash = "sha256-3pWeRxjAhr3ntBR3xDhoDUZDjU6xICU23NUpb/Vl6R4="; + }) + (fetchpatch { + # tree-sitter 0.26 compatibility fix, see https://bugs.gentoo.org/971731 + url = "https://gitweb.gentoo.org/proj/emacs-patches.git/plain/emacs/30.2/02_all_ts-query-pred.patch?id=86190bf195b3e17108372d8ad89eb57037180dd2"; + hash = "sha256-0GPyfKLSaB09a8hamrSf6lx4Qk8Big4AKMOivkN1wEM="; + }) ]; }); } diff --git a/pkgs/applications/editors/emacs/tree-sitter-0.26.patch b/pkgs/applications/editors/emacs/tree-sitter-0.26.patch deleted file mode 100644 index fe3b9ee8db3b..000000000000 --- a/pkgs/applications/editors/emacs/tree-sitter-0.26.patch +++ /dev/null @@ -1,56 +0,0 @@ ---- a/src/treesit.c -+++ b/src/treesit.c -@@ -34,7 +34,7 @@ along with GNU Emacs. If not, see $out + ''; + dontInstall = true; + }; +in +stdenv.mkDerivation (finalAttrs: { pname = "wire-desktop"; + inherit (sources.${stdenv.system}) version src; - versions = builtins.fromJSON (builtins.readFile ./versions.json); + missingHashes = ./missing-hashes.json; + offlineCache = yarn-berry.fetchYarnBerryDeps { + inherit (finalAttrs) src missingHashes; + hash = "sha256-md7B8NSqT9dmPxrp9zbWifNow+1j2tuTRMOljG1V8WE="; + }; - version = - { - x86_64-darwin = versions.macos.version; - aarch64-darwin = versions.macos.version; - x86_64-linux = versions.linux.version; - } - .${system} or throwSystem; + nativeBuildInputs = [ + nodejs + yarn-berry.yarnBerryConfigHook + yarn-berry + makeWrapper + ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ + jq + darwin.autoSignDarwinBinariesHook + ]; - hash = - { - x86_64-darwin = versions.macos.hash; - aarch64-darwin = versions.macos.hash; - x86_64-linux = versions.linux.hash; - } - .${system} or throwSystem; + patches = [ + ./build-linux.patch + ./build-macos.patch + ]; + + # we provide web-config externally due to yarn trying to fetch from github on build phase + postPatch = '' + substituteInPlace .copyconfigrc.js \ + --replace-fail 'repositoryUrl,' 'repositoryUrl, externalDir : "${web-config}",' + ''; + + env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1"; + + # we put the electrons for each platform under `node_modules/electron-dist` due to electron packager grabbing it otherwise + buildPhase = '' + runHook preBuild + + export BUILD_NUMBER=$(echo ${finalAttrs.version} | awk -F. '{print $NF}') + '' + + lib.optionalString stdenv.hostPlatform.isDarwin '' + + # this is needed due to macos builder using electron-packager directly + # we put the zipped electron into a custom path which is defined in the patch, see build-macos.patch + ELECTRON_VERSION_IN_LOCKFILE=$(yarn why electron --json | tail --lines 1 | jq --raw-output '.children | to_entries | first | .key ' | cut -d : -f 2) + mkdir node_modules/electron-dist + cp ${electron-dist-zip} node_modules/electron-dist/electron-v$ELECTRON_VERSION_IN_LOCKFILE-mas-${nodeArch}.zip + + # these variables are needed to skip signing on darwin, we sign with autoSignDarwinBinariesHook later + export MACOS_CERTIFICATE_NAME_APPLICATION="" MACOS_CERTIFICATE_NAME_INSTALLER="" + yarn build:macos:${nodeArch} + + '' + + lib.optionalString (stdenv.hostPlatform.isLinux) '' + + cp -R ${electron.dist} node_modules/electron-dist + # electron needs to have write access otherwire electron-fuses fails + chmod -R u+w node_modules/electron-dist + + # we build only for the linux-unpacked output, not other targets + export LINUX_TARGET=dir + yarn build:linux + + '' + + '' + runHook postBuild + ''; + + installPhase = '' + runHook preInstall + '' + + lib.optionalString stdenv.hostPlatform.isDarwin '' + + mkdir -p $out/{Applications,bin} + cp -r wrap/build/Wire-mas-${nodeArch}/Wire.app $out/Applications + + makeWrapper $out/Applications/Wire.app/Contents/MacOS/Wire $out/bin/wire-desktop + + '' + + lib.optionalString (stdenv.hostPlatform.isLinux) '' + + mkdir -p $out/share/wire-desktop + cp -r wrap/dist/linux-unpacked/{locales,resources{,.pak}} $out/share/wire-desktop + + makeWrapper ${lib.getExe electron} $out/bin/wire-desktop \ + --add-flags $out/share/wire-desktop/resources/app.asar \ + --inherit-argv0 + + for size in 32 256; do + install -Dm644 "resources/icons/"$size"x"$size".png" "$out/share/icons/hicolor/"$size"x"$size"/apps/wire-desktop.png" + done + + '' + + '' + runHook postInstall + ''; + + desktopItem = makeDesktopItem { + categories = [ + "Network" + "InstantMessaging" + "Chat" + "VideoConference" + ]; + comment = "Secure messenger for everyone"; + desktopName = "Wire"; + exec = "wire-desktop %U"; + genericName = "Secure messenger"; + icon = "wire-desktop"; + name = "wire-desktop"; + startupWMClass = "Wire"; + }; meta = { description = "Modern, secure messenger for everyone"; @@ -59,153 +184,17 @@ let ''; homepage = "https://wire.com/"; downloadPage = "https://wire.com/download/"; - sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; license = lib.licenses.gpl3Plus; maintainers = with lib.maintainers; [ arianvp - toonn + ern775 + korkutkardes7 ]; - platforms = lib.platforms.darwin ++ [ + platforms = [ "x86_64-linux" + "aarch64-linux" + "x86_64-darwin" + "aarch64-darwin" ]; - hydraPlatforms = [ ]; }; - - passthru.updateScript = { - command = [ - ./update.sh - ./. - ]; - # R-ryantm does not respect the commit feature, leading to inaccurate - # commit messages because it only sees the Linux version numbers. - # nixpkgs-update: no auto update - supportedFeatures = [ "commit" ]; - }; - - linux = stdenv.mkDerivation rec { - inherit - pname - version - meta - passthru - ; - - src = fetchurl { - url = "https://wire-app.wire.com/linux/debian/pool/main/Wire-${version}_amd64.deb"; - inherit hash; - }; - - desktopItem = makeDesktopItem { - categories = [ - "Network" - "InstantMessaging" - "Chat" - "VideoConference" - ]; - comment = "Secure messenger for everyone"; - desktopName = "Wire"; - exec = "wire-desktop %U"; - genericName = "Secure messenger"; - icon = "wire-desktop"; - name = "wire-desktop"; - startupWMClass = "Wire"; - }; - - dontBuild = true; - dontConfigure = true; - dontPatchELF = true; - dontWrapGApps = true; - - # TODO: migrate off autoPatchelfHook and use nixpkgs' electron - nativeBuildInputs = [ - autoPatchelfHook - dpkg - makeWrapper - (buildPackages.wrapGAppsHook3.override { makeWrapper = buildPackages.makeShellWrapper; }) - ]; - - buildInputs = [ - alsa-lib - libgbm - nss - nspr - systemd - ]; - - installPhase = '' - runHook preInstall - - mkdir -p "$out/bin" - cp -R "opt" "$out" - cp -R "usr/share" "$out/share" - chmod -R g-w "$out" - - # Desktop file - mkdir -p "$out/share/applications" - cp "${desktopItem}/share/applications/"* "$out/share/applications" - - runHook postInstall - ''; - - runtimeDependencies = [ - (lib.getLib udev) - libdbusmenu - ]; - - preFixup = '' - gappsWrapperArgs+=(--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime=true}}") - ''; - - postFixup = '' - makeWrapper $out/opt/Wire/wire-desktop $out/bin/wire-desktop \ - "''${gappsWrapperArgs[@]}" - ''; - }; - - darwin = stdenv.mkDerivation { - inherit - pname - version - meta - passthru - ; - - src = fetchurl { - url = "https://github.com/wireapp/wire-desktop/releases/download/macos%2F${version}/Wire.pkg"; - inherit hash; - }; - - buildInputs = [ - cpio - xar - ]; - - unpackPhase = '' - runHook preUnpack - - xar -xf $src - cd com.wearezeta.zclient.mac.pkg - - runHook postUnpack - ''; - - buildPhase = '' - runHook preBuild - - cat Payload | gunzip -dc | cpio -i - - runHook postBuild - ''; - - installPhase = '' - runHook preInstall - - mkdir -p $out/Applications - cp -r Wire.app $out/Applications - - runHook postInstall - ''; - }; - -in -if stdenv.hostPlatform.isDarwin then darwin else linux +}) diff --git a/pkgs/by-name/wi/wire-desktop/update.sh b/pkgs/by-name/wi/wire-desktop/update.sh deleted file mode 100755 index 65fb554d6aab..000000000000 --- a/pkgs/by-name/wi/wire-desktop/update.sh +++ /dev/null @@ -1,89 +0,0 @@ -#!/usr/bin/env nix-shell -#!nix-shell -i bash -p curl jq - -set -e - -cd $1 - -releases=$(curl -L \ - -H "Accept: application/vnd.github+json" \ - -H "X-GitHub-Api-Version: 2022-11-28" \ - "https://api.github.com/repos/wireapp/wire-desktop/releases" \ -) - -latest=$(jq --argjson suffix '{ "linux": ".deb", "macos": ".pkg" }' \ - --slurpfile versions versions.json ' - def platform_latest(platform): - map(select(.tag_name | startswith(platform))) - | max_by(.tag_name) - | { version: .tag_name | ltrimstr(platform + "/") - , url: .assets.[] - | .browser_download_url - | select(endswith($suffix.[platform])) - }; - - . as $releases - | $versions.[] as $old - | $old - | with_entries( .key as $key - | { key: $key, value: $releases | platform_latest($key) } - | select(.value.version != $old.[$key].version) - ) -' <<< "$releases" -) - -urlHashes=$( - printf '{ ' - function entries () { - local sep='' - for url in $(jq --raw-output '.[].url' <<< "$latest"); do - hash=$(nix-hash --to-sri --type sha256 $(nix-prefetch-url $url)) - if [ -z "$hash" ]; then - printf 'Failed to retrieve hash for %s\n' "$url" 2>&1 - fi - printf '%s"%s": "%s"\n' "$sep" "$url" "$hash" - sep=', ' - done - } - entries - printf '}' -) - -commit=$(jq --arg versionJSON "$(printf '%s/versions.json' "$1")" \ - --slurpfile versions versions.json ' - $versions.[] as $old - | to_entries - | map("\(.key) \($old.[.key].version) -> \(.value.version)") - | join(", ") - | [ if . == "" - then empty - else { attrPath: "wire-desktop" - , oldVersion: "A" - , newVersion: "B" - , files: [ $versionJSON ] - , commitMessage: "wire-desktop: \(.)" - } - end - ] -' <<< "$latest" -) - -tempfile=$(mktemp) - -updated=$(jq --argjson hashes "$urlHashes" --slurpfile versions versions.json ' - $versions.[] as $old - | $old + map_values(with_entries(if .key == "url" - then { key: "hash" - , value: $hashes.[.value] - } - else . - end - ) - ) -' <<< "$latest" > $tempfile -) - -mv $tempfile versions.json - -printf '%s' "$commit" -exit 0 diff --git a/pkgs/by-name/wi/wire-desktop/versions.json b/pkgs/by-name/wi/wire-desktop/versions.json deleted file mode 100644 index d1771695f066..000000000000 --- a/pkgs/by-name/wi/wire-desktop/versions.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "linux": { - "version": "3.40.3882", - "hash": "sha256-8cZGbOngQ0LcUdCcalexkF2nEDb+u3I0zqEbRf/sRiw=" - }, - "macos": { - "version": "3.40.5442", - "hash": "sha256-BxGkAbkl5kgeHq4dgITYsU1fXFY8XDWEOfwjHnk6XtQ=" - } -} diff --git a/pkgs/by-name/xr/xremap/package.nix b/pkgs/by-name/xr/xremap/package.nix index f94197d0e164..3ee0e4d02b91 100644 --- a/pkgs/by-name/xr/xremap/package.nix +++ b/pkgs/by-name/xr/xremap/package.nix @@ -58,13 +58,13 @@ assert ( ); rustPlatform.buildRustPackage (finalAttrs: { pname = "xremap${variant.suffix or ""}"; - version = "0.15.1"; + version = "0.15.2"; src = fetchFromGitHub { owner = "xremap"; repo = "xremap"; tag = "v${finalAttrs.version}"; - hash = "sha256-PvhpPdgAnCT8HaPEQHdTSympmGqRAK9/t3T5KEHovMM="; + hash = "sha256-J07iDGltzJg/2r+bUlBaOpZxAhg020J1giqbTZNSDRY="; }; nativeBuildInputs = [ pkg-config ]; @@ -72,7 +72,7 @@ rustPlatform.buildRustPackage (finalAttrs: { buildNoDefaultFeatures = true; buildFeatures = variant.features; - cargoHash = "sha256-t32EVL8btJEeqWL5601+6pptT/Mt4KxMeVVlNo/nw5k="; + cargoHash = "sha256-iBlX0ikkzZu2VTKXF9UEe9qA+i9OjEOwWSpwvsqGPFQ="; passthru = lib.mapAttrs (name: lib.const (xremap.override { withVariant = name; })) variants; diff --git a/pkgs/by-name/yg/yggdrasil-ng/package.nix b/pkgs/by-name/yg/yggdrasil-ng/package.nix index 7af423a0b2de..e4a109846271 100644 --- a/pkgs/by-name/yg/yggdrasil-ng/package.nix +++ b/pkgs/by-name/yg/yggdrasil-ng/package.nix @@ -5,16 +5,16 @@ }: rustPlatform.buildRustPackage (oldAttrs: { pname = "yggdrasil-ng"; - version = "0.1.4"; + version = "0.1.6"; src = fetchFromGitHub { owner = "Revertron"; repo = "Yggdrasil-ng"; tag = "v${oldAttrs.version}"; - hash = "sha256-AutOV1FXBeiG9CNoVSili3sF+QndZI2L7b72jdPOe5E="; + hash = "sha256-nJLK5O2kjFRGZ3JwqwLHtYqvJfrOxtZOjdM6q2NNrbk="; }; - cargoHash = "sha256-9/whbfM5fMZT6COo2HvdCmeCFC93NI1GXhGNAAaTiLM="; + cargoHash = "sha256-mJr8IMTbB+mSrsxzq6ehnfBueulNqZtxU/1aHAyv954="; __structuredAttrs = true; diff --git a/pkgs/by-name/ze/zenn-cli/package.nix b/pkgs/by-name/ze/zenn-cli/package.nix index f8e8cf443630..432303a01549 100644 --- a/pkgs/by-name/ze/zenn-cli/package.nix +++ b/pkgs/by-name/ze/zenn-cli/package.nix @@ -40,8 +40,8 @@ stdenv.mkDerivation (finalAttrs: { pnpmWorkspaces ; pnpm = pnpm_10; - fetcherVersion = 1; - hash = "sha256-WXsS5/J08n/dWV5MbyX4vK7j1mfiUoLdzwmzyqoX3FA="; + fetcherVersion = 3; + hash = "sha256-uxeZnYZzwyNOZN1x1f6tzcYgPbJhSc3gTdsfaE+967w="; }; preBuild = '' diff --git a/pkgs/by-name/zi/zigbee2mqtt/package.nix b/pkgs/by-name/zi/zigbee2mqtt/package.nix index 52365017d72a..39f9521557ce 100644 --- a/pkgs/by-name/zi/zigbee2mqtt/package.nix +++ b/pkgs/by-name/zi/zigbee2mqtt/package.nix @@ -26,8 +26,8 @@ stdenv.mkDerivation (finalAttrs: { pnpmDeps = fetchPnpmDeps { inherit (finalAttrs) pname version src; pnpm = pnpm_9; - fetcherVersion = 1; - hash = "sha256-8ioe9/gSI9u9ehrnj3L1j+vPS9p+nJGs2d8TdZTEsk4="; + fetcherVersion = 3; + hash = "sha256-uYzY1ixKTughpc6JfoMmp4/RKdgP1cKBuMMLZspSx18="; }; nativeBuildInputs = [ diff --git a/pkgs/development/python-modules/brax/default.nix b/pkgs/development/python-modules/brax/default.nix index e2609c149536..d74a839c505a 100644 --- a/pkgs/development/python-modules/brax/default.nix +++ b/pkgs/development/python-modules/brax/default.nix @@ -40,6 +40,7 @@ buildPythonPackage (finalAttrs: { pname = "brax"; version = "0.14.2"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google"; @@ -48,6 +49,20 @@ buildPythonPackage (finalAttrs: { hash = "sha256-/oznBa44xKl+9T1YrTVhCbuKZj16V1BTlnmCGRbF45g="; }; + patches = [ + # AttributeError: jax.device_put_replicated is deprecated; use jax.device_put instead. + # See https://docs.jax.dev/en/latest/migrate_pmap.html#drop-in-replacements for a drop-in replacement. + ./dont-use-device_put_replicated-compat.patch + ]; + + # TypeError: clip() got an unexpected keyword argument 'a_min' + postPatch = '' + substituteInPlace brax/fluid.py \ + --replace-fail \ + "box = 6.0 * jp.clip(jp.sum(diag_inertia_v, axis=-1), a_min=1e-12)" \ + "box = 6.0 * jp.clip(jp.sum(diag_inertia_v, axis=-1), min=1e-12)" + ''; + build-system = [ hatchling ]; diff --git a/pkgs/development/python-modules/brax/dont-use-device_put_replicated-compat.patch b/pkgs/development/python-modules/brax/dont-use-device_put_replicated-compat.patch new file mode 100644 index 000000000000..261aa5907a60 --- /dev/null +++ b/pkgs/development/python-modules/brax/dont-use-device_put_replicated-compat.patch @@ -0,0 +1,68 @@ +diff --git a/brax/training/agents/apg/train.py b/brax/training/agents/apg/train.py +index f5fcb0e..87b198f 100644 +--- a/brax/training/agents/apg/train.py ++++ b/brax/training/agents/apg/train.py +@@ -310,7 +310,7 @@ def train( + specs.Array((env.observation_size,), jnp.dtype(dtype)) + ), + ) +- training_state = jax.device_put_replicated( ++ training_state = pmap.device_put_replicated( + training_state, jax.local_devices()[:local_devices_to_use] + ) + +diff --git a/brax/training/agents/ppo/train.py b/brax/training/agents/ppo/train.py +index 9aec960..6624733 100644 +--- a/brax/training/agents/ppo/train.py ++++ b/brax/training/agents/ppo/train.py +@@ -753,7 +753,7 @@ def train( + {}, + ) + +- training_state = jax.device_put_replicated( ++ training_state = pmap.device_put_replicated( + training_state, jax.local_devices()[:local_devices_to_use] + ) + +diff --git a/brax/training/agents/sac/train.py b/brax/training/agents/sac/train.py +index be716e9..8dcf3bf 100644 +--- a/brax/training/agents/sac/train.py ++++ b/brax/training/agents/sac/train.py +@@ -108,7 +108,7 @@ def _init_training_state( + alpha_params=log_alpha, + normalizer_params=normalizer_params, + ) +- return jax.device_put_replicated( ++ return pmap.device_put_replicated( + training_state, jax.local_devices()[:local_devices_to_use] + ) + +diff --git a/brax/training/pmap.py b/brax/training/pmap.py +index 82760fc..af62ef8 100644 +--- a/brax/training/pmap.py ++++ b/brax/training/pmap.py +@@ -19,12 +19,23 @@ from typing import Any + + import jax + import jax.numpy as jnp ++from jax.sharding import Mesh, NamedSharding, PartitionSpec as P ++import numpy as np ++ ++ ++def device_put_replicated(x, devices): ++ """Drop-in replacement for jax.device_put_replicated supporting pytrees.""" ++ mesh = Mesh(np.array(devices), ('x',)) ++ sharding = NamedSharding(mesh, P('x')) ++ return jax.tree.map( ++ lambda y: jax.device_put(jnp.stack([y] * len(devices)), sharding), x ++ ) + + + def bcast_local_devices(value, local_devices_to_use=1): + """Broadcasts an object to all local devices.""" + devices = jax.local_devices()[:local_devices_to_use] +- return jax.device_put_replicated(value, devices) ++ return device_put_replicated(value, devices) + + + def synchronize_hosts(): diff --git a/pkgs/development/python-modules/chex/default.nix b/pkgs/development/python-modules/chex/default.nix index dde855d7415c..ed93783889d6 100644 --- a/pkgs/development/python-modules/chex/default.nix +++ b/pkgs/development/python-modules/chex/default.nix @@ -2,6 +2,7 @@ lib, buildPythonPackage, fetchFromGitHub, + fetchpatch, # build-system flit-core, @@ -20,25 +21,35 @@ pytestCheckHook, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "chex"; version = "0.1.91"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "deepmind"; repo = "chex"; - tag = "v${version}"; + tag = "v${finalAttrs.version}"; hash = "sha256-lJ9+kvG7dRtfDVgvkcJ9/jtnX0lMfxY4mmZ290y/74U="; }; + patches = [ + # jax.device_put_replicated is removed in jax 0.10.0 + # This fix was merged upstream -> remove when updating to the next release + (fetchpatch { + url = "https://github.com/google-deepmind/chex/commit/5fbd2c9a9936799daf92354e0307b9e88b9cc163.patch"; + excludes = [ + "chex/_src/variants.py" + ]; + hash = "sha256-ZTimSq7/yt2UEiWmLcfFBadX8+VcaxuPhkQJEyiEZlE="; + }) + ]; + build-system = [ flit-core ]; - pythonRelaxDeps = [ - "typing_extensions" - ]; dependencies = [ absl-py jax @@ -69,8 +80,8 @@ buildPythonPackage rec { meta = { description = "Library of utilities for helping to write reliable JAX code"; homepage = "https://github.com/deepmind/chex"; - changelog = "https://github.com/google-deepmind/chex/releases/tag/v${version}"; + changelog = "https://github.com/google-deepmind/chex/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.asl20; maintainers = with lib.maintainers; [ ndl ]; }; -} +}) diff --git a/pkgs/development/python-modules/clu/default.nix b/pkgs/development/python-modules/clu/default.nix index 9f6f4f966517..5818e92219e3 100644 --- a/pkgs/development/python-modules/clu/default.nix +++ b/pkgs/development/python-modules/clu/default.nix @@ -31,6 +31,7 @@ buildPythonPackage (finalAttrs: { pname = "clu"; version = "0.0.12"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google"; @@ -39,6 +40,15 @@ buildPythonPackage (finalAttrs: { hash = "sha256-ntqRz3fCXMf0EDQsddT68Mdi105ECBVQpVsStzk2kvQ="; }; + # Fix Jax 0.10.0 compatibility + # TypeError: clip() got an unexpected keyword argument 'a_min' + postPatch = '' + substituteInPlace clu/metrics.py \ + --replace-fail \ + "variance = jnp.clip(variance, a_min=0.0)" \ + "variance = jnp.clip(variance, min=0.0)" + ''; + build-system = [ setuptools ]; diff --git a/pkgs/development/python-modules/distrax/default.nix b/pkgs/development/python-modules/distrax/default.nix index b438f69eebec..8f6cf0d383cb 100644 --- a/pkgs/development/python-modules/distrax/default.nix +++ b/pkgs/development/python-modules/distrax/default.nix @@ -24,6 +24,7 @@ buildPythonPackage (finalAttrs: { pname = "distrax"; version = "0.1.8"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google-deepmind"; diff --git a/pkgs/development/python-modules/django-filingcabinet/default.nix b/pkgs/development/python-modules/django-filingcabinet/default.nix index ac426b332d98..9dd305b3ad37 100644 --- a/pkgs/development/python-modules/django-filingcabinet/default.nix +++ b/pkgs/development/python-modules/django-filingcabinet/default.nix @@ -97,8 +97,8 @@ buildPythonPackage rec { pnpmDeps = fetchPnpmDeps { inherit pname version src; - fetcherVersion = 1; - hash = "sha256-kvLV/pCX/wQHG0ttrjSro7/CoQ5K1T0aFChafQOwvNw="; + fetcherVersion = 3; + hash = "sha256-p+RpEDVbdYmeSD4bB0oUMrTpsVDGYkqME13awnoTNd0="; }; postBuild = '' diff --git a/pkgs/development/python-modules/django-rq/default.nix b/pkgs/development/python-modules/django-rq/default.nix index 43859c8dcbeb..a946f4d89b54 100644 --- a/pkgs/development/python-modules/django-rq/default.nix +++ b/pkgs/development/python-modules/django-rq/default.nix @@ -53,6 +53,11 @@ buildPythonPackage (finalAttrs: { export DJANGO_SETTINGS_MODULE=tests.settings ''; + disabledTests = [ + # ValueError: Job ID must only contain letters, numbers, underscores and dashes + "test_scheduled_jobs" + ]; + meta = { description = "Simple app that provides django integration for RQ (Redis Queue)"; homepage = "https://github.com/rq/django-rq"; diff --git a/pkgs/development/python-modules/equinox/default.nix b/pkgs/development/python-modules/equinox/default.nix index 841e4f2858ab..4cfb141ecdb0 100644 --- a/pkgs/development/python-modules/equinox/default.nix +++ b/pkgs/development/python-modules/equinox/default.nix @@ -21,14 +21,15 @@ buildPythonPackage (finalAttrs: { pname = "equinox"; - version = "0.13.6"; + version = "0.13.7"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "patrick-kidger"; repo = "equinox"; tag = "v${finalAttrs.version}"; - hash = "sha256-OETWXAcCp945mMrpC8U4gSBvEeQX8RoUGZR4irBs7Ak="; + hash = "sha256-vgmU8cqNCyiZYah1SSwzVtLS+YB2T1uooCC17k12+h8="; }; # Relax speed constraints on tests that can fail on busy builders @@ -56,25 +57,6 @@ buildPythonPackage (finalAttrs: { pytestCheckHook ]; - pytestFlags = [ - # DeprecationWarning: The default axis_types will change in JAX v0.9.0 to jax.sharding.AxisType.Explicit. - "-Wignore::DeprecationWarning" - ]; - - disabledTestPaths = [ - # ValueError: not enough values to unpack (expected 2, got 0) - "tests/test_finalise_jaxpr.py" - ]; - - disabledTests = [ - # Failed: DID NOT WARN. No warnings of type (,) were emitted. - # Reported upstream: https://github.com/patrick-kidger/equinox/issues/1186 - "test_jax_transform_warn" - - # Flaky: AssertionError: Non-linear scaling detected - "test_speed_buffer_while" - ]; - pythonImportsCheck = [ "equinox" ]; meta = { diff --git a/pkgs/development/python-modules/flax/default.nix b/pkgs/development/python-modules/flax/default.nix index 119b841cde81..89f24260f486 100644 --- a/pkgs/development/python-modules/flax/default.nix +++ b/pkgs/development/python-modules/flax/default.nix @@ -13,7 +13,6 @@ numpy, optax, orbax-checkpoint, - orbax-export, pyyaml, rich, tensorstore, @@ -36,14 +35,15 @@ buildPythonPackage (finalAttrs: { pname = "flax"; - version = "0.12.6"; + version = "0.12.7"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google"; repo = "flax"; tag = "v${finalAttrs.version}"; - hash = "sha256-rIDfF9W8cxF0njH4e4uhqURQ0C4N8Boe76u6meMgC34="; + hash = "sha256-a78KiTsCCARWZvbxz9QKdUKnjkDJGXcPVVJu5rU4m/U="; }; build-system = [ @@ -58,7 +58,6 @@ buildPythonPackage (finalAttrs: { numpy optax orbax-checkpoint - orbax-export pyyaml rich tensorstore @@ -78,11 +77,6 @@ buildPythonPackage (finalAttrs: { tensorflow ]; - pytestFlags = [ - # FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar. - "-Wignore::FutureWarning" - ]; - disabledTestPaths = [ # Docs test, needs extra deps + we're not interested in it. "docs/_ext/codediff_test.py" diff --git a/pkgs/development/python-modules/funsor/default.nix b/pkgs/development/python-modules/funsor/default.nix index b82ca7614486..96c7dcd3a62e 100644 --- a/pkgs/development/python-modules/funsor/default.nix +++ b/pkgs/development/python-modules/funsor/default.nix @@ -49,6 +49,13 @@ buildPythonPackage rec { }) ]; + # TypeError: clip() got an unexpected keyword argument 'a_max' + postPatch = '' + substituteInPlace funsor/jax/ops.py \ + --replace-fail "a_max=" "max=" \ + --replace-fail "a_min=" "min=" + ''; + build-system = [ setuptools ]; dependencies = [ diff --git a/pkgs/development/python-modules/jax-cuda12-pjrt/default.nix b/pkgs/development/python-modules/jax-cuda12-pjrt/default.nix index c7826b24546f..57454d4f84b6 100644 --- a/pkgs/development/python-modules/jax-cuda12-pjrt/default.nix +++ b/pkgs/development/python-modules/jax-cuda12-pjrt/default.nix @@ -50,8 +50,8 @@ buildPythonPackage (finalAttrs: { .${stdenv.hostPlatform.system}; hash = { - x86_64-linux = "sha256-U2owUpInbFdF77un61dXaEnFp8dzmKOp5h/TG69RAvA="; - aarch64-linux = "sha256-VvSifl8ZypFMD0QCU5RpqpLQG/cTNqzQ7Y/dwgqRvI0="; + x86_64-linux = "sha256-MJUVRT9Zyq2Vv3bIvGScJLwOPRLQe68895K+CCq97js="; + aarch64-linux = "sha256-NqwxbFiKDgjrZPhoJwUmrco4VtS3CxN2C36bc76F0s8="; } .${stdenv.hostPlatform.system}; }; diff --git a/pkgs/development/python-modules/jax-cuda12-plugin/default.nix b/pkgs/development/python-modules/jax-cuda12-plugin/default.nix index 0ccf040f552f..ad450298399c 100644 --- a/pkgs/development/python-modules/jax-cuda12-plugin/default.nix +++ b/pkgs/development/python-modules/jax-cuda12-plugin/default.nix @@ -39,42 +39,42 @@ let "3.11-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp311"; - hash = "sha256-1Vd82Ge9kmd2nkU7rYUNSAeoQ5a8l29jKlFe29d+SEs="; + hash = "sha256-lXMXyv8eawBqE1UXM3cN8jWidHBkviawJ0YP46WPWO4="; }; "3.11-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp311"; - hash = "sha256-s5VfN10XkC8NJ+cFlnLNGWOlU0WVOkJpnk4HjOxyWtw="; + hash = "sha256-GkpKVqgyrTDgHBQIWx+iRApV+kzggI5AXnNlDv+K+zE="; }; "3.12-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp312"; - hash = "sha256-iKVZCNd1sG3akqjE9MAVd44lulw2BbV/hLAAUvZujvE="; + hash = "sha256-oWugDXI2YUWCfKOajISfn+4Rd9ZzjJ7f1ys6n+31zxg="; }; "3.12-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp312"; - hash = "sha256-sozPBbzAvHzLy9Mm2AKEZXTPbaA5FY52FHvZb1xvEYk="; + hash = "sha256-6vGmGVqg60i0IMcfIrktGXeNlIAkl3yuRkEnnV9sH4E="; }; "3.13-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp313"; - hash = "sha256-vX3+0Xv6nQ4wFvjCpnZ8dHnZHhvf33kW6ysHQ1zEZY4="; + hash = "sha256-7QdNN5Z7zmHBuv3fndCoMCMGwS+QcAylrfo9CP3Uruc="; }; "3.13-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp313"; - hash = "sha256-uaJwhdiTzFnCsoaxeJdV+Rzz6rHeobW+nmMvTJc5og4="; + hash = "sha256-dHnmfZ2Y1KD1JflPi4GIDcwFhjH23hGLkd6R2xtAle0="; }; "3.14-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp314"; - hash = "sha256-U1F0LA/LIdqeCUoZZasg/eUlhih392kYpJCxtWZk1To="; + hash = "sha256-96ahiBNJ3DnyRIGioBn/KUuUkJuAqIge/iHUW2pfaR0="; }; "3.14-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp314"; - hash = "sha256-MyEmmeG7sb7V0q4Urp/3Kh7tLQkqUearzAJ4prK4KHQ="; + hash = "sha256-iIb8V5df7gG+FyX4mLaSkvYVtwgwrvXC+95jgzNha10="; }; }; in diff --git a/pkgs/development/python-modules/jax/default.nix b/pkgs/development/python-modules/jax/default.nix index c68c1e516388..d2a0a7109cf2 100644 --- a/pkgs/development/python-modules/jax/default.nix +++ b/pkgs/development/python-modules/jax/default.nix @@ -6,7 +6,6 @@ lapack, buildPythonPackage, fetchFromGitHub, - fetchpatch2, cudaSupport ? config.cudaSupport, # build-system @@ -41,25 +40,18 @@ let in buildPythonPackage (finalAttrs: { pname = "jax"; - version = "0.9.2"; + version = "0.10.0"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google"; repo = "jax"; # google/jax contains tags for jax and jaxlib. Only use jax tags! tag = "jax-v${finalAttrs.version}"; - hash = "sha256-/vLCTAF46M1H0Q64RLM7+IFMofmjZmZ4IFzvm/y7zkg="; + hash = "sha256-/RCihrjONN/+QwyQRNEmlIa7JsCLzz+SkBe5sd+ThgU="; }; - patches = [ - # https://github.com/jax-ml/jax/pull/32840 - (fetchpatch2 { - url = "https://github.com/Prince213/jax/commit/af5c211d49f3b99447db2252d2cc2b8e0fb54d1c.patch?full_index=1"; - hash = "sha256-ijEd+MDe91qyYfE+aMzR5rNmTeGadin6Io8PIfJWc3o="; - }) - ]; - build-system = [ setuptools ]; # The version is automatically set to ".dev" if this variable is not set. diff --git a/pkgs/development/python-modules/jaxlib/bin.nix b/pkgs/development/python-modules/jaxlib/bin.nix index ef55de72ac84..deb80c9b68ad 100644 --- a/pkgs/development/python-modules/jaxlib/bin.nix +++ b/pkgs/development/python-modules/jaxlib/bin.nix @@ -18,7 +18,7 @@ }: let - version = "0.9.2"; + version = "0.10.0"; inherit (python) pythonVersion; # As of 2023-06-06, google/jax upstream is no longer publishing CPU-only wheels to their GCS bucket. Instead the @@ -49,65 +49,65 @@ let "3.11-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp311"; - hash = "sha256-msmVtLoaru2uDWnzGZh9UV3K7NRQW2QrYxL54VQ5NR8="; + hash = "sha256-m+IpmTpB5bK4TyNOzBml3gLzXt2xGVzwJ71TnhYB4V0="; }; "3.11-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp311"; - hash = "sha256-MG3lSh3nOGyAbHI+NWzjMtkj73SPinLWdP77dIEh1Nw="; + hash = "sha256-PblOvIWTddlV3jUEGCrdfOFzPOPTDBXg7wMWAstRpVk="; }; "3.11-aarch64-darwin" = getSrcFromPypi { platform = "macosx_11_0_arm64"; dist = "cp311"; - hash = "sha256-eF8XfD63jLfceXxV7VxLYxIUGEXJpoaVfkhLrL/OXog="; + hash = "sha256-J3Ay6fB0w/1f/R4MsD1P5m4nLeRyZnzbxBitmbIbZGo="; }; "3.12-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp312"; - hash = "sha256-iLJ2px9PIHGx/S6SKr/WfIfGl3pVGhA2/rzqeNXvfiI="; + hash = "sha256-sL+4ZaB98ubXQYwLDCkt0pS1UAUjsd1YcrGA2yqkgNQ="; }; "3.12-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp312"; - hash = "sha256-/vAthGhjtybnJFKZOIOoWW6sMl8ioux+qSHaD7xVCbQ="; + hash = "sha256-qh1w8aTifrQDZU5x4vso1XhtPpt3/BhH6MU4mICSfKQ="; }; "3.12-aarch64-darwin" = getSrcFromPypi { platform = "macosx_11_0_arm64"; dist = "cp312"; - hash = "sha256-l8L75Yy+5KJ9lMpzXXCdIxspmrbtizsQdfUthk39MsE="; + hash = "sha256-fB2bRjMnx6IzPyEBFOywTyj+/FG6gjOoWiKAzOdb20I="; }; "3.13-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp313"; - hash = "sha256-ttUAPjrdXDRqNK6e3EcFjLwttgyO1cUAllIhdtrwHJ8="; + hash = "sha256-0wPcMbZei3k9VgD4GxWDvgPcm4dqTBCz4lm2YJocvjs="; }; "3.13-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp313"; - hash = "sha256-vvYe7zbtOM7BBp6pc/iK+eAzNeiE9lAew/5/YiKhVVs="; + hash = "sha256-bY14twcLNOTFu6X34Qkn5/Sqybab4X6bCliYVTpDOPM="; }; "3.13-aarch64-darwin" = getSrcFromPypi { platform = "macosx_11_0_arm64"; dist = "cp313"; - hash = "sha256-UqADJQj4z1eRx6e+4UJTHucGw8BVGBF/sLbujV4X/ec="; + hash = "sha256-OEY1//VYmaKVu8gu5sb3c6MA54fcRyypK755q/qsg2k="; }; "3.14-x86_64-linux" = getSrcFromPypi { platform = "manylinux_2_27_x86_64"; dist = "cp314"; - hash = "sha256-PXFRFApJNvMhiy0bE0PdI3vShlz1FEKIS22C/ohKPec="; + hash = "sha256-KkLPBMD4i8A7FQoX+n3bsvQOCWZn7IobhA7YeRPm5zU="; }; "3.14-aarch64-linux" = getSrcFromPypi { platform = "manylinux_2_27_aarch64"; dist = "cp314"; - hash = "sha256-vkYnxC1Erdf+F9KE71ef+NFZ48tpR/ZDd1jzQXfoeOY="; + hash = "sha256-rUfgckMJeewhY3qkh9TcRkAouOm+JyaPN95pU2x240E="; }; "3.14-aarch64-darwin" = getSrcFromPypi { platform = "macosx_11_0_arm64"; dist = "cp314"; - hash = "sha256-urFo0lVVRkRhvQdzI0hPaQxHHmnOiww5o5+4Gz46i/A="; + hash = "sha256-mLJmcpQ2cnQoc/ZbwDIWgZ/FUyXJnxRlkNAHwBcr/zA="; }; }; in @@ -116,6 +116,8 @@ buildPythonPackage { inherit version; format = "wheel"; + __structuredAttrs = true; + # See https://discourse.nixos.org/t/ofborg-does-not-respect-meta-platforms/27019/6. src = ( srcs."${pythonVersion}-${stdenv.hostPlatform.system}" diff --git a/pkgs/development/python-modules/numpyro/default.nix b/pkgs/development/python-modules/numpyro/default.nix index b25f958cc9b9..2e114b7b5e06 100644 --- a/pkgs/development/python-modules/numpyro/default.nix +++ b/pkgs/development/python-modules/numpyro/default.nix @@ -40,6 +40,11 @@ buildPythonPackage (finalAttrs: { hash = "sha256-sNqllL9nBwXp0kn+HAjvIaHf7LR0UKh9q7DZ20yCr5A="; }; + patches = [ + # Remove usage of xla_pmap_p which was removed in jax 0.10.0 + ./fix-jax-0.10.0-compat.patch + ]; + build-system = [ setuptools ]; dependencies = [ diff --git a/pkgs/development/python-modules/numpyro/fix-jax-0.10.0-compat.patch b/pkgs/development/python-modules/numpyro/fix-jax-0.10.0-compat.patch new file mode 100644 index 000000000000..ad9e937a1e06 --- /dev/null +++ b/pkgs/development/python-modules/numpyro/fix-jax-0.10.0-compat.patch @@ -0,0 +1,20 @@ +diff --git a/numpyro/ops/provenance.py b/numpyro/ops/provenance.py +index 1234567..abcdefg 100644 +--- a/numpyro/ops/provenance.py ++++ b/numpyro/ops/provenance.py +@@ -4,7 +4,7 @@ + import jax + from jax.api_util import debug_info, flatten_fun, shaped_abstractify + from jax.extend.core import Literal +-from jax.extend.core.primitives import call_p, closed_call_p, jit_p, xla_pmap_p ++from jax.extend.core.primitives import call_p, closed_call_p, jit_p + import jax.extend.linear_util as lu + from jax.interpreters.partial_eval import trace_to_jaxpr_dynamic + +@@ -114,7 +114,6 @@ def track_deps_call_rule(eqn, provenance_inputs): + + track_deps_rules[call_p] = track_deps_call_rule +-track_deps_rules[xla_pmap_p] = track_deps_call_rule + + + def track_deps_closed_call_rule(eqn, provenance_inputs): diff --git a/pkgs/development/python-modules/pyoverkiz/default.nix b/pkgs/development/python-modules/pyoverkiz/default.nix index aeb3153acd7c..1375a365b892 100644 --- a/pkgs/development/python-modules/pyoverkiz/default.nix +++ b/pkgs/development/python-modules/pyoverkiz/default.nix @@ -15,14 +15,14 @@ buildPythonPackage (finalAttrs: { pname = "pyoverkiz"; - version = "1.20.1"; + version = "1.20.2"; pyproject = true; src = fetchFromGitHub { owner = "iMicknl"; repo = "python-overkiz-api"; tag = "v${finalAttrs.version}"; - hash = "sha256-PaJ4AC0N82iGTsgP620uI6Iw9l0aHrR7UutWLYxrOYE="; + hash = "sha256-6KcxtHO+mwyKyb2MGGY80M40o2OKwLYPBANipb3ySAY="; }; build-system = [ hatchling ]; diff --git a/pkgs/development/python-modules/python-iso639/default.nix b/pkgs/development/python-modules/python-iso639/default.nix index 88f34647d506..c30777c78f1f 100644 --- a/pkgs/development/python-modules/python-iso639/default.nix +++ b/pkgs/development/python-modules/python-iso639/default.nix @@ -6,16 +6,16 @@ setuptools, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "python-iso639"; - version = "2026.1.31"; + version = "2026.4.20"; pyproject = true; src = fetchFromGitHub { owner = "jacksonllee"; repo = "iso639"; - tag = "v${version}"; - hash = "sha256-mavTbjf57EYUMil3DBOmTZl8WwRW7sjxddb4WuK+YlI="; + tag = "v${finalAttrs.version}"; + hash = "sha256-aXckFcWG8zcP9GELTT5eHnQzklAYG70LyX34fhVGdTo="; }; build-system = [ setuptools ]; @@ -27,10 +27,10 @@ buildPythonPackage rec { ]; meta = { - changelog = "https://github.com/jacksonllee/iso639/blob/${src.tag}/CHANGELOG.md"; + changelog = "https://github.com/jacksonllee/iso639/blob/${finalAttrs.src.tag}/CHANGELOG.md"; description = "ISO 639 language codes, names, and other associated information"; homepage = "https://github.com/jacksonllee/iso639"; license = lib.licenses.asl20; maintainers = with lib.maintainers; [ dotlambda ]; }; -} +}) diff --git a/pkgs/development/python-modules/rlax/default.nix b/pkgs/development/python-modules/rlax/default.nix index 8e106b949c65..45f634ca431f 100644 --- a/pkgs/development/python-modules/rlax/default.nix +++ b/pkgs/development/python-modules/rlax/default.nix @@ -22,18 +22,25 @@ pytestCheckHook, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "rlax"; version = "0.1.8"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "google-deepmind"; repo = "rlax"; - tag = "v${version}"; + tag = "v${finalAttrs.version}"; hash = "sha256-E/zYFd5bfx58FfA3uR7hzRAIs844QzJA8TZTwmwDByk="; }; + # TypeError: clip() got an unexpected keyword argument 'a_min' + postPatch = '' + substituteInPlace rlax/_src/mpo_ops.py \ + --replace-fail "a_min=" "min=" + ''; + build-system = [ flit-core ]; @@ -82,8 +89,8 @@ buildPythonPackage rec { meta = { description = "Library of reinforcement learning building blocks in JAX"; homepage = "https://github.com/deepmind/rlax"; - changelog = "https://github.com/google-deepmind/rlax/releases/tag/${src.tag}"; + changelog = "https://github.com/google-deepmind/rlax/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.asl20; maintainers = with lib.maintainers; [ onny ]; }; -} +}) diff --git a/pkgs/development/python-modules/rq/default.nix b/pkgs/development/python-modules/rq/default.nix index 246d508816a8..8f3c55996e7d 100644 --- a/pkgs/development/python-modules/rq/default.nix +++ b/pkgs/development/python-modules/rq/default.nix @@ -3,6 +3,7 @@ stdenv, fetchFromGitHub, buildPythonPackage, + pythonAtLeast, # build-system hatchling, @@ -22,14 +23,15 @@ buildPythonPackage (finalAttrs: { pname = "rq"; - version = "2.7"; + version = "2.8"; pyproject = true; + __structuredAttrs = true; src = fetchFromGitHub { owner = "rq"; repo = "rq"; tag = "v${finalAttrs.version}"; - hash = "sha256-332K+n3mWf+k7/QvIFJFhuDXqd1t2p8ZVv/l+Y167Bk="; + hash = "sha256-ZO67rsqub9hBUt4XMqrx+P7Dj1dEKD9zp4O5x1Kehe0="; }; build-system = [ hatchling ]; @@ -57,11 +59,24 @@ buildPythonPackage (finalAttrs: { # redisTestHook does not work on darwin-x86_64 doCheck = !(stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64); - disabledTests = lib.optionals stdenv.hostPlatform.isDarwin [ - # PermissionError: [Errno 13] Permission denied: '/tmp/rq-tests.txt' - "test_deleted_jobs_arent_executed" - "test_suspend_worker_execution" - ]; + disabledTests = + lib.optionals + ((pythonAtLeast "3.14") && stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64) + [ + # AssertionError + "test_create_job_with_ttl_should_expire" + "test_execution_order_with_dual_dependency" + "test_execution_order_with_sole_dependency" + "test_sigint_handling" + "test_successful_job_repeat" + "test_suspend_worker_execution" + "test_work" + ] + ++ lib.optionals stdenv.hostPlatform.isDarwin [ + # PermissionError: [Errno 13] Permission denied: '/tmp/rq-tests.txt' + "test_deleted_jobs_arent_executed" + "test_suspend_worker_execution" + ]; pythonImportsCheck = [ "rq" ]; diff --git a/pkgs/development/python-modules/skrl/default.nix b/pkgs/development/python-modules/skrl/default.nix index 0b37d4d0261b..2990385ef1ab 100644 --- a/pkgs/development/python-modules/skrl/default.nix +++ b/pkgs/development/python-modules/skrl/default.nix @@ -37,6 +37,23 @@ buildPythonPackage (finalAttrs: { hash = "sha256-5lkoYAmMIWqK3+E3WxXMWS9zal2DhZkfl30EkrHKpdI="; }; + # Fix Jax 0.10.0 compatibility + # TypeError: clip() got an unexpected keyword argument 'a_min' + postPatch = '' + substituteInPlace skrl/models/jax/gaussian.py \ + --replace-fail \ + "jnp.clip(log_std, a_min=log_std_min, a_max=log_std_max)" \ + "jnp.clip(log_std, min=log_std_min, max=log_std_max)" \ + --replace-fail \ + "jnp.clip(actions, a_min=clip_actions_min, a_max=clip_actions_max)" \ + "jnp.clip(actions, min=clip_actions_min, max=clip_actions_max)" + + substituteInPlace skrl/models/jax/deterministic.py \ + --replace-fail \ + "jnp.clip(actions, a_min=self._d_clip_actions_min, a_max=self._d_clip_actions_max)" \ + "jnp.clip(actions, min=self._d_clip_actions_min, max=self._d_clip_actions_max)" + ''; + build-system = [ setuptools ]; dependencies = [ diff --git a/pkgs/os-specific/darwin/xcode/default.nix b/pkgs/os-specific/darwin/xcode/default.nix index 136b7baeb6d9..8052d58a8eb3 100644 --- a/pkgs/os-specific/darwin/xcode/default.nix +++ b/pkgs/os-specific/darwin/xcode/default.nix @@ -129,6 +129,8 @@ lib.makeExtensible (self: { xcode_26_3_Apple_silicon = requireXcode "26.3_Apple_silicon" "sha256-q2p45zqAZUH6Z1Q3DHbZgpuuFTjZoMPhEfFdeIUvclw="; xcode_26_4 = requireXcode "26.4_Universal" "sha256-0Cg4Ytu2+JOLEqw1ZZoB6hxFXNA2KriTLwLpT8bmA7I="; xcode_26_4_Apple_silicon = requireXcode "26.4_Apple_silicon" "sha256-urkJVqUY6+5z0YiEqCru9M/OneDLAMzdGfOt7i3d1WI="; + xcode_26_4_1 = requireXcode "26.4.1_Universal" "sha256-N9QgPKfZV64gJPlr4r/0gPS0yAgJd3a+qlr0YbzMCU4="; + xcode_26_4_1_Apple_silicon = requireXcode "26.4.1_Apple_silicon" "sha256-8MtGX97e/2+zvY2Et9Jm9eXqVmyr+U02UqsKmffh9hs="; xcode = self."xcode_${ lib.replaceStrings [ "." ] [ "_" ] ( diff --git a/pkgs/servers/home-assistant/custom-components/auth_oidc/package.nix b/pkgs/servers/home-assistant/custom-components/auth_oidc/package.nix index dbbd4ce371eb..196286b30579 100644 --- a/pkgs/servers/home-assistant/custom-components/auth_oidc/package.nix +++ b/pkgs/servers/home-assistant/custom-components/auth_oidc/package.nix @@ -4,34 +4,40 @@ fetchFromGitHub, fetchNpmDeps, aiofiles, - bcrypt, jinja2, joserfc, nodejs, npmHooks, - python-jose, + pytestCheckHook, + pytest-homeassistant-custom-component, + pytest-cov-stub, }: buildHomeAssistantComponent rec { owner = "christaangoossens"; domain = "auth_oidc"; - version = "0.6.5-alpha"; + version = "1.0.2"; src = fetchFromGitHub { owner = "christiaangoossens"; repo = "hass-oidc-auth"; tag = "v${version}"; - hash = "sha256-nclrSO6KmPnwXRPuuFwR6iYHsyfqcelPRGERWVJpdyk="; + hash = "sha256-ZYJD0PVh2E07cdY1a7uxSxdooAMz78HwJpwr4uWofZM="; }; postPatch = '' - rm custom_components/auth_oidc/static/style.css + # Tests import directly from auth_oidc, but the component is installed + # under custom_components.auth_oidc + for f in tests/test_hass_webserver.py tests/test_state_store.py; do + substituteInPlace "$f" \ + --replace-fail "from auth_oidc" "from custom_components.auth_oidc" + done ''; env.npmDeps = fetchNpmDeps { name = "${domain}-npm-deps"; inherit src; - hash = "sha256-i75YeCZVSMFDWzaiDJRTYqQee5I15n9ll0YYX1PXYbA="; + hash = "sha256-R5i4o2VnaXwgX72r6cBJULxSKadkU22vriMMWoMc5As="; }; nativeBuildInputs = [ @@ -41,16 +47,20 @@ buildHomeAssistantComponent rec { dependencies = [ aiofiles - bcrypt jinja2 joserfc - python-jose ]; postBuild = '' npm run css ''; + nativeCheckInputs = [ + pytestCheckHook + pytest-homeassistant-custom-component + pytest-cov-stub + ]; + meta = { changelog = "https://github.com/christiaangoossens/hass-oidc-auth/releases/tag/v${version}"; description = "OpenID Connect authentication provider for Home Assistant"; diff --git a/pkgs/servers/home-assistant/custom-lovelace-modules/custom-sidebar/package.nix b/pkgs/servers/home-assistant/custom-lovelace-modules/custom-sidebar/package.nix index 98edabe58f96..4e56645c71d1 100644 --- a/pkgs/servers/home-assistant/custom-lovelace-modules/custom-sidebar/package.nix +++ b/pkgs/servers/home-assistant/custom-lovelace-modules/custom-sidebar/package.nix @@ -21,8 +21,8 @@ stdenvNoCC.mkDerivation (finalAttrs: { pnpmDeps = fetchPnpmDeps { inherit (finalAttrs) pname version src; - fetcherVersion = 1; - hash = "sha256-VbmbqTwuXfJQVSaQHGVwIZJf7350HsH+TGeVCtCXL38="; + fetcherVersion = 3; + hash = "sha256-gUVETXrl5rcXvn0YeKLfM+eErUpMxCuVlAOoyqQkLXs="; }; nativeBuildInputs = [ diff --git a/pkgs/servers/web-apps/discourse/default.nix b/pkgs/servers/web-apps/discourse/default.nix index 061a2fe543c3..5c572d71511d 100644 --- a/pkgs/servers/web-apps/discourse/default.nix +++ b/pkgs/servers/web-apps/discourse/default.nix @@ -305,8 +305,8 @@ let pname = "discourse-assets"; inherit version src; pnpm = pnpm; - fetcherVersion = 1; - hash = "sha256-/vPNHEB/ZuHWnSLqfz2NM/scSRH9wzotzjunDAw5Imc="; + fetcherVersion = 3; + hash = "sha256-xft/2x0iti0yJ53uI9q2+FSvKgWWfKQzlMlPFz3RZsE="; }; nativeBuildInputs = runtimeDeps ++ [ diff --git a/pkgs/tools/package-management/lix/default.nix b/pkgs/tools/package-management/lix/default.nix index 0f59bb4e9d33..9ef54924323f 100644 --- a/pkgs/tools/package-management/lix/default.nix +++ b/pkgs/tools/package-management/lix/default.nix @@ -20,6 +20,7 @@ nixpkgs-reviewFull, nil, nix-direnv, + nix-du, nix-fast-build, haskell, nix-serve-ng, @@ -127,6 +128,10 @@ let nix = self.lix; }; + nix-du = nix-du.override { + nix = self.lix; + }; + nix-eval-jobs = self.callPackage (callPackage ./common-nix-eval-jobs.nix nix-eval-jobs-args) { stdenv = lixStdenv; }; diff --git a/pkgs/top-level/darwin-packages.nix b/pkgs/top-level/darwin-packages.nix index fa9b60790eff..b508524c4d61 100644 --- a/pkgs/top-level/darwin-packages.nix +++ b/pkgs/top-level/darwin-packages.nix @@ -162,6 +162,8 @@ makeScopeWithSplicing' { xcode_26_3_Apple_silicon xcode_26_4 xcode_26_4_Apple_silicon + xcode_26_4_1 + xcode_26_4_1_Apple_silicon xcode requireXcode ;