Update pipenv, add ITG options, py311 from nixos23_05
This commit is contained in:
@@ -33,6 +33,8 @@ in rec {
|
||||
pythonPackagesExtensions = (prev.pythonPackagesExtensions or []) ++ [
|
||||
(python-final: python-prev: let cp = python-final.callPackage; in {
|
||||
django-rapyd-modernauth = cp ./django-rapyd-modernauth.nix {};
|
||||
graypy = cp ./graypy.nix {};
|
||||
itg-django-utils = cp ./itg-django-utils.nix {};
|
||||
xonsh-apipenv = cp ./xonsh-apipenv.nix {};
|
||||
xonsh-direnv = cp ./xonsh-direnv.nix {};
|
||||
xontrib-vox = cp ./xonsh-vox.nix {};
|
||||
@@ -63,6 +65,7 @@ in rec {
|
||||
handbrake = prev.handbrake.override {
|
||||
libbluray = libbluray-custom;
|
||||
};
|
||||
pipenv-ivr = prev.callPackage ./pipenv.nix { };
|
||||
|
||||
xonsh = prev.xonsh.overridePythonAttrs (old: rec{
|
||||
python3 = final.gregpy;
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
|
||||
amqplib,
|
||||
mock,
|
||||
pytestCheckHook,
|
||||
requests,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "graypy";
|
||||
version = "2.1.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "severb";
|
||||
repo = "graypy";
|
||||
rev = "2.1.0";
|
||||
hash = "sha256-y1HbJEpqnAgOeB+zXKy3iUT6Lpv0bufjL7+jWUSAjFs=";
|
||||
};
|
||||
|
||||
nativeCheckInputs = [
|
||||
amqplib
|
||||
mock
|
||||
pytestCheckHook
|
||||
requests
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Python logging handlers that send messages in the Graylog Extended Log Format (GELF).";
|
||||
homepage = "https://github.com/severb/graypy";
|
||||
license = licenses.bsd3;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchurl,
|
||||
|
||||
django,
|
||||
djangorestframework,
|
||||
graypy,
|
||||
setuptools,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "itg-django-utils";
|
||||
version = "0.1.11";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pypi.ivrtechnology.com/packages/itg-django-utils-0.1.12.tar.gz";
|
||||
hash = "sha256-LbOl4L4UZbRTlLuBL4L3ser6+WDuP3R5a03EIh1xSK8=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
django
|
||||
djangorestframework
|
||||
graypy
|
||||
setuptools
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "ITG specific stuff";
|
||||
homepage = "http://www.ivrtechnology.com";
|
||||
maintainers = [];
|
||||
};
|
||||
|
||||
doCheck = false;
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, python3
|
||||
, fetchFromGitHub
|
||||
, installShellFiles
|
||||
}:
|
||||
|
||||
with python3.pkgs;
|
||||
|
||||
let
|
||||
|
||||
runtimeDeps = ps: with ps; [
|
||||
certifi
|
||||
setuptools
|
||||
pip
|
||||
virtualenv
|
||||
virtualenv-clone
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isAndroid [
|
||||
pyjnius
|
||||
];
|
||||
|
||||
pythonEnv = python3.withPackages runtimeDeps;
|
||||
|
||||
in buildPythonApplication rec {
|
||||
pname = "pipenv";
|
||||
version = "2023.11.15";
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "pypa";
|
||||
repo = "pipenv";
|
||||
rev = "refs/tags/v${version}";
|
||||
hash = "sha256-kxwyws22xJkqBy/hXXcAPHZR2NgZHbmwZr9vYqce434=";
|
||||
};
|
||||
|
||||
env.LC_ALL = "en_US.UTF-8";
|
||||
|
||||
nativeBuildInputs = [
|
||||
installShellFiles
|
||||
setuptools
|
||||
wheel
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# pipenv invokes python in a subprocess to create a virtualenv
|
||||
# and to call setup.py.
|
||||
# It would use sys.executable, which in our case points to a python that
|
||||
# does not have the required dependencies.
|
||||
substituteInPlace pipenv/utils/virtualenv.py \
|
||||
--replace "sys.executable" "'${pythonEnv.interpreter}'"
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = runtimeDeps python3.pkgs;
|
||||
|
||||
preCheck = ''
|
||||
export HOME="$TMPDIR"
|
||||
'';
|
||||
|
||||
nativeCheckInputs = [
|
||||
mock
|
||||
pytestCheckHook
|
||||
pytest-xdist
|
||||
pytz
|
||||
requests
|
||||
];
|
||||
|
||||
disabledTests = [
|
||||
"test_convert_deps_to_pip"
|
||||
"test_download_file"
|
||||
];
|
||||
|
||||
disabledTestPaths = [
|
||||
"tests/integration"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
installShellCompletion --cmd pipenv \
|
||||
--bash <(_PIPENV_COMPLETE=bash_source $out/bin/pipenv) \
|
||||
--zsh <(_PIPENV_COMPLETE=zsh_source $out/bin/pipenv) \
|
||||
--fish <(_PIPENV_COMPLETE=fish_source $out/bin/pipenv)
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Python Development Workflow for Humans";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.all;
|
||||
maintainers = with maintainers; [ berdario ];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user