2021-01-15 22:18:51 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
2022-03-30 09:31:56 +00:00
|
|
|
, pythonOlder
|
2021-01-15 22:18:51 +00:00
|
|
|
, fetchPypi
|
|
|
|
, requests
|
|
|
|
, requests-toolbelt
|
|
|
|
, pyparsing
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "cloudscraper";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "1.2.71";
|
2022-03-30 09:31:56 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2021-01-15 22:18:51 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2023-05-24 13:37:59 +00:00
|
|
|
hash = "sha256-QpxuiqaRbVutXIperFDz6lPJrCJhb2yyGxjcxxUX0NM=";
|
2021-01-15 22:18:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
requests
|
|
|
|
requests-toolbelt
|
|
|
|
pyparsing
|
|
|
|
];
|
|
|
|
|
|
|
|
# The tests require several other dependencies, some of which aren't in
|
|
|
|
# nixpkgs yet, and also aren't included in the PyPI bundle. TODO.
|
|
|
|
doCheck = false;
|
|
|
|
|
2022-03-30 09:31:56 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"cloudscraper"
|
|
|
|
];
|
2021-01-15 22:18:51 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
2022-03-30 09:31:56 +00:00
|
|
|
description = "Python module to bypass Cloudflare's anti-bot page";
|
2021-02-05 17:12:51 +00:00
|
|
|
homepage = "https://github.com/venomous/cloudscraper";
|
2022-11-27 09:42:12 +00:00
|
|
|
changelog = "https://github.com/VeNoMouS/cloudscraper/releases/tag/${version}";
|
2021-01-15 22:18:51 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ kini ];
|
|
|
|
};
|
|
|
|
}
|