nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 74 lines 1.5 kB view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 cryptography, 6 fetchFromGitHub, 7 keyring, 8 pytestCheckHook, 9 playwright, 10 setuptools, 11 setuptools-scm, 12}: 13 14buildPythonPackage rec { 15 pname = "pycookiecheat"; 16 version = "0.11"; 17 pyproject = true; 18 19 src = fetchFromGitHub { 20 owner = "n8henrie"; 21 repo = "pycookiecheat"; 22 tag = version; 23 hash = "sha256-hP4J41ctAkrC6HIeKu6ITzK3W0PB7/tCz0cjP42I/J8="; 24 }; 25 26 pythonRelaxDeps = [ 27 "cryptography" 28 "keyring" 29 ]; 30 31 build-system = [ 32 setuptools 33 setuptools-scm 34 ]; 35 36 dependencies = [ 37 cryptography 38 keyring 39 ]; 40 41 nativeCheckInputs = [ 42 playwright 43 pytestCheckHook 44 ]; 45 46 pythonImportsCheck = [ "pycookiecheat" ]; 47 48 preCheck = '' 49 export HOME=$(mktemp -d) 50 ''; 51 52 disabledTests = [ 53 # Tests want to use playwright executable 54 "test_fake_cookie" 55 "test_firefox_cookies" 56 "test_firefox_get_default_profile" 57 "test_firefox_no_cookies" 58 "test_load_firefox_cookie_db" 59 "test_no_cookies" 60 "test_warns_for_string_browser" 61 ] 62 ++ lib.optionals stdenv.hostPlatform.isDarwin [ "test_slack_config" ]; 63 64 meta = { 65 description = "Borrow cookies from your browser's authenticated session for use in Python scripts"; 66 homepage = "https://github.com/n8henrie/pycookiecheat"; 67 changelog = "https://github.com/n8henrie/pycookiecheat/blob/${src.tag}/CHANGELOG.md"; 68 license = lib.licenses.mit; 69 maintainers = with lib.maintainers; [ 70 fab 71 n8henrie 72 ]; 73 }; 74}