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

test_mplot3d.test_quiver3d tests require np.meshgrid from numpy >= 1.7.0 #3297

Closed
matthew-brett opened this issue Jul 24, 2014 · 5 comments
Closed
Milestone

Comments

@matthew-brett
Copy link
Contributor

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

3 errors of form:

======================================================================
ERROR: test suite for <class 'tests.test_mplot3d.test_quiver3d_empty'>
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose/plugins/multiprocess.py", line 788, in run
    self.setUp()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose/suite.py", line 291, in setUp
    self.setupContext(ancestor)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose/plugins/multiprocess.py", line 770, in setupContext
    super(NoSharedFixtureContextSuite, self).setupContext(context)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose/suite.py", line 314, in setupContext
    try_run(context, names)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nose/util.py", line 470, in try_run
    return func()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/testing/decorators.py", line 134, in setup_class
    cls._func()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/mpl_toolkits/tests/test_mplot3d.py", line 180, in test_quiver3d_empty
    x, y, z = np.meshgrid([], [], [])
TypeError: meshgrid() takes exactly 2 arguments (3 given)

np.meshgrid only allowed 2 arguments before numpy 1.7.0. I think this means these tests as currently written need numpy > 1.7.0 .

@tacaswell tacaswell added this to the v1.4.0 milestone Jul 24, 2014
@tacaswell
Copy link
Member

We can just switch to using np.ogrid + some extra math.

We shouldn't use np.arange like that anyway (should be using linspace).

@WeatherGod
Copy link
Member

Writing up a fix for this. In the process, I realize that there is a bug in
quiver. I will submit all of it as a single PR.

On Thu, Jul 24, 2014 at 8:55 AM, Thomas A Caswell notifications@github.com
wrote:

We can just switch to using np.ogrid + some extra math.

We shouldn't use np.arange like that anyway (should be using linspace).


Reply to this email directly or view it on GitHub
#3297 (comment)
.

@WeatherGod
Copy link
Member

Created #3300 to fix this and some other issues discovered when switching over to use np.ogrid[]. Thanks for noticing the problem!

@matthew-brett
Copy link
Contributor Author

Relevant current v1.4.x branch errors fixed - thanks a lot for the fast work:

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

@tacaswell
Copy link
Member

fixed by #3300

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