2020-05-15 21:57:56 +00:00
|
|
|
{ buildPythonPackage
|
2020-10-11 12:50:04 +00:00
|
|
|
, fetchPypi
|
2020-05-15 21:57:56 +00:00
|
|
|
, pytest
|
|
|
|
, tqdm
|
|
|
|
, docopt
|
|
|
|
, requests
|
|
|
|
, jsonpatch
|
|
|
|
, schema
|
|
|
|
, responses
|
|
|
|
, lib
|
|
|
|
, glibcLocales
|
|
|
|
, setuptools
|
2021-12-06 16:07:01 +00:00
|
|
|
, urllib3
|
2022-03-30 09:31:56 +00:00
|
|
|
, pythonOlder
|
2020-05-15 21:57:56 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "internetarchive";
|
2022-06-16 17:23:12 +00:00
|
|
|
version = "3.0.2";
|
2022-03-30 09:31:56 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-10-11 12:50:04 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-06-16 17:23:12 +00:00
|
|
|
sha256 = "sha256-3oVkZcLvaFIYTQi/1ZwMoBkEhls3OiezgwNKxrQSjrY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2020-05-15 21:57:56 +00:00
|
|
|
tqdm
|
2020-04-24 23:36:52 +00:00
|
|
|
docopt
|
|
|
|
requests
|
|
|
|
jsonpatch
|
|
|
|
schema
|
2022-06-16 17:23:12 +00:00
|
|
|
setuptools # needs pkg_resources at runtime
|
2021-12-06 16:07:01 +00:00
|
|
|
urllib3
|
2022-03-30 09:31:56 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
checkInputs = [ pytest responses glibcLocales ];
|
|
|
|
|
|
|
|
# tests depend on network
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
LC_ALL=en_US.utf-8 pytest tests
|
|
|
|
'';
|
|
|
|
|
2020-10-11 12:50:04 +00:00
|
|
|
pythonImportsCheck = [ "internetarchive" ];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
2020-05-15 21:57:56 +00:00
|
|
|
description = "A Python and Command-Line Interface to Archive.org";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/jjjake/internetarchive";
|
2021-04-08 16:26:57 +00:00
|
|
|
changelog = "https://github.com/jjjake/internetarchive/raw/v${version}/HISTORY.rst";
|
|
|
|
license = licenses.agpl3Plus;
|
2020-05-15 21:57:56 +00:00
|
|
|
maintainers = [ maintainers.marsam ];
|
2022-06-16 17:23:12 +00:00
|
|
|
mainProgram = "ia";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|