Merge pull request #189312 from mweinelt/dateparser-patch-flaky-test

This commit is contained in:
Martin Weinelt 2022-09-01 19:40:58 +02:00 committed by GitHub
commit dc47970fbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,6 +29,13 @@ buildPythonPackage rec {
sha256 = "sha256-bDup3q93Zq+pvwsy/lQy2byOMjG6C/+7813hWQMbZRU=";
};
postPatch = ''
# https://github.com/scrapinghub/dateparser/issues/1053
substituteInPlace tests/test_search.py --replace \
"('June 2020', datetime.datetime(2020, 6, datetime.datetime.utcnow().day, 0, 0))," \
"('June 2020', datetime.datetime(2020, 6, min(30, datetime.datetime.utcnow().day), 0, 0)),"
'';
propagatedBuildInputs = [
# install_requires
python-dateutil pytz regex tzlocal