-
Notifications
You must be signed in to change notification settings - Fork 596
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
Deprecate nested given #4283
base: master
Are you sure you want to change the base?
Deprecate nested given #4283
Conversation
Nice! It occurs to me that some people are probably going to use |
I'm not sure how to rewrite our tests for this change without weakening them :( see e.g. test_minimise_array_shapes |
...maybe we need to add a special "internal-use-only" flag to disable this for our own tests? It's janky, but I can see a reasonable argument for it. |
If we can't rewrite our own tests without nested givens, maybe we shouldn't be deprecating them for others? Crosshair can pretty easily detect + throw when it encounters this, and I'm not sure that "quadratic behavior" is compelling for knowledgeable developers who are setting reasonable max_examples limits, as we do. |
I agree, nested Would it be acceptable to make it into a health check failure (so that it can be turned off after being warned about the drawbacks)? |
I looked at the five reported in-the-wild usages. Briefly,
2 and 4 are superficially valid uses IMO. |
🤦♂️ yes this is obviously the solution, now that you mention it. |
Closes #4167