about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/selenium-wire/default.nix
blob: bbc98666394b9b2ba50ce6562a90b04b766253d0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
{ lib
, blinker
, brotli
, buildPythonPackage
, certifi
, fetchFromGitHub
, h2
, hyperframe
, kaitaistruct
, pyasn1
, httpbin
, pyopenssl
, pyparsing
, pysocks
, gunicorn
, pytestCheckHook
, pythonOlder
, selenium
, setuptools
, wsproto
, zstandard
}:

buildPythonPackage rec {
  pname = "selenium-wire";
  version = "5.1.0";
  pyproject = true;

  disabled = pythonOlder "3.7";

  src = fetchFromGitHub {
    owner = "wkeeling";
    repo = "selenium-wire";
    rev = "refs/tags/${version}";
    hash = "sha256-KgaDxHS0dAK6CT53L1qqx1aORMmkeaiXAUtGC82hiIQ=";
  };

  nativeBuildInputs = [
    setuptools
  ];

  propagatedBuildInputs = [
    blinker
    brotli
    certifi
    h2
    hyperframe
    kaitaistruct
    pyasn1
    pyopenssl
    pyparsing
    pysocks
    selenium
    wsproto
    zstandard
  ];

  nativeCheckInputs = [
    gunicorn
    httpbin
    pytestCheckHook
  ];

  pythonImportsCheck = [
    "seleniumwire"
  ];

  disabledTestPaths = [
    # Don't run End2End tests
    "tests/end2end/test_end2end.py"
  ];

  meta = with lib; {
    description = "Extends Selenium's Python bindings to give you the ability to inspect requests made by the browser";
    homepage = "https://github.com/wkeeling/selenium-wire";
    changelog = "https://github.com/wkeeling/selenium-wire/blob/${version}/HISTORY.rst";
    license = licenses.mit;
    maintainers = with maintainers; [ fab ];
  };
}