Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python37Packages.dateparser tests fail #52766

Closed
ivan opened this issue Dec 24, 2018 · 2 comments
Closed

python37Packages.dateparser tests fail #52766

ivan opened this issue Dec 24, 2018 · 2 comments

Comments

@ivan
Copy link
Member

ivan commented Dec 24, 2018

Issue description

python36Packages.dateparser tests pass, while python37Packages.dateparser tests fail with:

======================================================================
FAIL: test_detection_24_es (tests.test_search.TestTranslateSearch)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/nix/store/5v7lfgvnwl87vp4x18w1bhp14s7sw12m-python3.7-parameterized-0.6.1/lib/python3.7/site-packages/parameterized/parameterized.py", line 392, in standalone_func
    return func(*(a + p.args), **p.kwargs)
  File "/build/dateparser/tests/test_search.py", line 619, in test_detection
    self.assertEqual(result, shortname)
AssertionError: 'eo' != 'es'
- eo
+ es


======================================================================
FAIL: test_search_and_parse_26_es (tests.test_search.TestTranslateSearch)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/nix/store/5v7lfgvnwl87vp4x18w1bhp14s7sw12m-python3.7-parameterized-0.6.1/lib/python3.7/site-packages/parameterized/parameterized.py", line 392, in standalone_func
    return func(*(a + p.args), **p.kwargs)
  File "/build/dateparser/dateparser/conf.py", line 81, in wrapper
    return f(*args, **kwargs)
  File "/build/dateparser/tests/test_search.py", line 413, in test_search_and_parse
    self.assertEqual(result, expected)
AssertionError: Lists differ: [('a', datetime.datetime(2000, 1, 1, 0, 0)),[479 chars] 0))] != [('de 1939', datetime.datetime(1939, 1, 1, 0[51 chars] 0))]

First differing element 0:
('a', datetime.datetime(2000, 1, 1, 0, 0))
('de 1939', datetime.datetime(1939, 1, 1, 0, 0))

First list contains 10 additional elements.
First extra element 2:
('a', datetime.datetime(2000, 1, 1, 0, 0))

Diff is 670 characters long. Set self.maxDiff to None to see it.

======================================================================
FAIL: test_search_date_string_31_es (tests.test_search.TestTranslateSearch)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/nix/store/5v7lfgvnwl87vp4x18w1bhp14s7sw12m-python3.7-parameterized-0.6.1/lib/python3.7/site-packages/parameterized/parameterized.py", line 392, in standalone_func
    return func(*(a + p.args), **p.kwargs)
  File "/build/dateparser/tests/test_search.py", line 210, in test_search_date_string
    self.assertEqual(result, datetime_string)
AssertionError: 'M' != 'Miércoles 31 Diciembre 2014'
- M
+ Miércoles 31 Diciembre 2014


----------------------------------------------------------------------
Ran 209 tests in 3.805s

FAILED (failures=3)

Official Hydra sees the same thing: https://hydra.nixos.org/eval/1497276?filter=dateparser&compare=1497263&full=

Upstream's tests pass on Python 3.7 with their Travis setup. (That is a build of a recent commit, but I still see the same failures after pointing src = at a checkout of https://github.com/scrapinghub/dateparser)

Does anyone have any ideas?

Steps to reproduce

With nixpkgs master, nix-env -iA python37Packages.dateparser

@ck3d ck3d mentioned this issue Jan 28, 2019
10 tasks
@dotlambda
Copy link
Member

@dotlambda
Copy link
Member

dotlambda commented Jan 29, 2019

As long as this problem remains, the best thing to do is using python36 for affected application. Switching to python36 should be done in commits that don't change anything else and that reference this issue in their commit message so that they can easily be reverted.
Simply skipping the tests does not make much sense since these are real incompatibilities.

dotlambda pushed a commit to dotlambda/nixpkgs that referenced this issue Jan 29, 2019
dateparser tests fail on python36: NixOS#52766
ck3d added a commit to ck3d/nixpkgs that referenced this issue Jan 30, 2019
still not working, since depending python modules uses python37 instead
of wanted python36
dotlambda pushed a commit to dotlambda/nixpkgs that referenced this issue Jan 31, 2019
dateparser tests fail on python37:
NixOS#52766
dotlambda pushed a commit to dotlambda/nixpkgs that referenced this issue Feb 1, 2019
dateparser tests fail on python37:
NixOS#52766
dotlambda pushed a commit to dotlambda/nixpkgs that referenced this issue Feb 12, 2019
@FRidh FRidh closed this as completed in 9fe2447 Feb 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants