Compare commits

...

14 Commits

Author SHA1 Message Date
chn
f2db4d060c remove patches no longer useful 2025-05-11 08:56:10 +08:00
chn
a9b151a3df generate patch 2025-05-11 08:47:11 +08:00
chn
6ff3bce5ce update nvidia beta 2025-04-02 11:39:36 +08:00
Kiskae
022a396dc9 linuxPackages.nvidiaPackages.beta: 565.57.01 -> 570.86.16 2025-02-26 10:09:07 +08:00
chn
cf12438c52 fix libvirt 2025-02-10 23:32:36 +08:00
chn
6846899244 open-webui: update 2025-02-09 18:33:40 +08:00
chn
737a5146eb fix pytorch 2025-02-04 20:55:52 +08:00
chn
245c87b41f fix paperwork 2025-01-23 20:19:21 +08:00
chn
24e16d8b21 fix peertube 2025-01-08 10:56:37 +08:00
chn
94a86525c9 fix folly 2024-12-18 15:21:37 +08:00
chn
85dd45440b Revert "vscode 1.95.3"
This reverts commit bcf6828551.
2024-12-16 10:28:32 +08:00
chn
468b2d57c8 Revert "vscode: 1.95.3 -> 1.96.0"
This reverts commit 7d108073e4.
2024-12-16 10:28:18 +08:00
DontEatOreo
7d108073e4 vscode: 1.95.3 -> 1.96.0
Changelog: https://github.com/microsoft/vscode/releases/tag/1.96.0
Diff: https://github.com/microsoft/vscode/compare/1.95.3...1.96.0
2024-12-16 10:23:23 +08:00
Josh Spicer
bcf6828551 vscode 1.95.3 2024-12-16 10:22:36 +08:00
13 changed files with 891 additions and 95 deletions

686
diff.patch Normal file
View File

