Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ buildPythonPackage, fetchFromGitHub, pytest, six, clint, pyyaml, docopt 2, requests, jsonpatch, args, schema, responses, backports_csv, isPy3k 3, lib, glibcLocales }: 4 5buildPythonPackage rec { 6 pname = "internetarchive"; 7 version = "1.8.1"; 8 9 # Can't use pypi, data files for tests missing 10 src = fetchFromGitHub { 11 owner = "jjjake"; 12 repo = "internetarchive"; 13 rev = "v${version}"; 14 sha256 = "1fdb0kr9hzgyh0l8d02khcjpsgyd63nbablhc49ncdsav3dhhr3f"; 15 }; 16 17 propagatedBuildInputs = [ 18 six 19 clint 20 pyyaml 21 docopt 22 requests 23 jsonpatch 24 args 25 schema 26 ] ++ lib.optional (!isPy3k) backports_csv; 27 28 checkInputs = [ pytest responses glibcLocales ]; 29 30 # tests depend on network 31 doCheck = false; 32 33 checkPhase = '' 34 LC_ALL=en_US.utf-8 pytest tests 35 ''; 36 37 meta = with lib; { 38 description = "A python wrapper for the various Internet Archive APIs"; 39 homepage = https://github.com/jjjake/internetarchive; 40 license = licenses.agpl3; 41 }; 42}