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

OSX test failures #3152

Closed
matthew-brett opened this issue Jun 26, 2014 · 7 comments
Closed

OSX test failures #3152

matthew-brett opened this issue Jun 26, 2014 · 7 comments

Comments

@matthew-brett
Copy link
Contributor

I've been slaving away on getting Matt Terry's mpl test grid working with the latest OSX environments:

https://travis-ci.org/matthew-brett/mpl_mac_testing/builds/28506492

I'm getting what look like genuine test failures very near the end of this log here:

https://api.travis-ci.org/jobs/28506496/log.txt?deansi=true

Here are the failures. Are any of these familiar?

======================================================================
ERROR: Failure: AttributeError ('module' object has no attribute 'test_dates')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/loader.py", line 403, in loadTestsFromName
    module = resolve_name(addr.module)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/util.py", line 321, in resolve_name
    obj = getattr(obj, part)
AttributeError: 'module' object has no attribute 'test_dates'

======================================================================
ERROR: Failure: AttributeError ('module' object has no attribute 'test_legend')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/loader.py", line 403, in loadTestsFromName
    module = resolve_name(addr.module)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/util.py", line 321, in resolve_name
    obj = getattr(obj, part)
AttributeError: 'module' object has no attribute 'test_legend'

======================================================================
ERROR: Failure: AttributeError ('module' object has no attribute 'test_patheffects')
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/failure.py", line 39, in runTest
    raise self.exc_val.with_traceback(self.tb)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/loader.py", line 403, in loadTestsFromName
    module = resolve_name(addr.module)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/util.py", line 321, in resolve_name
    obj = getattr(obj, part)
AttributeError: 'module' object has no attribute 'test_patheffects'

======================================================================
ERROR: matplotlib.tests.test_backend_ps.test_savefig_to_stringio_with_distiller
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/nose-1.3.3-py3.3.egg/nose/case.py", line 198, in runTest
    self.test(*self.arg)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/testing/decorators.py", line 110, in wrapped_function
    func(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/tests/test_backend_ps.py", line 53, in test_savefig_to_stringio_with_distiller
    _test_savefig_to_stringio()
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/tests/test_backend_ps.py", line 27, in _test_savefig_to_stringio
    plt.savefig(buffer, format=format)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/pyplot.py", line 571, in savefig
    res = fig.savefig(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/figure.py", line 1470, in savefig
    self.canvas.print_figure(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backend_bases.py", line 2192, in print_figure
    **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 985, in print_ps
    return self._print_ps(outfile, 'ps', *args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 1016, in _print_ps
    **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 1218, in _print_figure
    gs_distill(tmpfile, isEPSF, ptype=papertype, bbox=bbox)
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 1520, in gs_distill
    if ps_backend_helper.supports_ps2write: # gs version >= 9
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 109, in supports_ps2write
    return self.gs_version[0] >= 9
  File "/Library/Frameworks/Python.framework/Versions/3.3/lib/python3.3/site-packages/matplotlib-1.4.x-py3.3-macosx-10.6-intel.egg/matplotlib/backends/backend_ps.py", line 99, in gs_version
    gs_version = tuple(map(int, ver.strip().split(".")))
ValueError: invalid literal for int() with base 10: ''
@tacaswell
Copy link
Member

Some of those looks like there are import errors in test modules. Errors on import are silently snarfed by nose so the module for test_* does not get defined so the way the test scripts are you get the attribute error when you run the tests.

@matthew-brett
Copy link
Contributor Author

Thanks for the comment; I will look further for import errors.

Remaining errors look like backward incompatibility with numpy 1.5.1:

https://s3.amazonaws.com/archive.travis-ci.org/jobs/29152366/log.txt

I don't see the same error testing (on Python 3) against numpy 1.71. Is it possible the 1.5 compatibility needs a review?

The last error is in all the test runs. Looking at the code, maybe the test for the ghostscript version is failing returning an empty string, then resulting in an error converting to int.

@matthew-brett
Copy link
Contributor Author

Looking deeper - I think that's the right explanation of the gs_version error, but I'm not sure how matplotlib.backends.backend_ps.PsBackendHelper should behave when ghostscript is not present. Should that backend not get instantiated at all in the tests?

@matthew-brett
Copy link
Contributor Author

Import errors caused by missing 'mock' module in Python 3 : #3189

@tacaswell
Copy link
Member

@matthew-brett Closing this, please re-open if #3189 did not fully address this.

@matthew-brett
Copy link
Contributor Author

No, #3189 only addressed the import failures. There are failures now from incompatibility with numpy 1.5, and with missing ghostscript. I am fixing the first set of failures but was hoping for advice on the second - see #3152 (comment)

@tacaswell tacaswell reopened this Jul 6, 2014
@tacaswell
Copy link
Member

We dropped 1.5 so this is no longer relevant.

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

2 participants