22 buildPythonPackage rec {
26 disabled = pythonOlder "3.7";
28 format = "setuptools";
30 src = fetchFromGitHub {
31 owner = "scrapinghub";
33 rev = "refs/tags/v${version}";
34 hash = "sha256-52g8defF5bsisBv2QoyUymXcf0sljOI9PjeR4l0Pw6k=";
37 propagatedBuildInputs = [
44 passthru.optional-dependencies = {
45 calendars = [ hijri-converter convertdate ];
46 fasttext = [ fasttext ];
47 langdetect = [ langdetect ];
57 ] ++ lib.flatten (lib.attrValues passthru.optional-dependencies);
60 export HOME="$TEMPDIR"
63 # Upstream only runs the tests in tests/ in CI, others use git clone
64 pytestFlagsArray = [ "tests" ];
68 "test_custom_language_detect_fast_text_0"
69 "test_custom_language_detect_fast_text_1"
72 pythonImportsCheck = [ "dateparser" ];
75 changelog = "https://github.com/scrapinghub/dateparser/blob/${src.rev}/HISTORY.rst";
76 description = "Date parsing library designed to parse dates from HTML pages";
77 homepage = "https://github.com/scrapinghub/dateparser";
78 license = licenses.bsd3;
79 maintainers = with maintainers; [ dotlambda ];