diff options
Diffstat (limited to 'pkgs/development')
22 files changed, 398 insertions, 144 deletions
diff --git a/pkgs/development/compilers/go/1.17.nix b/pkgs/development/compilers/go/1.17.nix index e16e78d21a3..35c16f49f70 100644 --- a/pkgs/development/compilers/go/1.17.nix +++ b/pkgs/development/compilers/go/1.17.nix @@ -54,11 +54,11 @@ in stdenv.mkDerivation rec { pname = "go"; - version = "1.17.5"; + version = "1.17.6"; src = fetchurl { url = "https://dl.google.com/go/go${version}.src.tar.gz"; - sha256 = "sha256-Pe+5oJvtBCQDGV6HLcvIxvrhSFljMyJ5Zo7FLoCpWi0="; + sha256 = "sha256-TcG78/9h8MH/Kxk1Xm2IFRpwEmJopHx2FHdobvlHSMg="; }; # perl is used for testing go vet diff --git a/pkgs/development/libraries/lensfun/default.nix b/pkgs/development/libraries/lensfun/default.nix index 23675c9f9f8..a889e5358a5 100644 --- a/pkgs/development/libraries/lensfun/default.nix +++ b/pkgs/development/libraries/lensfun/default.nix @@ -25,9 +25,9 @@ stdenv.mkDerivation { }; # replace database with a more recent snapshot - postUnpack = '' - rm -R source/data/db - cp -R ${lensfunDatabase}/data/db source/data + prePatch = '' + rm -R ./data/db + cp -R ${lensfunDatabase}/data/db ./data ''; nativeBuildInputs = [ cmake pkg-config ]; diff --git a/pkgs/development/libraries/libcamera/default.nix b/pkgs/development/libraries/libcamera/default.nix index 187e2cf908e..37acf1fc8f0 100644 --- a/pkgs/development/libraries/libcamera/default.nix +++ b/pkgs/development/libraries/libcamera/default.nix @@ -4,9 +4,11 @@ , meson , ninja , pkg-config +, makeFontsConf , boost , gnutls , openssl +, libdrm , libevent , lttng-ust , gst_all_1 @@ -15,16 +17,17 @@ , doxygen , python3 , python3Packages +, systemd # for libudev }: stdenv.mkDerivation { pname = "libcamera"; - version = "unstable-2021-09-24"; + version = "unstable-2022-01-03"; src = fetchgit { url = "https://git.libcamera.org/libcamera/libcamera.git"; - rev = "40f5fddca7f774944a53f58eeaebc4db79c373d8"; - sha256 = "0jklgdv5ma4nszxibms5lkf5d2ips7ncynwa1flglrhl5bl4wkzz"; + rev = "1db1e31e664c1f613dc964d8519fe75d67b154b6"; + hash = "sha256-pXYPIU9xDWA870Gp1Jgizi5xnUHRvTqEq/ofFXdVZdg="; }; postPatch = '' @@ -44,6 +47,10 @@ stdenv.mkDerivation { # cam integration libevent + libdrm + + # hotplugging + systemd # lttng tracing lttng-ust @@ -65,11 +72,18 @@ stdenv.mkDerivation { openssl ]; - mesonFlags = [ "-Dv4l2=true" "-Dqcam=disabled" ]; + mesonFlags = [ + "-Dv4l2=true" + "-Dqcam=disabled" + "-Dlc-compliance=disabled" # tries unconditionally to download gtest when enabled + ]; # Fixes error on a deprecated declaration NIX_CFLAGS_COMPILE = "-Wno-error=deprecated-declarations"; + # Silence fontconfig warnings about missing config + FONTCONFIG_FILE = makeFontsConf { fontDirectories = []; }; + meta = with lib; { description = "An open source camera stack and framework for Linux, Android, and ChromeOS"; homepage = "https://libcamera.org"; diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix index b7ca4df8885..bdce5f48efd 100644 --- a/pkgs/development/libraries/ncurses/default.nix +++ b/pkgs/development/libraries/ncurses/default.nix @@ -1,15 +1,13 @@ -{ lib, stdenv, fetchurl, pkg-config - +{ lib +, stdenv +, fetchurl +, buildPackages +, pkg-config , abiVersion ? "6" -, mouseSupport ? false -, unicode ? true , enableStatic ? stdenv.hostPlatform.isStatic -, enableShared ? !enableStatic , withCxx ? !stdenv.hostPlatform.useAndroidPrebuilt - -, gpm - -, buildPackages +, mouseSupport ? false, gpm +, unicodeSupport ? true }: stdenv.mkDerivation rec { @@ -31,13 +29,13 @@ stdenv.mkDerivation rec { setOutputFlags = false; # some aren't supported configureFlags = [ - (lib.withFeature enableShared "shared") + (lib.withFeature (!enableStatic) "shared") "--without-debug" "--enable-pc-files" "--enable-symlinks" "--with-manpage-format=normal" "--disable-stripping" - ] ++ lib.optional unicode "--enable-widec" + ] ++ lib.optional unicodeSupport "--enable-widec" ++ lib.optional (!withCxx) "--without-cxx" ++ lib.optional (abiVersion == "5") "--with-abi-version=5" ++ lib.optional stdenv.hostPlatform.isNetBSD "--enable-rpath" @@ -49,12 +47,16 @@ stdenv.mkDerivation rec { # Only the C compiler, and explicitly not C++ compiler needs this flag on solaris: CFLAGS = lib.optionalString stdenv.isSunOS "-D_XOPEN_SOURCE_EXTENDED"; - depsBuildBuild = [ buildPackages.stdenv.cc ]; + depsBuildBuild = [ + buildPackages.stdenv.cc + ]; + nativeBuildInputs = [ pkg-config ] ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [ buildPackages.ncurses ]; + buildInputs = lib.optional (mouseSupport && stdenv.isLinux) gpm; preConfigure = '' @@ -147,31 +149,26 @@ stdenv.mkDerivation rec { rm "$out"/lib/*.a ''; - meta = { + meta = with lib; { + homepage = "https://www.gnu.org/software/ncurses/"; description = "Free software emulation of curses in SVR4 and more"; - longDescription = '' - The Ncurses (new curses) library is a free software emulation of - curses in System V Release 4.0, and more. It uses Terminfo - format, supports pads and color and multiple highlights and - forms characters and function-key mapping, and has all the other - SYSV-curses enhancements over BSD Curses. - - The ncurses code was developed under GNU/Linux. It has been in - use for some time with OpenBSD as the system curses library, and - on FreeBSD and NetBSD as an external package. It should port - easily to any ANSI/POSIX-conforming UNIX. It has even been - ported to OS/2 Warp! + The Ncurses (new curses) library is a free software emulation of curses in + System V Release 4.0, and more. It uses Terminfo format, supports pads and + color and multiple highlights and forms characters and function-key + mapping, and has all the other SYSV-curses enhancements over BSD Curses. + + The ncurses code was developed under GNU/Linux. It has been in use for + some time with OpenBSD as the system curses library, and on FreeBSD and + NetBSD as an external package. It should port easily to any + ANSI/POSIX-conforming UNIX. It has even been ported to OS/2 Warp! ''; - - homepage = "https://www.gnu.org/software/ncurses/"; - - license = lib.licenses.mit; - platforms = lib.platforms.all; + license = licenses.mit; + platforms = platforms.all; }; passthru = { ldflags = "-lncurses"; - inherit unicode abiVersion; + inherit unicodeSupport abiVersion; }; } diff --git a/pkgs/development/libraries/opencv/4.x.nix b/pkgs/development/libraries/opencv/4.x.nix index 10459d959b2..0c6f9fb90c0 100644 --- a/pkgs/development/libraries/opencv/4.x.nix +++ b/pkgs/development/libraries/opencv/4.x.nix @@ -275,7 +275,12 @@ stdenv.mkDerivation { propagatedBuildInputs = lib.optional enablePython pythonPackages.numpy ++ lib.optionals enableCuda [ cudatoolkit nvidia-optical-flow-sdk ]; - nativeBuildInputs = [ cmake pkg-config unzip ]; + nativeBuildInputs = [ cmake pkg-config unzip ] + ++ lib.optionals enablePython [ + pythonPackages.pip + pythonPackages.wheel + pythonPackages.setuptools + ]; NIX_CFLAGS_COMPILE = lib.optionalString enableEXR "-I${ilmbase.dev}/include/OpenEXR"; @@ -333,6 +338,21 @@ stdenv.mkDerivation { postInstall = '' sed -i "s|{exec_prefix}/$out|{exec_prefix}|;s|{prefix}/$out|{prefix}|" \ "$out/lib/pkgconfig/opencv4.pc" + '' + # install python distribution information, so other packages can `import opencv` + + lib.optionalString enablePython '' + pushd $NIX_BUILD_TOP/$sourceRoot/modules/python/package + python -m pip wheel --verbose --no-index --no-deps --no-clean --no-build-isolation --wheel-dir dist . + + pushd dist + python -m pip install ./*.whl --no-index --no-warn-script-location --prefix="$out" --no-cache + + # the cv2/__init__.py just tries to check provide "nice user feedback" if the installation is bad + # however, this also causes infinite recursion when used by other packages + rm -r $out/${pythonPackages.python.sitePackages}/cv2 + + popd + popd ''; passthru = lib.optionalAttrs enablePython { pythonPath = [ ]; }; diff --git a/pkgs/development/libraries/pipewire/default.nix b/pkgs/development/libraries/pipewire/default.nix index b6d96492fce..f1159017de6 100644 --- a/pkgs/development/libraries/pipewire/default.nix +++ b/pkgs/development/libraries/pipewire/default.nix @@ -60,16 +60,12 @@ }: let - fontsConf = makeFontsConf { - fontDirectories = [ ]; - }; - - mesonEnable = b: if b then "enabled" else "disabled"; + mesonEnableFeature = b: if b then "enabled" else "disabled"; mesonList = l: "[" + lib.concatStringsSep "," l + "]"; self = stdenv.mkDerivation rec { pname = "pipewire"; - version = "0.3.42"; + version = "0.3.43"; outputs = [ "out" @@ -87,7 +83,7 @@ let owner = "pipewire"; repo = "pipewire"; rev = version; - sha256 = "sha256-Iyd5snOt+iCT7W0+FlfvhMUZo/gF+zr9JX4HIGVdHto="; + sha256 = "sha256-vjMA9dQvZe7dPbF9BNtCYf1V240RUBdtxeyqFjWA4j4="; }; patches = [ @@ -103,15 +99,6 @@ let ./0090-pipewire-config-template-paths.patch # Place SPA data files in lib output to avoid dependency cycles ./0095-spa-data-dir.patch - # Fix attempt to put system service units into pkgs.systemd. - (fetchpatch { - url = "https://gitlab.freedesktop.org/pipewire/pipewire/-/commit/b666edde787b167c6e19b9356257d48007357acc.diff"; - sha256 = "1pmnyyvrjykr46ld4a5frq3cc739f8h4jwvfj414lyx8c6ybm63s"; - }) - (fetchpatch { - url = "https://gitlab.freedesktop.org/pipewire/pipewire/-/commit/5054b48c9de655b4b48f7c801cb305d9eb122520.diff"; - sha256 = "0myhb7h4g7x2nr08dpx8d7nqhsmzp90yanmkvm627r1xxnnr3ivn"; - }) ]; nativeBuildInputs = [ @@ -159,33 +146,32 @@ let "-Dinstalled_test_prefix=${placeholder "installedTests"}" "-Dpipewire_pulse_prefix=${placeholder "pulse"}" "-Dlibjack-path=${placeholder "jack"}/lib" - "-Dlibcamera=${mesonEnable libcameraSupport}" - "-Droc=${mesonEnable rocSupport}" - "-Dlibpulse=${mesonEnable pulseTunnelSupport}" - "-Davahi=${mesonEnable zeroconfSupport}" - "-Dgstreamer=${mesonEnable gstreamerSupport}" + "-Dlibcamera=${mesonEnableFeature libcameraSupport}" + "-Droc=${mesonEnableFeature rocSupport}" + "-Dlibpulse=${mesonEnableFeature pulseTunnelSupport}" + "-Davahi=${mesonEnableFeature zeroconfSupport}" + "-Dgstreamer=${mesonEnableFeature gstreamerSupport}" "-Dsystemd-system-service=enabled" - "-Dffmpeg=${mesonEnable ffmpegSupport}" - "-Dbluez5=${mesonEnable bluezSupport}" - "-Dbluez5-backend-hsp-native=${mesonEnable nativeHspSupport}" - "-Dbluez5-backend-hfp-native=${mesonEnable nativeHfpSupport}" - "-Dbluez5-backend-ofono=${mesonEnable ofonoSupport}" - "-Dbluez5-backend-hsphfpd=${mesonEnable hsphfpdSupport}" + "-Dffmpeg=${mesonEnableFeature ffmpegSupport}" + "-Dbluez5=${mesonEnableFeature bluezSupport}" + "-Dbluez5-backend-hsp-native=${mesonEnableFeature nativeHspSupport}" + "-Dbluez5-backend-hfp-native=${mesonEnableFeature nativeHfpSupport}" + "-Dbluez5-backend-ofono=${mesonEnableFeature ofonoSupport}" + "-Dbluez5-backend-hsphfpd=${mesonEnableFeature hsphfpdSupport}" "-Dsysconfdir=/etc" "-Dpipewire_confdata_dir=${placeholder "lib"}/share/pipewire" "-Dsession-managers=" "-Dvulkan=enabled" ]; - FONTCONFIG_FILE = fontsConf; # Fontconfig error: Cannot load default config file + # Fontconfig error: Cannot load default config file + FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ ]; }; doCheck = true; postUnpack = '' - patchShebangs source/doc/strip-static.sh patchShebangs source/doc/input-filter.sh patchShebangs source/doc/input-filter-h.sh - patchShebangs source/spa/tests/gen-cpp-test.py ''; postInstall = '' diff --git a/pkgs/development/libraries/pipewire/wireplumber.nix b/pkgs/development/libraries/pipewire/wireplumber.nix new file mode 100644 index 00000000000..eba1b210590 --- /dev/null +++ b/pkgs/development/libraries/pipewire/wireplumber.nix @@ -0,0 +1,82 @@ +{ lib +, stdenv +, fetchFromGitLab +, nix-update-script +, # base build deps + meson +, pkg-config +, ninja +, # docs build deps + python3 +, doxygen +, graphviz +, # GI build deps + gobject-introspection +, # runtime deps + glib +, systemd +, lua5_4 +, pipewire +, # options + enableDocs ? true +, enableGI ? stdenv.hostPlatform == stdenv.buildPlatform +}: +let + mesonEnableFeature = b: if b then "enabled" else "disabled"; +in +stdenv.mkDerivation rec { + pname = "wireplumber"; + version = "0.4.6"; + + outputs = [ "out" "dev" ] ++ lib.optional enableDocs "doc"; + + src = fetchFromGitLab { + domain = "gitlab.freedesktop.org"; + owner = "pipewire"; + repo = "wireplumber"; + rev = version; + sha256 = "sha256-y+Gj9EZn67W3U81zXgp+6JAFxZSZTwwT0TB3Kueb/Tw="; + }; + + nativeBuildInputs = [ + meson + pkg-config + ninja + ] ++ lib.optionals enableDocs [ + graphviz + ] ++ lib.optionals enableGI [ + gobject-introspection + ] ++ lib.optionals (enableDocs || enableGI) [ + doxygen + (python3.withPackages (ps: with ps; + lib.optionals enableDocs [ sphinx sphinx_rtd_theme breathe ] ++ + lib.optionals enableGI [ lxml ] + )) + ]; + + buildInputs = [ + glib + systemd + lua5_4 + pipewire + ]; + + mesonFlags = [ + "-Dsystem-lua=true" + "-Delogind=disabled" + "-Ddoc=${mesonEnableFeature enableDocs}" + "-Dintrospection=${mesonEnableFeature enableGI}" + ]; + + passthru.updateScript = nix-update-script { + attrPath = pname; + }; + + meta = with lib; { + description = "A modular session / policy manager for PipeWire"; + homepage = "https://pipewire.org"; + license = licenses.mit; + platforms = platforms.linux; + maintainers = with maintainers; [ k900 ]; + }; +} diff --git a/pkgs/development/python-modules/django-allauth/default.nix b/pkgs/development/python-modules/django-allauth/default.nix index 143e76cf0d8..a68cfd6d9cd 100644 --- a/pkgs/development/python-modules/django-allauth/default.nix +++ b/pkgs/development/python-modules/django-allauth/default.nix @@ -3,14 +3,14 @@ buildPythonPackage rec { pname = "django-allauth"; - version = "0.40.0"; + version = "0.47.0"; # no tests on PyPI src = fetchFromGitHub { owner = "pennersr"; repo = pname; rev = version; - sha256 = "10id4k01p1hg5agb8cmllg8mv4kc7ryl75br10idwxabqqp4vla1"; + sha256 = "sha256-wKrsute6TCl331UrxNEBf/zTtGnyGHsOZQwdiicbg2o="; }; propagatedBuildInputs = [ requests requests_oauthlib django python3-openid ]; diff --git a/pkgs/development/python-modules/django-oauth-toolkit/default.nix b/pkgs/development/python-modules/django-oauth-toolkit/default.nix index e7cb4814cb4..6212c754f89 100644 --- a/pkgs/development/python-modules/django-oauth-toolkit/default.nix +++ b/pkgs/development/python-modules/django-oauth-toolkit/default.nix @@ -1,22 +1,58 @@ -{ lib, buildPythonPackage, fetchFromGitHub -, django, requests, oauthlib +{ lib +, buildPythonPackage +, fetchFromGitHub + +# propagates +, django +, jwcrypto +, requests +, oauthlib + +# tests +, djangorestframework +, pytest-django +, pytest-xdist +, pytest-mock +, pytestCheckHook }: buildPythonPackage rec { pname = "django-oauth-toolkit"; - version = "1.2.0"; + version = "1.6.1"; + format = "setuptools"; src = fetchFromGitHub { owner = "jazzband"; repo = pname; rev = version; - sha256 = "1zbksxrcxlqnapmlvx4rgvpqc4plgnq0xnf45cjwzwi1626zs8g6"; + sha256 = "sha256-TOrFxQULwiuwpVFqRwRkfTW+GRudLNy6F/gIjUYjZhI="; }; - propagatedBuildInputs = [ django requests oauthlib ]; + postPatch = '' + sed -i '/cov/d' tox.ini + ''; + + propagatedBuildInputs = [ + django + jwcrypto + oauthlib + requests + ]; + + DJANGO_SETTINGS_MODULE = "tests.settings"; + + checkInputs = [ + djangorestframework + pytest-django + pytest-xdist + pytest-mock + pytestCheckHook + ]; - # django.core.exceptions.ImproperlyConfigured: Requested setting OAUTH2_PROVIDER, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings - doCheck = false; + disabledTests = [ + # Failed to get a valid response from authentication server. Status code: 404, Reason: Not Found. + "test_response_when_auth_server_response_return_404" + ]; meta = with lib; { description = "OAuth2 goodies for the Djangonauts"; diff --git a/pkgs/development/python-modules/django_guardian/default.nix b/pkgs/development/python-modules/django_guardian/default.nix index 9685e55bb1c..c7bda13dd9a 100644 --- a/pkgs/development/python-modules/django_guardian/default.nix +++ b/pkgs/development/python-modules/django_guardian/default.nix @@ -1,5 +1,5 @@ { lib, buildPythonPackage, fetchPypi -, django_environ, mock, django +, django-environ, mock, django , pytest, pytest-runner, pytest-django }: buildPythonPackage rec { @@ -11,7 +11,7 @@ buildPythonPackage rec { sha256 = "c58a68ae76922d33e6bdc0e69af1892097838de56e93e78a8361090bcd9f89a0"; }; - checkInputs = [ pytest pytest-runner pytest-django django_environ mock ]; + checkInputs = [ pytest pytest-runner pytest-django django-environ mock ]; propagatedBuildInputs = [ django ]; meta = with lib; { diff --git a/pkgs/development/python-modules/gql/default.nix b/pkgs/development/python-modules/gql/default.nix new file mode 100644 index 00000000000..65e4bbde319 --- /dev/null +++ b/pkgs/development/python-modules/gql/default.nix @@ -0,0 +1,77 @@ +{ lib +, aiofiles +, aiohttp +, botocore +, buildPythonPackage +, fetchFromGitHub +, graphql-core +, mock +, parse +, pytest-asyncio +, pytestCheckHook +, pythonOlder +, requests +, requests-toolbelt +, urllib3 +, vcrpy +, websockets +, yarl +}: + +buildPythonPackage rec { + pname = "gql"; + version = "3.0.0rc0"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; + + src = fetchFromGitHub { + owner = "graphql-python"; + repo = pname; + rev = "v${version}"; + hash = "sha256-yr1DyMj/0C9XPTyGdbQbn7nMRKr4JwItFDsqvl/goqU="; + }; + + propagatedBuildInputs = [ + aiohttp + botocore + graphql-core + requests + requests-toolbelt + urllib3 + websockets + yarl + ]; + + checkInputs = [ + aiofiles + mock + parse + pytest-asyncio + pytestCheckHook + vcrpy + ]; + + disabledTests = [ + # Tests requires network access + "test_execute_result_error" + "test_http_transport" + ]; + + disabledTestPaths = [ + # Exclude linter tests + "gql-checker/tests/test_flake8_linter.py" + "gql-checker/tests/test_pylama_linter.py" + ]; + + pythonImportsCheck = [ + "gql" + ]; + + meta = with lib; { + description = "GraphQL client in Python"; + homepage = "https://github.com/graphql-python/gql"; + license = with licenses; [ mit ]; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/development/python-modules/gradient-utils/default.nix b/pkgs/development/python-modules/gradient-utils/default.nix index 87002505c0e..e81d815e8c2 100644 --- a/pkgs/development/python-modules/gradient-utils/default.nix +++ b/pkgs/development/python-modules/gradient-utils/default.nix @@ -7,6 +7,7 @@ , poetry-core , prometheus-client , pytestCheckHook +, pythonOlder , requests }: @@ -15,6 +16,8 @@ buildPythonPackage rec { version = "0.5.0"; format = "pyproject"; + disabled = pythonOlder "3.6"; + src = fetchFromGitHub { owner = "Paperspace"; repo = pname; @@ -22,15 +25,9 @@ buildPythonPackage rec { sha256 = "19plkgwwfs6298vjplgsvhirixi3jbngq5y07x9c0fjxk39fa2dk"; }; - postPatch = '' - substituteInPlace pyproject.toml \ - --replace 'numpy = "1.18.5"' 'numpy = "^1.18.5"' \ - --replace 'hyperopt = "0.1.2"' 'hyperopt = ">=0.1.2"' \ - --replace 'wheel = "^0.35.1"' 'wheel = "*"' \ - --replace 'prometheus-client = ">=0.8,<0.10"' 'prometheus-client = "*"' - ''; - - nativeBuildInputs = [ poetry-core ]; + nativeBuildInputs = [ + poetry-core + ]; propagatedBuildInputs = [ hyperopt @@ -44,20 +41,24 @@ buildPythonPackage rec { pytestCheckHook ]; + postPatch = '' + substituteInPlace pyproject.toml \ + --replace 'wheel = "^0.35.1"' 'wheel = "*"' \ + --replace 'prometheus-client = ">=0.8,<0.10"' 'prometheus-client = "*"' + ''; + preCheck = '' export HOSTNAME=myhost-experimentId ''; - disabledTests = [ - "test_add_metrics_pushes_metrics" # requires a working prometheus push gateway - ]; - disabledTestPaths = [ - # needs network access + # Requires a working Prometheus push gateway "tests/integration/test_metrics.py" ]; - pythonImportsCheck = [ "gradient_utils" ]; + pythonImportsCheck = [ + "gradient_utils" + ]; meta = with lib; { description = "Python utils and helpers library for Gradient"; diff --git a/pkgs/development/python-modules/gradient/default.nix b/pkgs/development/python-modules/gradient/default.nix index ccde1a38ecc..026c61fc615 100644 --- a/pkgs/development/python-modules/gradient/default.nix +++ b/pkgs/development/python-modules/gradient/default.nix @@ -9,6 +9,7 @@ , fetchPypi , gradient_statsd , gradient-utils +, gql , halo , marshmallow , progressbar2 @@ -22,17 +23,19 @@ buildPythonPackage rec { pname = "gradient"; - version = "1.9.0"; + version = "1.9.1"; + format = "setuptools"; src = fetchPypi { inherit pname version; - sha256 = "47be02511d7ea66a13559598851cb435d435fb3f7676f6de17292d06daad8947"; + hash = "sha256-zimOh4bc9EQGpqMky/etwnAF04onJ2m/KAl29IaAeAY="; }; postPatch = '' substituteInPlace setup.py \ --replace 'attrs<=' 'attrs>=' \ --replace 'colorama==' 'colorama>=' \ + --replace 'gql[requests]==3.0.0a6' 'gql' \ --replace 'PyYAML==' 'PyYAML>=' \ --replace 'marshmallow<' 'marshmallow>=' \ --replace 'websocket-client==' 'websocket-client>=' @@ -45,6 +48,7 @@ buildPythonPackage rec { click-didyoumean click-help-colors colorama + gql gradient_statsd gradient-utils halo @@ -58,17 +62,20 @@ buildPythonPackage rec { websocket-client ]; - # tries to use /homeless-shelter to mimic container usage, etc + # Tries to use /homeless-shelter to mimic container usage, etc doCheck = false; + # marshmallow.exceptions.StringNotCollectionError: "only" should be a collection of strings. + # Support for marshmallow > 3 + # pythonImportsCheck = [ + # "gradient" + # ]; + meta = with lib; { description = "The command line interface for Gradient"; homepage = "https://github.com/Paperspace/gradient-cli"; license = licenses.isc; platforms = platforms.unix; maintainers = with maintainers; [ thoughtpolice ]; - # There is no support for click > 8 - # https://github.com/Paperspace/gradient-cli/issues/368 - broken = true; }; } diff --git a/pkgs/development/python-modules/makefun/default.nix b/pkgs/development/python-modules/makefun/default.nix index dbf4b8ffe46..1d4ae635800 100644 --- a/pkgs/development/python-modules/makefun/default.nix +++ b/pkgs/development/python-modules/makefun/default.nix @@ -7,11 +7,11 @@ buildPythonPackage rec { pname = "makefun"; - version = "1.13.0"; + version = "1.13.1"; src = fetchPypi { inherit pname version; - sha256 = "2c673d2b4f0ef809347513cb45e3b23a04228588af7c9ac859e99247abac516a"; + sha256 = "985bb8b670ffbbb95d2a8aa996d318e6e9a3f26fc6f3ef2da93ebdf8f9c616bf"; }; postPatch = '' diff --git a/pkgs/development/python-modules/oauthlib/default.nix b/pkgs/development/python-modules/oauthlib/default.nix index 5c4cbc78adb..01e6ca29b5d 100644 --- a/pkgs/development/python-modules/oauthlib/default.nix +++ b/pkgs/development/python-modules/oauthlib/default.nix @@ -1,31 +1,40 @@ { lib , buildPythonPackage , fetchFromGitHub -, mock -, pytest -, cryptography + +# propagates , blinker +, cryptography , pyjwt + +# test +, mock +, pytestCheckHook }: buildPythonPackage rec { pname = "oauthlib"; - version = "unstable-2020-05-08"; + version = "3.1.1"; + format = "setuptools"; # master supports pyjwt==1.7.1 src = fetchFromGitHub { owner = pname; repo = pname; - rev = "46647402896db5f0d979eba9594623e889739060"; - sha256 = "1wrdjdvlfcd74lckcgascnasrffg8sip0z673si4ag5kv4afiz3l"; + rev = "v${version}"; + hash = "sha256:1bgxpzh11i0x7h9py3a29cz5z714b3p498b62znnn5ciy0cr80sv"; }; - checkInputs = [ mock pytest ]; - propagatedBuildInputs = [ cryptography blinker pyjwt ]; + propagatedBuildInputs = [ + blinker + cryptography + pyjwt + ]; - checkPhase = '' - py.test tests/ - ''; + checkInputs = [ + mock + pytestCheckHook + ]; meta = with lib; { homepage = "https://github.com/idan/oauthlib"; diff --git a/pkgs/development/python-modules/pydub/default.nix b/pkgs/development/python-modules/pydub/default.nix index 6b67814a222..3adf54281b7 100644 --- a/pkgs/development/python-modules/pydub/default.nix +++ b/pkgs/development/python-modules/pydub/default.nix @@ -1,8 +1,18 @@ -{ lib, stdenv, buildPythonPackage, fetchFromGitHub, scipy, ffmpeg-full }: +{ lib +, stdenv +, buildPythonPackage +, fetchFromGitHub + +# tests +, ffmpeg-full +, python +}: buildPythonPackage rec { pname = "pydub"; version = "0.25.1"; + format = "setuptools"; + # pypi version doesn't include required data files for tests src = fetchFromGitHub { owner = "jiaaro"; @@ -11,23 +21,24 @@ buildPythonPackage rec { sha256 = "0xskllq66wqndjfmvp58k26cv3w480sqsil6ifwp4gghir7hqc8m"; }; + pythonImportsCheck = [ + "pydub" + "pydub.audio_segment" + "pydub.playback" + ]; - # disable a test that fails on aarch64 due to rounding errors - postPatch = lib.optionalString stdenv.isAarch64 '' - substituteInPlace test/test.py \ - --replace "test_overlay_with_gain_change" "notest_overlay_with_gain_change" - ''; - - checkInputs = [ scipy ffmpeg-full ]; + checkInputs = [ + ffmpeg-full + ]; checkPhase = '' - python test/test.py + ${python.interpreter} test/test.py ''; meta = with lib; { - description = "Manipulate audio with a simple and easy high level interface."; - homepage = "http://pydub.com/"; - license = licenses.mit; - platforms = platforms.all; + description = "Manipulate audio with a simple and easy high level interface"; + homepage = "http://pydub.com"; + license = licenses.mit; + maintainers = with maintainers; [ hexa ]; }; } diff --git a/pkgs/development/python-modules/pylgnetcast/default.nix b/pkgs/development/python-modules/pylgnetcast/default.nix index cadb4bb8383..51e3dfdab28 100644 --- a/pkgs/development/python-modules/pylgnetcast/default.nix +++ b/pkgs/development/python-modules/pylgnetcast/default.nix @@ -7,7 +7,7 @@ buildPythonPackage rec { pname = "pylgnetcast"; - version = "0.3.5"; + version = "0.3.7"; format = "setuptools"; disabled = pythonOlder "3.6"; @@ -16,7 +16,7 @@ buildPythonPackage rec { owner = "Drafteed"; repo = "python-lgnetcast"; rev = "v${version}"; - sha256 = "11g7ya4ppqxjiv3fkz9mi6h1afw9icy6xyn4jzm63kjvxqhrwnw4"; + sha256 = "0pmz52k2sfxj5x2wcwdjks2lqh1gb5zfrjgc6xij8jal4l9xd2dz"; }; propagatedBuildInputs = [ diff --git a/pkgs/development/python-modules/pynetbox/default.nix b/pkgs/development/python-modules/pynetbox/default.nix index eeb6ad01798..54fb270a176 100644 --- a/pkgs/development/python-modules/pynetbox/default.nix +++ b/pkgs/development/python-modules/pynetbox/default.nix @@ -10,13 +10,13 @@ buildPythonPackage rec { pname = "pynetbox"; - version = "6.4.1"; + version = "6.5.0"; src = fetchFromGitHub { owner = "netbox-community"; repo = pname; rev = "v${version}"; - sha256 = "08k2zxfz23gzbk49r3hmh6r3m5rgx1gk7w83qxi1v4gbm4wr0v9m"; + sha256 = "1fk64bi7aswsmfqsciamml2wydgfg464h6i7479xfim4mwmkkik4"; }; SETUPTOOLS_SCM_PRETEND_VERSION = version; diff --git a/pkgs/development/python-modules/pytest-cases/default.nix b/pkgs/development/python-modules/pytest-cases/default.nix index ccbf5401bd2..c3374032d33 100644 --- a/pkgs/development/python-modules/pytest-cases/default.nix +++ b/pkgs/development/python-modules/pytest-cases/default.nix @@ -10,14 +10,14 @@ buildPythonPackage rec { pname = "pytest-cases"; - version = "3.6.7"; + version = "3.6.8"; format = "setuptools"; disabled = pythonOlder "3.6"; src = fetchPypi { inherit pname version; - sha256 = "sha256-ZUAXmIww/tdm7nDAj2VDXq0B6raHeDX1ywxnnv3EVIE="; + sha256 = "d423e87b30e1080cc162d86c72bfa35861cccfe3539125e81c68ba142ab974bc"; }; nativeBuildInputs = [ diff --git a/pkgs/development/tools/kubepug/default.nix b/pkgs/development/tools/kubepug/default.nix index 4795d35e7e6..d14ba450103 100644 --- a/pkgs/development/tools/kubepug/default.nix +++ b/pkgs/development/tools/kubepug/default.nix @@ -1,23 +1,25 @@ -{ lib, buildGoModule, fetchFromGitHub }: +{ lib, buildGo117Module, fetchFromGitHub }: -buildGoModule rec { +buildGo117Module rec { pname = "kubepug"; - version = "1.2.2"; + version = "1.3.2"; src = fetchFromGitHub { owner = "rikatz"; repo = "kubepug"; rev = "v${version}"; - sha256 = "sha256-jQ/LzwxYxfCKiu+2VhjQ3YWwLEqZkYrH7+olBOMUA1A="; + sha256 = "sha256-cjL718xTgtYev/lYL24vwZcB+joY3wIY4ixRCwAHQ4E="; }; - vendorSha256 = "sha256-P5HoU9AAGFrSrp9iymjW+r8w5L90KUOrmaXM8p+Wn44="; + vendorSha256 = "0hynxj3q4aa1gx3w4ak56z6j5iplxi2hzqzsjkgz20fy34nfd41s"; ldflags = [ "-s" "-w" "-X=github.com/rikatz/kubepug/version.Version=${src.rev}" ]; - subPackages = [ "cmd/kubepug.go" ]; + patches = [ + ./skip-external-network-tests.patch + ]; meta = with lib; { description = "Checks a Kubernetes cluster for objects using deprecated API versions"; diff --git a/pkgs/development/tools/kubepug/skip-external-network-tests.patch b/pkgs/development/tools/kubepug/skip-external-network-tests.patch new file mode 100644 index 00000000000..e24aa01ad17 --- /dev/null +++ b/pkgs/development/tools/kubepug/skip-external-network-tests.patch @@ -0,0 +1,12 @@ +diff --git a/pkg/utils/downloader_test.go b/pkg/utils/downloader_test.go +index b227760..b72dee9 100644 +--- a/pkg/utils/downloader_test.go ++++ b/pkg/utils/downloader_test.go +@@ -7,6 +7,7 @@ import ( + ) + + func TestDownloadSwaggerFile(t *testing.T) { ++ t.Skipf("Nix sandbox does not have networking") + var tmpdir string + // Github actions does not have a temporary dir :/ + tmpdir = os.Getenv("RUNNER_TEMP") diff --git a/pkgs/development/tools/rust/cargo-llvm-lines/default.nix b/pkgs/development/tools/rust/cargo-llvm-lines/default.nix index 1e10d9eddcf..7fc1da095e5 100644 --- a/pkgs/development/tools/rust/cargo-llvm-lines/default.nix +++ b/pkgs/development/tools/rust/cargo-llvm-lines/default.nix @@ -2,16 +2,16 @@ rustPlatform.buildRustPackage rec { pname = "cargo-llvm-lines"; - version = "0.4.12"; + version = "0.4.13"; src = fetchFromGitHub { owner = "dtolnay"; repo = pname; rev = version; - sha256 = "sha256-D4blt8kGD0mxysedRMZo/VNfwfYdJs8T2zoNjHRi0ng="; + sha256 = "sha256-sN0i2oo0XuxneIK/w+jpxkcdm2rtqhyH2Y3CMPnH+ro="; }; - cargoSha256 = "sha256-H2APBu9oHmtRGSB+VQT9V5C36awPy8fi6A2Qf1RsIbU="; + cargoSha256 = "sha256-Gv7C4NFThNawhT+IYO0ZbpOh6w/yPeIJKZjzTyM/GJw="; meta = with lib; { description = "Count the number of lines of LLVM IR across all instantiations of a generic function"; |