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

When fixture setup crashes, immediately cancel all other fixture setups #121

Merged
merged 3 commits into from
May 7, 2021

Conversation

njsmith
Copy link
Member

@njsmith njsmith commented May 6, 2021

Fixes gh-120

@codecov
Copy link

codecov bot commented May 6, 2021

Codecov Report

Merging #121 (b338795) into master (59da535) will increase coverage by 0.06%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #121      +/-   ##
==========================================
+ Coverage   91.28%   91.34%   +0.06%     
==========================================
  Files          16       16              
  Lines         574      578       +4     
==========================================
+ Hits          524      528       +4     
  Misses         50       50              
Impacted Files Coverage Δ
pytest_trio/_tests/test_fixture_ordering.py 100.00% <100.00%> (ø)
pytest_trio/plugin.py 79.25% <100.00%> (ø)

@gc-ss
Copy link

gc-ss commented May 7, 2021

LGTM. Couldn't get it to hang any longer.

This PR has two issues - one with formatting and one with the docs build. Anything I can help with to make the merge happen?

(formatting fix from me would be passing it through black :P)

Thank you Nathaniel for this!

@njsmith
Copy link
Member Author

njsmith commented May 7, 2021

Yeah, we ought to switch to black, but haven't gotten around to it yet. (If you'd like to prepare a PR for that, feel free!)

I'm not sure what's going on the with docs build... the error message didn't make sense to me, and when I tried to reproduce it locally everything worked fine...

@njsmith
Copy link
Member Author

njsmith commented May 7, 2021

Oh wait I see, there's a bug in towncrier! When I used towncrier 19.2.0, it worked correctly. When I upgrade to towncrier 21.3.0, it generates the history file header like:

pytest-trio 0.7.0 (not released yet)pytest-trio 0.7.0 (not released yet)
------------------------------------

I.e., it drops the +dev and it puts the headline string twice. Very odd.

@njsmith
Copy link
Member Author

njsmith commented May 7, 2021

Looks like we're hitting twisted/towncrier#346

I guess we'll downgrade towncrier for the moment...

@pquentin pquentin merged commit e7debcb into python-trio:master May 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

How do I catch errors in tasks started from fixtures and abort tests(s) using cancel scope?
3 participants