Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at lanzaboote 98 lines 1.6 kB view raw
1{ lib 2, stdenv 3, altair 4, blinker 5, buildPythonPackage 6, cachetools 7, click 8, fetchPypi 9, gitpython 10, importlib-metadata 11, numpy 12, packaging 13, pandas 14, pillow 15, protobuf 16, pyarrow 17, pydeck 18, pympler 19, python-dateutil 20, pythonOlder 21, pythonRelaxDepsHook 22, requests 23, rich 24, tenacity 25, toml 26, tornado 27, typing-extensions 28, tzlocal 29, validators 30, watchdog 31}: 32 33buildPythonPackage rec { 34 pname = "streamlit"; 35 version = "1.27.2"; 36 format = "setuptools"; 37 38 disabled = pythonOlder "3.8"; 39 40 src = fetchPypi { 41 inherit pname version format; 42 hash = "sha256-M/muDeW31ZzX2rqHdUxU7IN6dsJKz8QdH45RSPIJA+4="; 43 }; 44 45 nativeBuildInputs = [ pythonRelaxDepsHook ]; 46 47 pythonRelaxDeps = [ 48 "pillow" 49 "pydeck" 50 ]; 51 52 propagatedBuildInputs = [ 53 altair 54 blinker 55 cachetools 56 click 57 gitpython 58 importlib-metadata 59 numpy 60 packaging 61 pandas 62 pillow 63 protobuf 64 pyarrow 65 pydeck 66 pympler 67 python-dateutil 68 requests 69 rich 70 tenacity 71 toml 72 tornado 73 typing-extensions 74 tzlocal 75 validators 76 ] ++ lib.optionals (!stdenv.isDarwin) [ 77 watchdog 78 ]; 79 80 # pypi package does not include the tests, but cannot be built with fetchFromGitHub 81 doCheck = false; 82 83 pythonImportsCheck = [ 84 "streamlit" 85 ]; 86 87 postInstall = '' 88 rm $out/bin/streamlit.cmd # remove windows helper 89 ''; 90 91 meta = with lib; { 92 homepage = "https://streamlit.io/"; 93 changelog = "https://github.com/streamlit/streamlit/releases/tag/${version}"; 94 description = "The fastest way to build custom ML tools"; 95 maintainers = with maintainers; [ natsukium yrashk ]; 96 license = licenses.asl20; 97 }; 98}