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

coverage.misc.CoverageException: --include and --source are mutually exclusive #543

Closed
nedbat opened this issue Dec 28, 2016 · 3 comments
Closed
Labels
bug Something isn't working

Comments

@nedbat
Copy link
Owner

nedbat commented Dec 28, 2016

Originally reported by Mike Jarvis (Bitbucket: mike_jarvis, GitHub: Unknown)


I'm getting an error running unit tests with nosetests that I suspect is due to something in the recent update to coverage 4.3: (cf. full travis log)

$ nosetests run_examples.py --with-coverage --cover-package=galsim --with-doctest
Traceback (most recent call last):
  File "/home/travis/virtualenv/python2.7.12/bin/nosetests", line 11, in <module>
    sys.exit(run_exit())
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/core.py", line 121, in __init__
    **extra_args)
  File "/opt/python/2.7.12/lib/python2.7/unittest/main.py", line 94, in __init__
    self.parseArgs(argv)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/core.py", line 145, in parseArgs
    self.config.configure(argv, doc=self.usage())
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/config.py", line 346, in configure
    self.plugins.configure(options, self)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/plugins/manager.py", line 284, in configure
    cfg(options, config)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/plugins/manager.py", line 99, in __call__
    return self.call(*arg, **kw)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/plugins/manager.py", line 167, in simple
    result = meth(*arg, **kw)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/nose/plugins/cover.py", line 142, in configure
    source=self.coverPackages)
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/coverage/control.py", line 140, in __init__
    concurrency=concurrency,
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/coverage/config.py", line 446, in read_coverage_config
    config.sanity_check()
  File "/home/travis/virtualenv/python2.7.12/lib/python2.7/site-packages/coverage/config.py", line 388, in sanity_check
    raise CoverageException("--include and --source are mutually exclusive")
coverage.misc.CoverageException: --include and --source are mutually exclusive

This error just started showing up today, so I suspect it has to do with the upgrade to coverage 4.3. But let me know if this is actually an upstream problem where I've been doing something invalid and 4.3 is just the first version to notice.

Also attaching the .coveragerc file we use in case helpful.


@nedbat
Copy link
Owner Author

nedbat commented Dec 28, 2016

Duplicate of #541.

@nedbat
Copy link
Owner Author

nedbat commented Dec 28, 2016

This is fixed in version 4.3.1, released today.

@nedbat
Copy link
Owner Author

nedbat commented Dec 28, 2016

Original comment by Mike Jarvis (Bitbucket: mike_jarvis, GitHub: Unknown)


Ah. Sorry for the noise. The other issue didn't show up yet when I searched. Thanks for the quick response!

@nedbat nedbat closed this as completed Dec 28, 2016
@nedbat nedbat added major bug Something isn't working labels Jun 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant