-
-
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
Make 'warnings' and 'deselected' in assert_outcomes optional #9475
Conversation
I'm not sure if I like the approach to be honest... while it is indeed convenient, I fear the asymmetry could lead to a silent mode of failure, where people expect e.g. warnings to be checked, but that does not happen. |
I was trying to fix the regression... should we keep the regression then? Fix this some other way? |
Agreed that this would fix the regression - but I'm not sure if it's the right way forward. I think I personally would prefer documenting this as a breaking change instead. However it sounded like @RonnyPfannschmidt was in favor of this approach in #9471, so I might be overridden on that. 😉 Maybe @okken has an opinion on this? |
I totally agree with the sentient of @TheCompiler My personal preference is to fix the regression first, then think about warning and /or plannable breaking changes The problem is that the api initially was incomplete, and likely still is incomplete, so we ought to consider the states explicitly and implicitly checked for |
OK, closing this then. 👍 |
reopening as its preferable not to break users while we figure the correct long term solution |
Let me note that we already had breaking changes to this API (without any kind of deprecation period) in pytest 6, via #6505. I've seen some version checks to account for that in the wild, but don't remember where. So I guess the question is whether we'd rather:
I'd prefer 2) over an inconsistent API - but then again 1) would probably mean that if we clean this up in form of some kind of different API, plugins then need to account for four different ways of doing the same thing, which isn't ideal either... Thoughts? I'm fine with merging this and defer a better API to another release, but I feel like there is a trade-off... also cc-ing @symonk |
Bump? I feel like we need a decision here to avoid blocking the 7.0.0 final. As said, I'm fine with being overridden on this, I just hope it won't paint us into a corner. |
The safest one, feature wise, is 2: close this PR and accept the breakage. But I don't have strong feelings either, so what you folks decide it is fine. |
the breakage will be a utter pain for all plugin testsuites supporting multiple pytest versions, |
ok, let's go for this then to get things unstuck, and hope we can come up with a better API altogether in the future... |
Fix #9471
I don't think we need a CHANGELOG here, as this has not really been officially released yet.