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

tests fail on 32 bit platforms #454

Closed
brianmay opened this issue Jan 28, 2017 · 3 comments
Closed

tests fail on 32 bit platforms #454

brianmay opened this issue Jan 28, 2017 · 3 comments

Comments

@brianmay
Copy link

Such as i386.

See https://bugs.debian.org/849652

======================================================================
ERROR: test_date_time_this_period (faker.tests.FactoryTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "faker/tests/__init__.py", line 389, in test_date_time_this_period
    self.assertTrue(self._datetime_to_time(provider.date_time_this_century(before_now=False, after_now=True)) >= self._datetime_to_time(datetime.datetime.now()))
  File "faker/providers/date_time/__init__.py", line 403, in date_time_this_century
    return cls.date_time_between_dates(now, next_century_start, tzinfo)
  File "faker/providers/date_time/__init__.py", line 381, in date_time_between_dates
    datetime_to_timestamp(datetime_end),
  File "faker/providers/date_time/__init__.py", line 22, in datetime_to_timestamp
    return mktime(dt.timetuple())
OverflowError: mktime argument out of range

======================================================================
ERROR: test_date_time_this_period_with_tzinfo (faker.tests.FactoryTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "faker/tests/__init__.py", line 418, in test_date_time_this_period_with_tzinfo
    provider.date_time_this_century(before_now=False, after_now=True, tzinfo=utc) >= datetime.datetime.now()
  File "faker/providers/date_time/__init__.py", line 403, in date_time_this_century
    return cls.date_time_between_dates(now, next_century_start, tzinfo)
  File "faker/providers/date_time/__init__.py", line 381, in date_time_between_dates
    datetime_to_timestamp(datetime_end),
  File "faker/providers/date_time/__init__.py", line 21, in datetime_to_timestamp
    dt = dt.astimezone(tzlocal())
  File "/usr/lib/python2.7/dist-packages/dateutil/tz/tz.py", line 99, in utcoffset
    if self._isdst(dt):
  File "/usr/lib/python2.7/dist-packages/dateutil/tz/tz.py", line 143, in _isdst
    return time.localtime(timestamp+time.timezone).tm_isdst
ValueError: timestamp out of range for platform time_t
@fcurella
Copy link
Collaborator

fcurella commented Feb 21, 2017

dupe of #408

@malefice
Copy link
Contributor

@fcurella it looks like you already fixed this and closed the other issue. alright to close this as well?

@fcurella
Copy link
Collaborator

Thank you for keeping tabs, @malefice ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants