File tree 1 file changed +5
-6
lines changed
hypothesis-python/src/hypothesis/internal/conjecture 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -434,17 +434,16 @@ def kill_branch(self) -> NoReturn:
434
434
else :
435
435
trial_data .freeze ()
436
436
key = self ._cache_key_ir (data = trial_data )
437
- if trial_data .status > Status .OVERRUN :
438
- try :
439
- return self .__data_cache_ir [key ]
440
- except KeyError :
441
- pass
442
- else :
437
+ if trial_data .status is Status .OVERRUN :
443
438
# if we simulated to an overrun, then we our result is certainly
444
439
# an overrun; no need to consult the cache. (and we store this result
445
440
# for simulation-less lookup later).
446
441
self .__data_cache_ir [key ] = Overrun
447
442
return Overrun
443
+ try :
444
+ return self .__data_cache_ir [key ]
445
+ except KeyError :
446
+ pass
448
447
449
448
data = self .new_conjecture_data_ir (nodes , max_length = max_length )
450
449
# note that calling test_function caches `data` for us, for both an ir
You can’t perform that action at this time.
0 commit comments