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

Fix tests on i386 #59

Merged
merged 1 commit into from
Jul 20, 2020
Merged

Fix tests on i386 #59

merged 1 commit into from
Jul 20, 2020

Conversation

avalentino
Copy link
Contributor

The test on get_equatorial_crossing_time fails on i386 platforms (see also https://tests.reproducible-builds.org/debian/rb-pkg/bullseye/i386/pyorbital.html)

======================================================================
ERROR: test_get_equatorial_crossing_time (pyorbital.tests.test_orbital.Test)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.8/unittest/mock.py", line 1325, in patched
    return func(*newargs, **newkeywargs)
  File "/build/pyorbital-1.6.0/pyorbital/tests/test_orbital.py", line 189, in test_get_equatorial_crossing_time
    self.assertTrue((res - exp) < timedelta(seconds=0.01))
TypeError: unsupported operand type(s) for -: 'NoneType' and 'datetime.datetime'

----------------------------------------------------------------------
Ran 38 tests in 1.565s

FAILED (errors=1)

This PR should fix the issue.

  • Tests passed
  • Passes flake8 pyorbital

@coveralls
Copy link

coveralls commented Jul 20, 2020

Coverage Status

Coverage increased (+0.03%) to 86.886% when pulling a86f627 on avalentino:fix-tests-on-i386 into 3ff7a6b on pytroll:master.

Copy link
Member

@djhoese djhoese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Just curious, what would it mean for you @avalentino if pytroll dropped 32-bit support for some of its packages?

@avalentino
Copy link
Contributor Author

Just curious, what would it mean for you @avalentino if pytroll dropped 32-bit support for some of its packages?

@djhoese, personally I don't use i386.
The issue has been discovered in the context of the maintenance of the debian package for pyorbital (I'm one of the maintainers).
If I'm not wrong it should be technically possible to support only a restricted set of architectures in debian for a specific package.
Anyway, IMHO, it would be nice to support as much architectures as possible, specially for pure Python packages.

@djhoese
Copy link
Member

djhoese commented Jul 20, 2020

specially for pure Python packages.

Yes, absolutely.

Mostly just curious if some of the C-using packages (pyresample, python-geotiepoints, etc) were to do something 64-bit only. Anyway, we'll cross that bridge when we come to it.

Thanks again.

@djhoese djhoese merged commit 9716504 into pytroll:master Jul 20, 2020
@avalentino avalentino deleted the fix-tests-on-i386 branch July 20, 2020 16:32
@mraspaud mraspaud added the bug label Jul 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants