Skip to content

Tests cannot run with setuptools 18.4 #5315

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

Closed
itoijala opened this issue Oct 25, 2015 · 7 comments
Closed

Tests cannot run with setuptools 18.4 #5315

itoijala opened this issue Oct 25, 2015 · 7 comments

Comments

@itoijala
Copy link
Contributor

This is a setuptools regression, 18.3.2 works fine.
See https://bitbucket.org/pypa/setuptools/commits/cf565b66b855dd4df189b679206f9fb113681737.
This will probably be fixed there, I just wanted to make you aware in case it is not.

Using matplotlib from master:

$ python setup.py test --nocapture --nose-verbose --processes=5 --process-timeout=300
...
running test
Traceback (most recent call last):
  File "setup.py", line 381, in <module>
    **extra_args
  File "/usr/lib/python3.5/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/usr/lib/python3.5/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python3.5/distutils/dist.py", line 973, in run_command
    cmd_obj.ensure_finalized()
  File "/usr/lib/python3.5/distutils/cmd.py", line 107, in ensure_finalized
    self.finalize_options()
  File "setup.py", line 158, in finalize_options
    self.test_args = []
AttributeError: can't set attribute
@jenshnielsen
Copy link
Member

Thanks. I think they still run with the old python tests.py I am starting to think that we should get rid of the setup.py test entry point?

@tacaswell tacaswell added this to the unassigned milestone Oct 26, 2015
@tacaswell
Copy link
Member

The reason that we have the setup.py test entry point at all is so that we can have test-only requirements.

@jenshnielsen
Copy link
Member

Yes but we are not using it. It's breaks Travis and we have to maintain the 2 other ways of testing which does not install the test only dependencies but raises a warning if they are missing. I would much rather make go for the simple solution and just raise if nose or mock is missing that seems way more reliable to me.

@mdboom
Copy link
Member

mdboom commented Oct 26, 2015

I would love to make our test running more "sane" -- or at the least have fewer options. Maybe a good discussion topic for today's hangout?

@tacaswell
Copy link
Member

fair enough. Ripping it back out is fine by me, it was just painful to put in.

@mdboom
Copy link
Member

mdboom commented Oct 26, 2015

FWIW: I wasn't advocating any particular solution here, just to revisit all the options we've ended up with and see how we can simplify. I know it was painful to get the test command in.

@anntzer
Copy link
Contributor

anntzer commented Jun 21, 2017

setup.py test is no longer a documented test entry point, so closing.

@anntzer anntzer closed this as completed Jun 21, 2017
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

5 participants