1{ 2 aiohttp, 3 apscheduler, 4 beautifulsoup4, 5 brotli, 6 buildPythonPackage, 7 colorama, 8 fetchPypi, 9 httpx, 10 lib, 11 lxml, 12 pillow, 13 pycryptodomex, 14 pyjwt, 15 pyyaml, 16 qrcode, 17 qrcode-terminal, 18 rsa, 19 setuptools, 20 setuptools-scm, 21 tqdm, 22 yarl, 23 nix-update-script, 24}: 25buildPythonPackage rec { 26 pname = "bilibili-api-python"; 27 version = "17.3.0"; 28 pyproject = true; 29 30 src = fetchPypi { 31 pname = "bilibili_api_python"; 32 inherit version; 33 hash = "sha256-Rlnz3ws023x5MiwabGR4gARH0bdUgucoixIMRqj+Z64="; 34 }; 35 36 # The upstream uses requirements.txt, which overly strict version constraints. 37 pythonRelaxDeps = [ 38 "beautifulsoup4" 39 "lxml" 40 "pillow" 41 ]; 42 43 build-system = [ 44 setuptools-scm 45 setuptools 46 ]; 47 48 dependencies = [ 49 aiohttp 50 beautifulsoup4 51 colorama 52 lxml 53 pyyaml 54 brotli 55 httpx 56 qrcode 57 apscheduler 58 rsa 59 pillow 60 tqdm 61 yarl 62 pycryptodomex 63 pyjwt 64 qrcode-terminal 65 ]; 66 67 # tests require network 68 doCheck = false; 69 70 pythonImportsCheck = [ "bilibili_api" ]; 71 72 passthru.updateScript = nix-update-script { }; 73 74 meta = { 75 changelog = "https://github.com/Nemo2011/bilibili-api/releases/tag/${version}"; 76 description = "Python module providing convenient integration for various Bilibili API along with some additional common features"; 77 homepage = "https://nemo2011.github.io/bilibili-api"; 78 license = lib.licenses.gpl3Plus; 79 maintainers = with lib.maintainers; [ moraxyc ]; 80 }; 81}