This seems to be a minimal reproduction:
(note I made a virtualenv one level up to avoid that being in the coverage output)
.coveragerc
t.py
import flask
app = flask.Flask(__name__)
@app.route('/foo/<a>')
def hello(a):
return 'world'
# pretend this is a test
with app.test_request_context():
with app.test_client() as client:
client.get(flask.url_for('hello', a='1'))
runtime
$ bash -xc 'coverage erase && coverage run t.py && coverage report && coverage xml'
+ coverage erase
+ coverage run t.py
+ coverage report
generated NoSource: No source for code: '/tmp/t/generated'.
Aborting report output, consider using -i.
Name Stmts Miss Cover
---------------------------
t.py 7 0 100%
+ coverage xml
No source for code: '/tmp/t/generated'.
Aborting report output, consider using -i.
triage (?)
This appears to come from here:
or, at least, that's the only instance of 'generated' or "generated" in my site-packages -- so I may be guessing a bit here.
This is causing CI failures in https://github.com/asottile/git-code-debt
workaround
A workaround appears to be setting this:
[run]
# ...
omit =
*generated
in .coveragerc
though ideally I wouldn't have to exclude this 🤔
This seems to be a minimal reproduction:
(note I made a virtualenv one level up to avoid that being in the coverage output)
.coveragerct.pyruntime
triage (?)
This appears to come from here:
werkzeug/src/werkzeug/routing.py
Line 1111 in 86f7bdf
or, at least, that's the only instance of
'generated'or"generated"in my site-packages -- so I may be guessing a bit here.This is causing CI failures in https://github.com/asottile/git-code-debt
workaround
A workaround appears to be setting this:
in
.coveragercthough ideally I wouldn't have to exclude this 🤔