Skip to content

exit code 2 when using '-x' flag #2832

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
3 of 4 tasks
cmccandless opened this issue Oct 11, 2017 · 3 comments
Closed
3 of 4 tasks

exit code 2 when using '-x' flag #2832

cmccandless opened this issue Oct 11, 2017 · 3 comments
Labels
status: help wanted developers would like help from experts on this topic type: backward compatibility might present some backward compatibility issues which should be carefully noted in the changelog type: bug problem that needs to be addressed

Comments

@cmccandless
Copy link

cmccandless commented Oct 11, 2017

pytest v3.2.1

Conditions:

A test fails while running pytest -x

Expected Behavior:

Exit code is 1 (according to usage)

Actual Behavior:

Exit code is 2

Confirmed environments:

  • Windows, Python3
  • Windows, Python2
  • Linux, Python3
  • Linux, Python2
@RonnyPfannschmidt RonnyPfannschmidt added status: help wanted developers would like help from experts on this topic type: backward compatibility might present some backward compatibility issues which should be carefully noted in the changelog type: bug problem that needs to be addressed labels Oct 11, 2017
@jespino
Copy link
Contributor

jespino commented Oct 17, 2017

I can confirm that it happens on Arch Linux with Python 3.6.2 and Python 2.7.14

@jespino
Copy link
Contributor

jespino commented Oct 17, 2017

I have made a PR here to fix the problem #2845 but It may be the expected behavior, currently return a 2 which is a "Interrupted" error code in pytest, which have sense. Anyway, a fail error code (1 in pytest) have a lot of sense too.

@cmccandless
Copy link
Author

Fixed in #2845

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: help wanted developers would like help from experts on this topic type: backward compatibility might present some backward compatibility issues which should be carefully noted in the changelog type: bug problem that needs to be addressed
Projects
None yet
Development

No branches or pull requests

3 participants