-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
pytest fails at first test with Exit: FATAL #2047
Comments
Can you show the full, exact output you get? That smells like something like a segmentation fault, in which case there's nothing pytest can do. |
|
The debug log says:
Which comes from your class JiraTestManager(object):
# ...
def __init__(self):
# ...
try:
# 165 lines of stuff...
except Exception:
logging.exception("Basic test setup failed")
self.initialized = 1
py.test.exit("FATAL") |
Thanks! Now I feel really stupid, I was sure that searched for the FATAL string in my code. Anyway that exception lines needs rework. BTW, do you know a way to display something on the screen (like details about this "special" error) even if I do have the stderr/stdout capture enabled? |
Why not simply let the exception propagate and let pytest handle the rest? |
I encounter a really strange issue on Jira python library, it seems that pytest exist during the execution of the first encountered test and doesn't give any explanation. I checked and there is nothing special about this test, disabling it it will move the error to the next one.
Debug log and pip freeze: https://gist.github.com/ssbarnea/a6799f7b648a675800970515219d4c82
The tests are at https://github.com/pycontribs/jira/blob/develop/tests/tests.py
It seems that this problem happens with both 2.9.2 and 3.0.3 on both Mac OS and Linux, with both python 2 and 3.
I am not sure if that's a real bug in pytest but clearly the behaviour is confusing.
The text was updated successfully, but these errors were encountered: