2018-12-26 00:10:21 +01:00
|
|
|
{ lib
|
2018-10-26 02:52:36 +02:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pytest
|
|
|
|
, pytestrunner
|
2018-12-26 00:10:21 +01:00
|
|
|
, functools32
|
2018-10-26 02:52:36 +02:00
|
|
|
, six
|
|
|
|
, w3lib
|
|
|
|
, lxml
|
|
|
|
, cssselect
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "parsel";
|
2018-11-04 11:35:08 +01:00
|
|
|
version = "1.5.1";
|
2018-10-26 02:52:36 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-11-04 11:35:08 +01:00
|
|
|
sha256 = "9ccd82b8a122345601f6f9209e972c0e8c3518a188fcff2d37cb4d7bc570b4b8";
|
2018-10-26 02:52:36 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ pytest pytestrunner ];
|
2018-12-26 00:10:21 +01:00
|
|
|
propagatedBuildInputs = [ functools32 six w3lib lxml cssselect ];
|
2018-10-26 02:52:36 +02:00
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
py.test
|
|
|
|
'';
|
|
|
|
|
2018-12-26 00:10:21 +01:00
|
|
|
meta = with lib; {
|
2018-10-26 02:52:36 +02:00
|
|
|
homepage = "https://github.com/scrapy/parsel";
|
|
|
|
description = "Parsel is a library to extract data from HTML and XML using XPath and CSS selectors";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|