@@ -0,0 +1,686 @@
diff --git a/lib/systems/architectures.nix b/lib/systems/architectures.nix
index df8ff438b17b..a31b25772f29 100644
--- a/lib/systems/architectures.nix
+++ b/lib/systems/architectures.nix
@@ -11,12 +11,13 @@ rec {
x86-64-v3 = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" "avx2" "fma" ];
x86-64-v4 = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" "avx2" "avx512" "fma" ];
# x86_64 Intel
- nehalem = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" ];
- westmere = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" ];
- sandybridge = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" ];
- ivybridge = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" ];
- haswell = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" "avx2" "fma" ];
- broadwell = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" "avx2" "fma" ];
+ nehalem = [ "sse3" "ssse3" "sse4_1" "sse4_2" ];
+ westmere = [ "sse3" "ssse3" "sse4_1" "sse4_2" ];
+ silvermont = [ "sse3" "ssse3" "sse4_1" "sse4_2" ];
+ sandybridge = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" ];
+ ivybridge = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" ];
+ haswell = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" "avx2" "fma" ];
+ broadwell = [ "sse3" "ssse3" "sse4_1" "sse4_2" "avx" "avx2" "fma" ];
skylake = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" "avx2" "fma" ];
skylake-avx512 = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" "avx2" "avx512" "fma" ];
cannonlake = [ "sse3" "ssse3" "sse4_1" "sse4_2" "aes" "avx" "avx2" "avx512" "fma" ];
diff --git a/lib/systems/examples.nix b/lib/systems/examples.nix
index 8433042838dc..d41db93aa684 100644
--- a/lib/systems/examples.nix
+++ b/lib/systems/examples.nix
@@ -320,6 +320,8 @@ rec {
libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain
};
+ mingwW64Static = mingwW64 // { isStatic = true; };
+
ucrt64 = {
config = "x86_64-w64-mingw32";
libc = "ucrt"; # This distinguishes the mingw (non posix) toolchain
diff --git a/nixos/modules/programs/ccache.nix b/nixos/modules/programs/ccache.nix
index bfcbe39b3ff0..5cfe40b92bf2 100644
--- a/nixos/modules/programs/ccache.nix
+++ b/nixos/modules/programs/ccache.nix
@@ -60,14 +60,20 @@ in {
# target configuration
(lib.mkIf (cfg.packageNames != []) {
nixpkgs.overlays = [
- (self: super: lib.genAttrs cfg.packageNames (pn: super.${pn}.override { stdenv = builtins.trace "with ccache: ${pn}" self.ccacheStdenv; }))
+ (self: super: lib.genAttrs cfg.packageNames (pn: super.${pn}.override { stdenv = builtins.trace "with ccache: ${pn}" self.ccacheStdenv; }))];})
+ (lib.mkIf cfg.enable {
+ nixpkgs.overlays = [
(self: super: {
ccacheWrapper = super.ccacheWrapper.override {
extraConfig = ''
- export CCACHE_COMPRESS=1
+ export CCACHE_NOCOMPRESS=true
export CCACHE_DIR="${cfg.cacheDir}"
export CCACHE_UMASK=007
+ export CCACHE_MAXSIZE=100G
+ export CCACHE_SLOPPINESS=random_seed,time_macros
+ export CCACHE_NOHASHDIR=true
+ export CCACHE_BASEDIR="$NIX_BUILD_TOP"
if [ ! -d "$CCACHE_DIR" ]; then
echo "====="
echo "Directory '$CCACHE_DIR' does not exist"
diff --git a/nixos/modules/services/databases/mysql.nix b/nixos/modules/services/databases/mysql.nix
index 412fe4836cd3..27f37fc9d06a 100644
--- a/nixos/modules/services/databases/mysql.nix
+++ b/nixos/modules/services/databases/mysql.nix
@@ -396,8 +396,8 @@ in
then
# While MariaDB comes with a 'mysql' super user account since 10.4.x, MySQL does not
# Since we don't want to run this service as 'root' we need to ensure the account exists on first run
- ( echo "CREATE USER IF NOT EXISTS '${cfg.user}'@'localhost' IDENTIFIED WITH ${if isMariaDB then "unix_socket" else "auth_socket"};"
- echo "GRANT ALL PRIVILEGES ON *.* TO '${cfg.user}'@'localhost' WITH GRANT OPTION;"
+ ( echo "CREATE USER IF NOT EXISTS '${cfg.user}' IDENTIFIED WITH ${if isMariaDB then "unix_socket" else "auth_socket"};"
+ echo "GRANT ALL PRIVILEGES ON *.* TO '${cfg.user}' WITH GRANT OPTION;"
) | ${cfg.package}/bin/mysql -u ${superUser} -N
${lib.concatMapStrings (database: ''
diff --git a/nixos/modules/services/web-servers/nginx/default.nix b/nixos/modules/services/web-servers/nginx/default.nix
index 145c86028de8..5a45130f1a36 100644
--- a/nixos/modules/services/web-servers/nginx/default.nix
+++ b/nixos/modules/services/web-servers/nginx/default.nix
@@ -105,6 +105,14 @@ let
proxy_set_header X-Forwarded-Server $host;
'';
+ recommendedProxyConfigNoHost = pkgs.writeText "nginx-recommended-proxy-headers-no-host.conf" ''
+ proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header X-Forwarded-Proto $scheme;
+ proxy_set_header X-Forwarded-Host $host;
+ proxy_set_header X-Forwarded-Server $host;
+ '';
+
proxyCachePathConfig = concatStringsSep "\n" (mapAttrsToList (name: proxyCachePath: ''
proxy_cache_path ${concatStringsSep " " [
"/var/cache/nginx/${name}"
@@ -455,6 +463,7 @@ let
${optionalString (config.return != null) "return ${toString config.return};"}
${config.extraConfig}
${optionalString (config.proxyPass != null && config.recommendedProxySettings) "include ${recommendedProxyConfig};"}
+ ${optionalString (config.proxyPass != null && config.recommendedProxySettingsNoHost) "include ${recommendedProxyConfigNoHost};"}
${mkBasicAuth "sublocation" config}
}
'') (sortProperties (mapAttrsToList (k: v: v // { location = k; }) locations)));
diff --git a/nixos/modules/services/web-servers/nginx/location-options.nix b/nixos/modules/services/web-servers/nginx/location-options.nix
index da55dc92f596..8bcb043953c4 100644
--- a/nixos/modules/services/web-servers/nginx/location-options.nix
+++ b/nixos/modules/services/web-servers/nginx/location-options.nix
@@ -134,5 +134,11 @@ with lib;
Enable recommended proxy settings.
'';
};
+
+ recommendedProxySettingsNoHost = mkOption {
+ type = types.bool;
+ default = false;
+ description = ''recommendedProxySettingsNoHost'';
+ };
};
}
diff --git a/pkgs/applications/audio/youtube-music/default.nix b/pkgs/applications/audio/youtube-music/default.nix
index b46e11a35e8d..faca81bfe9a7 100644
--- a/pkgs/applications/audio/youtube-music/default.nix
+++ b/pkgs/applications/audio/youtube-music/default.nix
@@ -67,7 +67,7 @@ stdenv.mkDerivation (finalAttrs: {
postFixup = lib.optionalString (!stdenv.hostPlatform.isDarwin) ''
makeWrapper ${electron}/bin/electron $out/bin/youtube-music \
--add-flags $out/share/lib/youtube-music/resources/app.asar \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
--set-default ELECTRON_FORCE_IS_PACKAGED 1 \
--set-default ELECTRON_IS_DEV 0 \
--inherit-argv0
diff --git a/pkgs/applications/editors/vscode/generic.nix b/pkgs/applications/editors/vscode/generic.nix
index 352c25fe1720..6a23b4c2aeb5 100644
--- a/pkgs/applications/editors/vscode/generic.nix
+++ b/pkgs/applications/editors/vscode/generic.nix
@@ -211,7 +211,7 @@ in
"--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ libdbusmenu ]}"}
# Add gio to PATH so that moving files to the trash works when not using a desktop environment
--prefix PATH : ${glib.bin}/bin
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}"
--add-flags ${lib.escapeShellArg commandLineArgs}
)
'';
diff --git a/pkgs/applications/editors/vscode/with-extensions.nix b/pkgs/applications/editors/vscode/with-extensions.nix
index 25c97f52d765..000b84fa7df1 100644
--- a/pkgs/applications/editors/vscode/with-extensions.nix
+++ b/pkgs/applications/editors/vscode/with-extensions.nix
@@ -1,5 +1,7 @@
{ lib, stdenv, runCommand, buildEnv, vscode, vscode-utils, makeWrapper, writeTextFile
-, vscodeExtensions ? [] }:
+, vscodeExtensions ? []
+, extraFlags ? ""
+}:
/*
`vscodeExtensions`
@@ -58,8 +60,7 @@ let
};
extensionsFlag = ''
- --add-flags "--extensions-dir ${combinedExtensionsDrv}/share/vscode/extensions"
- '';
+ --add-flags "--extensions-dir ${combinedExtensionsDrv}/share/vscode/extensions" '' + extraFlags;
in
runCommand "${wrappedPkgName}-with-extensions-${wrappedPkgVersion}" {
diff --git a/pkgs/applications/misc/whalebird/default.nix b/pkgs/applications/misc/whalebird/default.nix
index e46a1af85c82..a99d4c047ceb 100644
--- a/pkgs/applications/misc/whalebird/default.nix
+++ b/pkgs/applications/misc/whalebird/default.nix
@@ -96,7 +96,7 @@ stdenv.mkDerivation rec {
makeWrapper "${electron}/bin/electron" "$out/bin/whalebird" \
--add-flags "$out/opt/Whalebird/resources/app.asar" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}"
runHook postInstall
'';
diff --git a/pkgs/applications/networking/browsers/chromium/common.nix b/pkgs/applications/networking/browsers/chromium/common.nix
index c0a661a86038..c48ab3ef8158 100644
--- a/pkgs/applications/networking/browsers/chromium/common.nix
+++ b/pkgs/applications/networking/browsers/chromium/common.nix
@@ -60,10 +60,14 @@
, libgcrypt ? null # cupsSupport
, systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd
, systemd
+
+, enableCcache ? false
+, ccacheStdenv ? null
}:
buildFun:
-
+let originalStdenv = stdenv;
+in let stdenv = if enableCcache then ccacheStdenv.override { stdenv = originalStdenv; } else originalStdenv; in
let
python3WithPackages = python3.pythonOnBuildForHost.withPackages(ps: with ps; [
ply jinja2 setuptools
@@ -125,7 +129,7 @@ let
# There currently isn't a (much) more concise way to get a stdenv
# that uses lld as its linker without bootstrapping pkgsLLVM; see
# https://github.com/NixOS/nixpkgs/issues/142901
- buildPlatformLlvmStdenv =
+ originalBuildPlatformLlvmStdenv =
let
llvmPackages = pkgsBuildBuild.rustc.llvmPackages;
in
@@ -133,6 +137,9 @@ let
(llvmPackages.stdenv.cc.override {
inherit (llvmPackages) bintools;
});
+ buildPlatformLlvmStdenv =
+ if enableCcache then ccacheStdenv.override { stdenv = originalBuildPlatformLlvmStdenv; }
+ else originalBuildPlatformLlvmStdenv;
chromiumRosettaStone = {
cpu = platform:
diff --git a/pkgs/applications/networking/browsers/chromium/default.nix b/pkgs/applications/networking/browsers/chromium/default.nix
index 73ce63d6f8bc..546f45dbf8fd 100644
--- a/pkgs/applications/networking/browsers/chromium/default.nix
+++ b/pkgs/applications/networking/browsers/chromium/default.nix
@@ -19,6 +19,9 @@
, commandLineArgs ? ""
, pkgsBuildBuild
, pkgs
+
+, enableCcache ? config.enableCcache or false
+, ccacheStdenv ? null
}:
let
@@ -48,6 +51,7 @@ let
inherit chromiumVersionAtLeast versionRange;
inherit proprietaryCodecs
cupsSupport pulseSupport ungoogled;
+ inherit enableCcache ccacheStdenv;
gnChromium = buildPackages.gn.overrideAttrs (oldAttrs: {
version = if (upstream-info.deps.gn ? "version") then upstream-info.deps.gn.version else "0";
src = fetchgit {
@@ -124,7 +128,7 @@ in stdenv.mkDerivation {
mkdir -p "$out/bin"
makeWrapper "${browserBinary}" "$out/bin/chromium" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
--add-flags ${lib.escapeShellArg commandLineArgs}
ed -v -s "$out/bin/chromium" << EOF
diff --git a/pkgs/applications/networking/instant-messengers/discord/linux.nix b/pkgs/applications/networking/instant-messengers/discord/linux.nix
index a7c41de91166..ef38b4c23852 100644
--- a/pkgs/applications/networking/instant-messengers/discord/linux.nix
+++ b/pkgs/applications/networking/instant-messengers/discord/linux.nix
@@ -168,7 +168,7 @@ stdenv.mkDerivation rec {
wrapProgramShell $out/opt/${binaryName}/${binaryName} \
"''${gappsWrapperArgs[@]}" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland --enable-features=WaylandWindowDecorations}}" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
${lib.strings.optionalString withTTS "--add-flags \"--enable-speech-dispatcher\""} \
--prefix XDG_DATA_DIRS : "${gtk3}/share/gsettings-schemas/${gtk3.name}/" \
--prefix LD_LIBRARY_PATH : ${libPath}:$out/opt/${binaryName} \
diff --git a/pkgs/applications/networking/instant-messengers/element/element-desktop.nix b/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
index e2c1c8da00ad..ed98829d6486 100644
--- a/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
+++ b/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
@@ -109,7 +109,7 @@ stdenv.mkDerivation (finalAttrs: builtins.removeAttrs pinData [ "hashes" ] // {
makeWrapper '${electron}/bin/electron' "$out/bin/${executableName}" \
--set LD_PRELOAD ${sqlcipher}/lib/libsqlcipher.so \
--add-flags "$out/share/element/electron" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
--add-flags ${lib.escapeShellArg commandLineArgs}
runHook postInstall
diff --git a/pkgs/applications/networking/instant-messengers/slack/default.nix b/pkgs/applications/networking/instant-messengers/slack/default.nix
index b98f5d8020a0..454388f5746a 100644
--- a/pkgs/applications/networking/instant-messengers/slack/default.nix
+++ b/pkgs/applications/networking/instant-messengers/slack/default.nix
@@ -174,7 +174,7 @@ let
makeWrapper $out/lib/slack/slack $out/bin/slack \
--prefix XDG_DATA_DIRS : $GSETTINGS_SCHEMAS_PATH \
--suffix PATH : ${lib.makeBinPath [xdg-utils]} \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations,WebRTCPipeWireCapturer}}"
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations,WebRTCPipeWireCapturer --enable-wayland-ime}}"
# Fix the desktop link
substituteInPlace $out/share/applications/slack.desktop \
diff --git a/pkgs/applications/office/libreoffice/default.nix b/pkgs/applications/office/libreoffice/default.nix
index e9a97025455c..2d21ea5c4d59 100644
--- a/pkgs/applications/office/libreoffice/default.nix
+++ b/pkgs/applications/office/libreoffice/default.nix
@@ -149,10 +149,17 @@
, qttools ? null
, solid ? null
, sonnet ? null
+
+, config
+, enableCcache ? config.enableCcache or false
+, ccacheStdenv
}:
assert builtins.elem variant [ "fresh" "still" "collabora" ];
+let originalStdenv = stdenv; in
+let stdenv = if enableCcache then ccacheStdenv.override { stdenv = originalStdenv; } else originalStdenv; in
+
let
inherit (lib)
flatten flip
@@ -287,9 +294,10 @@ in stdenv.mkDerivation (finalAttrs: {
substituteInPlace configure.ac --replace-fail \
'GPGMEPP_CFLAGS=-I/usr/include/gpgme++' \
'GPGMEPP_CFLAGS=-I${gpgme.dev}/include/gpgme++'
-
# Fix for Python 3.12
substituteInPlace configure.ac --replace-fail distutils.sysconfig sysconfig
+ '' + optionalString (stdenv.hostPlatform.gcc.arch or null != null) ''
+ sed -e '/CPPUNIT_TEST(testDubiousArrayFormulasFODS);/d' -i './sc/qa/unit/functions_array.cxx'
'';
nativeBuildInputs = [
diff --git a/pkgs/applications/office/paperwork/paperwork-backend.nix b/pkgs/applications/office/paperwork/paperwork-backend.nix
index 4460e50ab624..e638a90131d7 100644
--- a/pkgs/applications/office/paperwork/paperwork-backend.nix
+++ b/pkgs/applications/office/paperwork/paperwork-backend.nix
@@ -23,6 +23,7 @@
, libreoffice
, unittestCheckHook
, setuptools-scm
+, stdenv
}:
buildPythonPackage rec {
@@ -83,6 +84,8 @@ buildPythonPackage rec {
export HOME=$TMPDIR
'';
+ doCheck = stdenv.hostPlatform.gcc.arch or null == null;
+
meta = with lib; {
description = "Backend part of Paperwork (Python API, no UI)";
homepage = "https://openpaper.work";
diff --git a/pkgs/by-name/bi/bitwarden-desktop/package.nix b/pkgs/by-name/bi/bitwarden-desktop/package.nix
index f027ca5ab960..3763008e8642 100644
--- a/pkgs/by-name/bi/bitwarden-desktop/package.nix
+++ b/pkgs/by-name/bi/bitwarden-desktop/package.nix
@@ -161,7 +161,7 @@ in buildNpmPackage rec {
makeWrapper '${lib.getExe electron}' "$out/bin/bitwarden" \
--add-flags $out/opt/Bitwarden/resources/app.asar \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
--set-default ELECTRON_IS_DEV 0 \
--inherit-argv0
diff --git a/pkgs/by-name/fo/folly/package.nix b/pkgs/by-name/fo/folly/package.nix
index 3d84de4ea5c7..c3c4a86abc9e 100644
--- a/pkgs/by-name/fo/folly/package.nix
+++ b/pkgs/by-name/fo/folly/package.nix
@@ -157,6 +157,12 @@ stdenv.mkDerivation (finalAttrs: {
++ lib.optionals stdenv.hostPlatform.isDarwin [
"buffered_atomic_test.BufferedAtomic.singleThreadUnguardedAccess"
]
+ ++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null) [
+ "io_async_hh_wheel_timer_test.HHWheelTimerTest.ReschedTest"
+ "io_async_hh_wheel_timer_test.HHWheelTimerTest.CancelTimeout"
+ "io_async_hh_wheel_timer_test.HHWheelTimerTest.DeleteWheelInTimeout"
+ "io_async_hh_wheel_timer_test.HHWheelTimerTest.FireOnce"
+ ]
)
)
}
diff --git a/pkgs/by-name/fr/framesh/package.nix b/pkgs/by-name/fr/framesh/package.nix
index b4673ca4cff9..ae29660ff347 100644
--- a/pkgs/by-name/fr/framesh/package.nix
+++ b/pkgs/by-name/fr/framesh/package.nix
@@ -21,7 +21,7 @@ appimageTools.wrapType2 {
install -m 444 -D ${appimageContents}/frame.png \
$out/share/icons/hicolor/512x512/apps/frame.png
wrapProgram "$out/bin/${pname}" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland --enable-features=WaylandWindowDecorations}}"
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland --enable-features=WaylandWindowDecorations --enable-wayland-ime}}"
substituteInPlace $out/share/applications/frame.desktop \
--replace 'Exec=AppRun' 'Exec=${pname}'
diff --git a/pkgs/by-name/gl/glaze/package.nix b/pkgs/by-name/gl/glaze/package.nix
index a36c79d89b39..2ac4ad856fab 100644
--- a/pkgs/by-name/gl/glaze/package.nix
+++ b/pkgs/by-name/gl/glaze/package.nix
@@ -8,13 +8,13 @@
stdenv.mkDerivation (final: {
pname = "glaze";
- version = "4.0.0";
+ version = "4.0.1";
src = fetchFromGitHub {
owner = "stephenberry";
repo = "glaze";
rev = "v${final.version}";
- hash = "sha256-zaGKYEnYTyAhtP0Hywxp8Y33wvjB1RkEoOGF41CaVnY";
+ hash = "sha256-gQfRz7b1kbn1AoKUNG62LBynmJNbDTXzPXaX6kDCjVw=";
};
nativeBuildInputs = [ cmake ];
diff --git a/pkgs/by-name/go/google-chrome/package.nix b/pkgs/by-name/go/google-chrome/package.nix
index 930b313ccc8b..7b96d74e2c62 100644
--- a/pkgs/by-name/go/google-chrome/package.nix
+++ b/pkgs/by-name/go/google-chrome/package.nix
@@ -248,6 +248,7 @@ let
--suffix PATH : "${lib.makeBinPath [ xdg-utils ]}" \
--prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH:${addDriverRunpath.driverLink}/share" \
--set CHROME_WRAPPER "google-chrome-$dist" \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime}}" \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \
--add-flags "--simulate-outdated-no-au='Tue, 31 Dec 2099 23:59:59 GMT'" \
--add-flags ${lib.escapeShellArg commandLineArgs}
diff --git a/pkgs/by-name/gs/gsl/package.nix b/pkgs/by-name/gs/gsl/package.nix
index aeb95476b2b6..8a71649cc16a 100644
--- a/pkgs/by-name/gs/gsl/package.nix
+++ b/pkgs/by-name/gs/gsl/package.nix
@@ -31,7 +31,9 @@ stdenv.mkDerivation rec {
env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.hostPlatform.isx86_64 "-mno-fma";
# https://lists.gnu.org/archive/html/bug-gsl/2015-11/msg00012.html
- doCheck = stdenv.hostPlatform.system != "i686-linux";
+ doCheck = stdenv.hostPlatform.system != "i686-linux"
+ # float precision issue
+ && (!stdenv.hostPlatform.avx512Support);
meta = {
description = "GNU Scientific Library, a large numerical library";
diff --git a/pkgs/by-name/li/libinsane/package.nix b/pkgs/by-name/li/libinsane/package.nix
index a83268ca31ad..f865963aa188 100644
--- a/pkgs/by-name/li/libinsane/package.nix
+++ b/pkgs/by-name/li/libinsane/package.nix
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
buildInputs = [ sane-backends glib ];
- nativeCheckInputs = [ cunit valgrind ];
+ nativeCheckInputs = [ cunit ] ++ lib.optional (stdenv.hostPlatform.gcc.arch or null == null) valgrind;
doCheck = true;
diff --git a/pkgs/by-name/op/openmpi/package.nix b/pkgs/by-name/op/openmpi/package.nix
index 7fcca51c739e..50e823d9a2c2 100644
--- a/pkgs/by-name/op/openmpi/package.nix
+++ b/pkgs/by-name/op/openmpi/package.nix
@@ -36,6 +36,7 @@
# note that opempi fails to build with AVX disabled, meaning that everything
# up to AVX is enabled by default.
avxOptions ? { },
+ enableSubstitute ? stdenv.isLinux
}:
stdenv.mkDerivation (finalAttrs: {
@@ -219,7 +220,7 @@ stdenv.mkDerivation (finalAttrs: {
# we currently don't perform these substitutions on other platforms,
# until a Darwin user will care enough about this cross platform
# related substitution.
- lib.optionalString stdenv.hostPlatform.isLinux ''
+ lib.optionalString enableSubstitute ''
substituteInPlace "''${!outputDev}/share/openmpi/${part1}${part2}-wrapper-data.txt" \
--replace-fail \
compiler=${lib.elemAt wrapperDataSubstitutions.${part2} 0} \
diff --git a/pkgs/by-name/ra/rapidjson/package.nix b/pkgs/by-name/ra/rapidjson/package.nix
index 09707dc75b9a..18bb0cb78b7e 100644
--- a/pkgs/by-name/ra/rapidjson/package.nix
+++ b/pkgs/by-name/ra/rapidjson/package.nix
@@ -64,7 +64,9 @@ stdenv.mkDerivation (finalAttrs: {
(lib.cmakeFeature "CMAKE_CXX_FLAGS_RELEASE" "-Wno-error")
];
- doCheck = !(stdenv.hostPlatform.isStatic || stdenv.hostPlatform.isDarwin);
+ doCheck = !(stdenv.hostPlatform.isStatic || stdenv.hostPlatform.isDarwin)
+ # some vargrind failed
+ && (stdenv.hostPlatform.gcc.arch or null == null);
nativeCheckInputs = [
valgrind
diff --git a/pkgs/by-name/re/redis/package.nix b/pkgs/by-name/re/redis/package.nix
index b39d9258ae64..4961d3656b1a 100644
--- a/pkgs/by-name/re/redis/package.nix
+++ b/pkgs/by-name/re/redis/package.nix
@@ -79,6 +79,12 @@ stdenv.mkDerivation (finalAttrs: {
--timeout 2000 \
--clients $NIX_BUILD_CORES \
--tags -leaks \
+ ''
+ # always failed on my machine, not sure why
+ + (lib.optionalString (stdenv.hostPlatform.gcc.arch or null != null) ''
+ --skipunit integration/aof-multi-part \
+ '')
+ + ''
--skipunit integration/failover # flaky and slow
runHook postCheck
diff --git a/pkgs/by-name/sp/spotify/linux.nix b/pkgs/by-name/sp/spotify/linux.nix
index b295d6fa5083..5d638876d2da 100644
--- a/pkgs/by-name/sp/spotify/linux.nix
+++ b/pkgs/by-name/sp/spotify/linux.nix
@@ -179,7 +179,7 @@ stdenv.mkDerivation {
''} \
--prefix LD_LIBRARY_PATH : "$librarypath" \
--prefix PATH : "${zenity}/bin" \
- --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland}}"
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--enable-features=UseOzonePlatform --ozone-platform=wayland --enable-wayland-ime}}"
runHook postFixup
'';
diff --git a/pkgs/development/libraries/lib2geom/default.nix b/pkgs/development/libraries/lib2geom/default.nix
index eedb433e61be..a11e3b9572c2 100644
--- a/pkgs/development/libraries/lib2geom/default.nix
+++ b/pkgs/development/libraries/lib2geom/default.nix
@@ -82,6 +82,7 @@ stdenv.mkDerivation rec {
# https://gitlab.com/inkscape/lib2geom/-/issues/63
"elliptical-arc-test"
]
+ ++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null) [ "elliptical-arc-test" ]
++ lib.optionals stdenv.hostPlatform.isMusl [
# Fails due to rounding differences
# https://gitlab.com/inkscape/lib2geom/-/issues/70
diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix
index b1e565266f86..8e4ba2240bb2 100644
--- a/pkgs/development/libraries/libvirt/default.nix
+++ b/pkgs/development/libraries/libvirt/default.nix
@@ -356,6 +356,7 @@ stdenv.mkDerivation rec {
--replace 'ON_BOOT="start"' 'ON_BOOT=''${ON_BOOT:-start}' \
--replace 'ON_SHUTDOWN="suspend"' 'ON_SHUTDOWN=''${ON_SHUTDOWN:-suspend}' \
--replace 'PARALLEL_SHUTDOWN=0' 'PARALLEL_SHUTDOWN=''${PARALLEL_SHUTDOWN:-0}' \
+ --replace 'SHUTDOWN_TIMEOUT=300' 'SHUTDOWN_TIMEOUT=''${SHUTDOWN_TIMEOUT:-300}' \
--replace "$out/bin" '${gettext}/bin' \
--replace 'lock/subsys' 'lock' \
--replace 'gettext.sh' 'gettext.sh
diff --git a/pkgs/development/libraries/opencolorio/default.nix b/pkgs/development/libraries/opencolorio/default.nix
index 4bc1f410872e..c056dc51f34d 100644
--- a/pkgs/development/libraries/opencolorio/default.nix
+++ b/pkgs/development/libraries/opencolorio/default.nix
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
++ lib.optional (!buildApps) "-DOCIO_BUILD_APPS=OFF";
# precision issues on non-x86
- doCheck = stdenv.hostPlatform.isx86_64;
+ doCheck = stdenv.hostPlatform.isx86_64 && (stdenv.hostPlatform.gcc.arch or null == null);
# Tends to fail otherwise.
enableParallelChecking = false;
diff --git a/pkgs/development/python-modules/numcodecs/default.nix b/pkgs/development/python-modules/numcodecs/default.nix
index 403d5ea16051..9ed43853472c 100644
--- a/pkgs/development/python-modules/numcodecs/default.nix
+++ b/pkgs/development/python-modules/numcodecs/default.nix
@@ -57,6 +57,11 @@ buildPythonPackage rec {
importlib-metadata
];
+ # not sure why
+ # use if ... then ... else instead of lib.optionals, to prevent rebuild of generic packages
+ disabledTests = if stdenv.hostPlatform.gcc.arch or null != null && !stdenv.hostPlatform.avx2Support
+ then [ "test_encode_decode" "test_partial_decode" ] else null;
+
# https://github.com/NixOS/nixpkgs/issues/255262
pytestFlagsArray = [ "$out/${python.sitePackages}/numcodecs" ];
diff --git a/pkgs/development/python-modules/opensearch-py/default.nix b/pkgs/development/python-modules/opensearch-py/default.nix
index 0914a8ca6701..f580850a184c 100644
--- a/pkgs/development/python-modules/opensearch-py/default.nix
+++ b/pkgs/development/python-modules/opensearch-py/default.nix
@@ -2,6 +2,7 @@
lib,
buildPythonPackage,
fetchFromGitHub,
+ stdenv,
# build-system
setuptools,
@@ -74,7 +75,8 @@ buildPythonPackage rec {
# finds our ca-bundle, but expects something else (/path/to/clientcert/dir or None)
"test_ca_certs_ssl_cert_dir"
"test_no_ca_certs"
- ];
+ ] ++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null)
+ [ "test_basicauth_in_request_session" "test_callable_in_request_session" ];
meta = {
description = "Python low-level client for OpenSearch";
diff --git a/pkgs/development/python-modules/scipy/default.nix b/pkgs/development/python-modules/scipy/default.nix
index e5b2db20a1c0..9397735b0004 100644
--- a/pkgs/development/python-modules/scipy/default.nix
+++ b/pkgs/development/python-modules/scipy/default.nix
@@ -148,7 +148,10 @@ buildPythonPackage {
"hyp2f1_test_case47"
"hyp2f1_test_case3"
"test_uint64_max"
- ];
+ ]
+ # some float precision issue
+ ++ lib.optionals stdenv.hostPlatform.avx2Support [ "hyp2f1_test_case42" ]
+ ++ lib.optionals stdenv.hostPlatform.avx512Support [ "test_equal_bounds" ];
doCheck = !(stdenv.hostPlatform.isx86_64 && stdenv.hostPlatform.isDarwin);
diff --git a/pkgs/development/python-modules/torch/default.nix b/pkgs/development/python-modules/torch/default.nix
index b4b3379ae117..42fdd0948edf 100644
--- a/pkgs/development/python-modules/torch/default.nix
+++ b/pkgs/development/python-modules/torch/default.nix
@@ -569,7 +569,7 @@ buildPythonPackage rec {
# Tests take a long time and may be flaky, so just sanity-check imports
doCheck = false;
- pythonImportsCheck = [ "torch" ];
+ pythonImportsCheck = lib.optional (python.pythonVersion != "3.11" || !cudaSupport) "torch";
nativeCheckInputs = [
hypothesis
diff --git a/pkgs/development/rocm-modules/6/llvm/stage-2/libcxxabi.nix b/pkgs/development/rocm-modules/6/llvm/stage-2/libcxxabi.nix
index e15ec777ff61..78441d28f1fc 100644
--- a/pkgs/development/rocm-modules/6/llvm/stage-2/libcxxabi.nix
+++ b/pkgs/development/rocm-modules/6/llvm/stage-2/libcxxabi.nix
@@ -1,6 +1,7 @@
{ stdenv
, callPackage
, rocmUpdateScript
+, lib
}:
callPackage ../base.nix rec {
@@ -34,4 +35,10 @@ callPackage ../base.nix rec {
"-DLIBCXX_INSTALL_LIBRARY=OFF"
"-DLIBCXX_INSTALL_HEADERS=OFF"
];
+
+ extraPostPatch = lib.optionalString (stdenv.hostPlatform.gcc.arch or null == "znver4") ''
+ # somehow it failed
+ rm ../libcxxabi/test/guard_threaded_test.pass.cpp
+ '';
+
}
diff --git a/pkgs/development/web/nodejs/nodejs.nix b/pkgs/development/web/nodejs/nodejs.nix
index 8881d608c95b..20903dbf28e4 100644
--- a/pkgs/development/web/nodejs/nodejs.nix
+++ b/pkgs/development/web/nodejs/nodejs.nix
@@ -332,6 +332,10 @@ let
"test-fs-readv"
"test-fs-readv-sync"
"test-vm-memleak"
+ ] ++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null) [
+ # failed if set priority to nix daemon
+ # also failed if use `nix build`, but not fail when use `nix-build`, not sure why
+ "test-os"
])}"
];
diff --git a/pkgs/kde/default.nix b/pkgs/kde/default.nix
index f5092b6da53d..220aaf379a0f 100644
--- a/pkgs/kde/default.nix
+++ b/pkgs/kde/default.nix
@@ -92,6 +92,9 @@ let
koi = self.callPackage ./third-party/koi { };
krohnkite = self.callPackage ./third-party/krohnkite { };
kzones = self.callPackage ./third-party/kzones { };
+
+ # Convenient for users to install various tools provided by kde
+ kdeGear = gear;
}
);
in
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 6e6156c8299e..fe0110812e69 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -6496,7 +6498,7 @@ self: super: with self; {
jaxlib-build = callPackage ../development/python-modules/jaxlib rec {
# Some platforms don't have `cudaSupport` defined, hence the need for 'or false'.
- inherit (pkgs.config) cudaSupport;
+ cudaSupport = false;
IOKit = pkgs.darwin.apple_sdk_11_0.IOKit;
};

View File

@@ -429,7 +429,7 @@ in {
environment = env;
path = with pkgs; [ nodejs_18 yarn ffmpeg-headless openssl ];
path = with pkgs; [ nodejs_18 yarn ffmpeg_6-headless openssl ];
script = ''
umask 077
@@ -843,7 +843,7 @@ in {
home = cfg.package;
};
})
(lib.attrsets.setAttrByPath [ cfg.user "packages" ] [ peertubeEnv pkgs.nodejs_18 pkgs.yarn pkgs.ffmpeg-headless ])
(lib.attrsets.setAttrByPath [ cfg.user "packages" ] [ peertubeEnv pkgs.nodejs_18 pkgs.yarn pkgs.ffmpeg_6-headless ])
(lib.mkIf cfg.redis.enableUnixSocket {${config.services.peertube.user}.extraGroups = [ "redis-peertube" ];})
];

View File

@@ -23,6 +23,7 @@
, libreoffice
, unittestCheckHook
, setuptools-scm
, stdenv
}:
buildPythonPackage rec {
@@ -83,6 +84,8 @@ buildPythonPackage rec {
export HOME=$TMPDIR
'';
doCheck = stdenv.hostPlatform.gcc.arch or null == null;
meta = with lib; {
description = "Backend part of Paperwork (Python API, no UI)";
homepage = "https://openpaper.work";

View File

@@ -157,6 +157,12 @@ stdenv.mkDerivation (finalAttrs: {
++ lib.optionals stdenv.hostPlatform.isDarwin [
"buffered_atomic_test.BufferedAtomic.singleThreadUnguardedAccess"
]
++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null) [
"io_async_hh_wheel_timer_test.HHWheelTimerTest.ReschedTest"
"io_async_hh_wheel_timer_test.HHWheelTimerTest.CancelTimeout"
"io_async_hh_wheel_timer_test.HHWheelTimerTest.DeleteWheelInTimeout"
"io_async_hh_wheel_timer_test.HHWheelTimerTest.FireOnce"
]
)
)
}

View File

@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
buildInputs = [ sane-backends glib ];
nativeCheckInputs = [ cunit valgrind ];
nativeCheckInputs = [ cunit ] ++ lib.optional (stdenv.hostPlatform.gcc.arch or null == null) valgrind;
doCheck = true;

View File

@@ -2,24 +2,24 @@
lib,
buildNpmPackage,
fetchFromGitHub,
python311,
python312,
nixosTests,
}:
let
pname = "open-webui";
version = "0.3.35";
version = "0.5.9";
src = fetchFromGitHub {
owner = "open-webui";
repo = "open-webui";
rev = "refs/tags/v${version}";
hash = "sha256-H46qoOEajPKRU/Lbd6r7r0vRjWSd7uGoA0deaDv6HSw=";
tag = "v${version}";
hash = "sha256-r4jl1WNI8tyhwyYbTZ+Q52xvv3PJY2FvhexMYHIIDPg=";
};
frontend = buildNpmPackage {
inherit pname version src;
npmDepsHash = "sha256-ohWSfwZfC/jfOpnNSqsvMyYnukk3Xa3Tq32PAl8Ds60=";
npmDepsHash = "sha256-PAX3aa0WdvCBvAD8AGQYqnx5Sd/85luMqP6hAyICyhA=";
# Disabling `pyodide:fetch` as it downloads packages during `buildPhase`
# Until this is solved, running python packages from the browser will not work.
@@ -30,6 +30,7 @@ let
env.CYPRESS_INSTALL_BINARY = "0"; # disallow cypress from downloading binaries in sandbox
env.ONNXRUNTIME_NODE_INSTALL_CUDA = "skip";
env.NODE_OPTIONS = "--max-old-space-size=8192";
installPhase = ''
runHook preInstall
@@ -41,10 +42,12 @@ let
'';
};
in
python311.pkgs.buildPythonApplication rec {
python312.pkgs.buildPythonApplication rec {
inherit pname version src;
pyproject = true;
build-system = with python312.pkgs; [ hatchling ];
# Not force-including the frontend build directory as frontend is managed by the `frontend` derivation above.
postPatch = ''
substituteInPlace pyproject.toml \
@@ -61,94 +64,114 @@ python311.pkgs.buildPythonApplication rec {
"pytest-docker"
];
dependencies = with python311.pkgs; [
aiohttp
alembic
anthropic
apscheduler
argon2-cffi
async-timeout
authlib
bcrypt
beautifulsoup4
black
boto3
chromadb
colbert-ai
docx2txt
duckduckgo-search
einops
extract-msg
fake-useragent
fastapi
faster-whisper
flask
flask-cors
fpdf2
ftfy
qdrant-client
google-generativeai
googleapis-common-protos
langchain
langchain-chroma
langchain-community
langfuse
markdown
nltk
openai
opencv-python-headless
openpyxl
pandas
passlib
peewee
peewee-migrate
psutil
psycopg2-binary
pydub
pyjwt
pymdown-extensions
pymilvus
pymongo
pymysql
pypandoc
pypdf
python-dotenv
python-jose
python-multipart
python-pptx
python-socketio
pytube
pyxlsb
rank-bm25
rapidocr-onnxruntime
redis
requests
sentence-transformers
tiktoken
unstructured
uvicorn
validators
xhtml2pdf
xlrd
youtube-transcript-api
];
build-system = with python311.pkgs; [ hatchling ];
dependencies =
with python312.pkgs;
[
aiocache
aiofiles
aiohttp
alembic
anthropic
apscheduler
argon2-cffi
async-timeout
authlib
bcrypt
beautifulsoup4
black
boto3
chromadb
colbert-ai
docx2txt
duckduckgo-search
einops
extract-msg
fake-useragent
fastapi
faster-whisper
flask
flask-cors
fpdf2
ftfy
gcp-storage-emulator
google-api-python-client
google-auth-httplib2
google-auth-oauthlib
google-cloud-storage
google-generativeai
googleapis-common-protos
iso-639
langchain
langchain-community
langdetect
langfuse
ldap3
markdown
moto
nltk
openai
opencv-python-headless
openpyxl
opensearch-py
pandas
passlib
peewee
peewee-migrate
pgvector
psutil
psycopg2-binary
pydub
pyjwt
pymdown-extensions
pymilvus
pymongo
pymysql
pypandoc
pypdf
python-dotenv
python-jose
python-multipart
python-pptx
python-socketio
pytube
pyxlsb
qdrant-client
rank-bm25
rapidocr-onnxruntime
redis
requests
sentence-transformers
soundfile
tiktoken
transformers
unstructured
uvicorn
validators
xlrd
youtube-transcript-api
]
++ moto.optional-dependencies.s3;
pythonImportsCheck = [ "open_webui" ];
makeWrapperArgs = [ "--set FRONTEND_BUILD_DIR ${frontend}/share/open-webui" ];
passthru.tests = {
inherit (nixosTests) open-webui;
passthru = {
tests = {
inherit (nixosTests) open-webui;
};
updateScript = ./update.sh;
};
meta = {
changelog = "https://github.com/open-webui/open-webui/blob/${src.tag}/CHANGELOG.md";
description = "Comprehensive suite for LLMs with a user-friendly WebUI";
homepage = "https://github.com/open-webui/open-webui";
changelog = "https://github.com/open-webui/open-webui/blob/${src.rev}/CHANGELOG.md";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ shivaraj-bh ];
mainProgram = "open-webui";
maintainers = with lib.maintainers; [
drupol
shivaraj-bh
];
};
}

View File

@@ -0,0 +1,21 @@
#!/usr/bin/env nix-shell
#!nix-shell -i bash -p git curl jq common-updater-scripts prefetch-npm-deps
set -eou pipefail
nixpkgs="$(git rev-parse --show-toplevel)"
path="$nixpkgs/pkgs/by-name/op/open-webui/package.nix"
version="$(curl --silent "https://api.github.com/repos/open-webui/open-webui/releases" | jq '.[0].tag_name' --raw-output)"
update-source-version open-webui "${version:1}" --file="$path"
# Fetch npm deps
tmpdir=$(mktemp -d)
curl -O --output-dir $tmpdir "https://raw.githubusercontent.com/open-webui/open-webui/refs/tags/${version}/package-lock.json"
curl -O --output-dir $tmpdir "https://raw.githubusercontent.com/open-webui/open-webui/refs/tags/${version}/package.json"
pushd $tmpdir
npm_hash=$(prefetch-npm-deps package-lock.json)
sed -i 's#npmDepsHash = "[^"]*"#npmDepsHash = "'"$npm_hash"'"#' "$path"
popd
rm -rf $tmpdir

View File

@@ -356,6 +356,7 @@ stdenv.mkDerivation rec {
--replace 'ON_BOOT="start"' 'ON_BOOT=''${ON_BOOT:-start}' \
--replace 'ON_SHUTDOWN="suspend"' 'ON_SHUTDOWN=''${ON_SHUTDOWN:-suspend}' \
--replace 'PARALLEL_SHUTDOWN=0' 'PARALLEL_SHUTDOWN=''${PARALLEL_SHUTDOWN:-0}' \
--replace 'SHUTDOWN_TIMEOUT=300' 'SHUTDOWN_TIMEOUT=''${SHUTDOWN_TIMEOUT:-300}' \
--replace "$out/bin" '${gettext}/bin' \
--replace 'lock/subsys' 'lock' \
--replace 'gettext.sh' 'gettext.sh

View File

@@ -0,0 +1,53 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
fs,
google-cloud-storage,
google-crc32c,
pytestCheckHook,
pytest-cov-stub,
requests,
}:
buildPythonPackage rec {
pname = "gcp-storage-emulator";
version = "2024.08.03";
pyproject = true;
src = fetchFromGitHub {
owner = "oittaa";
repo = "gcp-storage-emulator";
tag = "v${version}";
hash = "sha256-Lp9Wvod0wSE2+cnvLXguhagT30ax9TivyR8gC/kB7w0=";
};
build-system = [
setuptools
];
dependencies = [
fs
google-crc32c
];
nativeCheckInputs = [
google-cloud-storage
pytest-cov-stub
pytestCheckHook
requests
];
pythonImportsCheck = [
"gcp_storage_emulator"
];
meta = {
description = "Local emulator for Google Cloud Storage";
homepage = "https://github.com/oittaa/gcp-storage-emulator";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ drupol ];
mainProgram = "gcp-storage-emulator";
};
}

View File

@@ -2,6 +2,7 @@
lib,
buildPythonPackage,
fetchFromGitHub,
stdenv,
# build-system
setuptools,
@@ -74,7 +75,8 @@ buildPythonPackage rec {
# finds our ca-bundle, but expects something else (/path/to/clientcert/dir or None)
"test_ca_certs_ssl_cert_dir"
"test_no_ca_certs"
];
] ++ lib.optionals (stdenv.hostPlatform.gcc.arch or null != null)
[ "test_basicauth_in_request_session" "test_callable_in_request_session" ];
meta = {
description = "Python low-level client for OpenSearch";

View File

@@ -569,7 +569,7 @@ buildPythonPackage rec {
# Tests take a long time and may be flaky, so just sanity-check imports
doCheck = false;
pythonImportsCheck = [ "torch" ];
pythonImportsCheck = lib.optional (python.pythonVersion != "3.11" || !cudaSupport) "torch";
nativeCheckInputs = [
hypothesis

View File

@@ -58,13 +58,12 @@ rec {
});
beta = selectHighestVersion latest (generic {
version = "565.57.01";
sha256_64bit = "sha256-buvpTlheOF6IBPWnQVLfQUiHv4GcwhvZW3Ks0PsYLHo=";
sha256_aarch64 = "sha256-aDVc3sNTG4O3y+vKW87mw+i9AqXCY29GVqEIUlsvYfE=";
openSha256 = "sha256-/tM3n9huz1MTE6KKtTCBglBMBGGL/GOHi5ZSUag4zXA=";
settingsSha256 = "sha256-H7uEe34LdmUFcMcS6bz7sbpYhg9zPCb/5AmZZFTx1QA=";
persistencedSha256 = "sha256-hdszsACWNqkCh8G4VBNitDT85gk9gJe1BlQ8LdrYIkg=";
patchesOpen = [ drm_fop_flags_linux_612_patch ];
version = "570.133.07";
sha256_64bit = "sha256-LUPmTFgb5e9VTemIixqpADfvbUX1QoTT2dztwI3E3CY=";
sha256_aarch64 = "sha256-yTovUno/1TkakemRlNpNB91U+V04ACTMwPEhDok7jI0=";
openSha256 = "sha256-9l8N83Spj0MccA8+8R1uqiXBS0Ag4JrLPjrU3TaXHnM=";
settingsSha256 = "sha256-XMk+FvTlGpMquM8aE8kgYK2PIEszUZD2+Zmj2OpYrzU=";
persistencedSha256 = "sha256-G1V7JtHQbfnSRfVjz/LE2fYTlh9okpCbE4dfX9oYSg8=";
});
# Vulkan developer beta driver

View File

@@ -4994,6 +4994,8 @@ self: super: with self; {
gcovr = callPackage ../development/python-modules/gcovr { };
gcp-storage-emulator = callPackage ../development/python-modules/gcp-storage-emulator { };
gcsa = callPackage ../development/python-modules/gcsa { };
gcsfs = callPackage ../development/python-modules/gcsfs { };