1{ stdenv, buildPythonPackage, fetchFromGitHub, ua-parser }: 2 3buildPythonPackage rec { 4 pname = "user-agents"; 5 version = "1.1.0"; 6 7 # PyPI is missing devices.json 8 src = fetchFromGitHub { 9 owner = "selwin"; 10 repo = "python-user-agents"; 11 rev = "v${version}"; 12 sha256 = "14kxd780zhp8718xr1z63xffaj3bvxgr4pldh9sv943m4hvi0gw5"; 13 }; 14 15 propagatedBuildInputs = [ ua-parser ]; 16 17 meta = with stdenv.lib; { 18 description = "A Python library to identify devices by parsing user agent strings"; 19 homepage = https://github.com/selwin/python-user-agents; 20 license = licenses.mit; 21 platforms = platforms.unix; 22 maintainers = with maintainers; [ dotlambda ]; 23 }; 24}