Skip to content

Commit 4b88c55

Browse files
committed
only result after adding to pareto
1 parent 20ea7f9 commit 4b88c55

File tree

1 file changed

+2
-1
lines changed
  • hypothesis-python/src/hypothesis/internal/conjecture

1 file changed

+2
-1
lines changed

hypothesis-python/src/hypothesis/internal/conjecture/pareto.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,10 +133,11 @@ def add(self, data):
133133
"""Attempts to add ``data`` to the pareto front. Returns True if
134134
``data`` is now in the front, including if data is already in the
135135
collection, and False otherwise"""
136-
data = data.as_result()
137136
if data.status < Status.VALID:
138137
return False
139138

139+
data = data.as_result()
140+
140141
if not self.front:
141142
self.front.add(data)
142143
return True

0 commit comments

Comments
 (0)