nixpkgs/pkgs/development/python-modules/proxy-py/default.nix
Robert Schütz 1a04744f74 treewide: remove superfluous disabled
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:

    pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
    for f in $(find -name '*.nix'); do
        grep -q "$pattern" "$f" || continue
        sed -i "/$pattern/d" "$f"
        if [ $(grep -c pythonOlder "$f") == 1 ]; then
            sed -i '/^\s*pythonOlder,\s*$/d' "$f"
        fi
        nixfmt "$f"
    done
2026-01-11 09:34:20 -08:00

92 lines
1.6 KiB
Nix

{
lib,
bash,
buildPythonPackage,
fetchFromGitHub,
gnumake,
h2,
hpack,
httpx,
hyperframe,
openssl,
paramiko,
pytest-asyncio,
pytest-cov-stub,
pytest-mock,
pytest-xdist,
pytestCheckHook,
requests,
setuptools-scm,
typing-extensions,
}:
buildPythonPackage rec {
pname = "proxy-py";
version = "2.4.10";
pyproject = true;
src = fetchFromGitHub {
owner = "abhinavsingh";
repo = "proxy.py";
tag = "v${version}";
hash = "sha256-47Qt8J60QFfHUSquD17xMfl+wBTsSimaPSRvS/sSPMI=";
};
postPatch = ''
substituteInPlace Makefile \
--replace "SHELL := /bin/bash" "SHELL := ${bash}/bin/bash"
'';
build-system = [ setuptools-scm ];
dependencies = [
paramiko
typing-extensions
];
nativeCheckInputs = [
gnumake
h2
hpack
httpx
hyperframe
openssl
pytest-asyncio
pytest-cov-stub
pytest-mock
pytest-xdist
pytestCheckHook
requests
];
__darwinAllowLocalNetworking = true;
preCheck = ''
export HOME=$(mktemp -d);
'';
disabledTests = [
# Test requires network access
"http"
"http2"
"proxy"
"web_server"
# Location is not writable
"test_gen_csr"
"test_gen_public_key"
# Tests run into a timeout
"integration"
# Crashes
"test_grout"
];
pythonImportsCheck = [ "proxy" ];
meta = {
description = "Python proxy framework";
homepage = "https://github.com/abhinavsingh/proxy.py";
changelog = "https://github.com/abhinavsingh/proxy.py/releases/tag/${src.tag}";
license = with lib.licenses; [ bsd3 ];
maintainers = with lib.maintainers; [ fab ];
};
}