aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/hypothesis/py3
diff options
context:
space:
mode:
authorrobot-piglet <robot-piglet@yandex-team.com>2024-08-06 08:17:05 +0300
committerrobot-piglet <robot-piglet@yandex-team.com>2024-08-06 08:25:32 +0300
commit957f0c255bd884c03bf673d354346180583537bb (patch)
treeee18065a831df623246bf8fd32669936d1b66fbd /contrib/python/hypothesis/py3
parent754c5c17faf3622b414edc5ec8d61df214a4fa2c (diff)
downloadydb-957f0c255bd884c03bf673d354346180583537bb.tar.gz
Intermediate changes
Diffstat (limited to 'contrib/python/hypothesis/py3')
-rw-r--r--contrib/python/hypothesis/py3/.dist-info/METADATA10
-rw-r--r--contrib/python/hypothesis/py3/_hypothesis_pytestplugin.py6
-rw-r--r--contrib/python/hypothesis/py3/hypothesis/internal/conjecture/junkdrawer.py6
-rw-r--r--contrib/python/hypothesis/py3/hypothesis/reporting.py13
-rw-r--r--contrib/python/hypothesis/py3/hypothesis/version.py2
-rw-r--r--contrib/python/hypothesis/py3/ya.make2
6 files changed, 16 insertions, 23 deletions
diff --git a/contrib/python/hypothesis/py3/.dist-info/METADATA b/contrib/python/hypothesis/py3/.dist-info/METADATA
index ffee48a82f..223aafcb69 100644
--- a/contrib/python/hypothesis/py3/.dist-info/METADATA
+++ b/contrib/python/hypothesis/py3/.dist-info/METADATA
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: hypothesis
-Version: 6.108.2
+Version: 6.108.4
Summary: A library for property-based testing
Home-page: https://hypothesis.works
Author: David R. MacIver and Zac Hatfield-Dodds
@@ -41,10 +41,10 @@ Requires-Dist: exceptiongroup >=1.0.0 ; python_version < "3.11"
Provides-Extra: all
Requires-Dist: black >=19.10b0 ; extra == 'all'
Requires-Dist: click >=7.0 ; extra == 'all'
-Requires-Dist: crosshair-tool >=0.0.61 ; extra == 'all'
+Requires-Dist: crosshair-tool >=0.0.63 ; extra == 'all'
Requires-Dist: django >=3.2 ; extra == 'all'
Requires-Dist: dpcontracts >=0.4 ; extra == 'all'
-Requires-Dist: hypothesis-crosshair >=0.0.7 ; extra == 'all'
+Requires-Dist: hypothesis-crosshair >=0.0.9 ; extra == 'all'
Requires-Dist: lark >=0.10.1 ; extra == 'all'
Requires-Dist: libcst >=0.3.16 ; extra == 'all'
Requires-Dist: numpy >=1.17.3 ; extra == 'all'
@@ -63,8 +63,8 @@ Requires-Dist: rich >=9.0.0 ; extra == 'cli'
Provides-Extra: codemods
Requires-Dist: libcst >=0.3.16 ; extra == 'codemods'
Provides-Extra: crosshair
-Requires-Dist: hypothesis-crosshair >=0.0.7 ; extra == 'crosshair'
-Requires-Dist: crosshair-tool >=0.0.61 ; extra == 'crosshair'
+Requires-Dist: hypothesis-crosshair >=0.0.9 ; extra == 'crosshair'
+Requires-Dist: crosshair-tool >=0.0.63 ; extra == 'crosshair'
Provides-Extra: dateutil
Requires-Dist: python-dateutil >=1.4 ; extra == 'dateutil'
Provides-Extra: django
diff --git a/contrib/python/hypothesis/py3/_hypothesis_pytestplugin.py b/contrib/python/hypothesis/py3/_hypothesis_pytestplugin.py
index e82b528bb5..9df7817c68 100644
--- a/contrib/python/hypothesis/py3/_hypothesis_pytestplugin.py
+++ b/contrib/python/hypothesis/py3/_hypothesis_pytestplugin.py
@@ -309,7 +309,7 @@ else:
with current_pytest_item.with_value(item):
yield
if store.results:
- item.hypothesis_report_information = list(store.results)
+ item.hypothesis_report_information = "\n".join(store.results)
def _stash_get(config, key, default):
if hasattr(config, "stash"):
@@ -325,9 +325,7 @@ else:
def pytest_runtest_makereport(item, call):
report = (yield).get_result()
if hasattr(item, "hypothesis_report_information"):
- report.sections.append(
- ("Hypothesis", "\n".join(item.hypothesis_report_information))
- )
+ report.sections.append(("Hypothesis", item.hypothesis_report_information))
if report.when != "teardown":
return
diff --git a/contrib/python/hypothesis/py3/hypothesis/internal/conjecture/junkdrawer.py b/contrib/python/hypothesis/py3/hypothesis/internal/conjecture/junkdrawer.py
index 7dbab5b971..4465f59e5c 100644
--- a/contrib/python/hypothesis/py3/hypothesis/internal/conjecture/junkdrawer.py
+++ b/contrib/python/hypothesis/py3/hypothesis/internal/conjecture/junkdrawer.py
@@ -421,6 +421,10 @@ _gc_initialized = False
_gc_start = 0
_gc_cumulative_time = 0
+# Since gc_callback potentially runs in test context, and perf_counter
+# might be monkeypatched, we store a reference to the real one.
+_perf_counter = time.perf_counter
+
def gc_cumulative_time() -> float:
global _gc_initialized
@@ -430,7 +434,7 @@ def gc_cumulative_time() -> float:
def gc_callback(phase, info):
global _gc_start, _gc_cumulative_time
try:
- now = time.perf_counter()
+ now = _perf_counter()
if phase == "start":
_gc_start = now
elif phase == "stop" and _gc_start > 0:
diff --git a/contrib/python/hypothesis/py3/hypothesis/reporting.py b/contrib/python/hypothesis/py3/hypothesis/reporting.py
index a0f300b2bc..19073c5aff 100644
--- a/contrib/python/hypothesis/py3/hypothesis/reporting.py
+++ b/contrib/python/hypothesis/py3/hypothesis/reporting.py
@@ -8,8 +8,6 @@
# v. 2.0. If a copy of the MPL was not distributed with this file, You can
# obtain one at https://mozilla.org/MPL/2.0/.
-import inspect
-
from hypothesis._settings import Verbosity, settings
from hypothesis.internal.compat import escape_unicode_characters
from hypothesis.utils.dynamicvariables import DynamicVariable
@@ -37,14 +35,6 @@ def current_verbosity():
return settings.default.verbosity
-def to_text(textish):
- if inspect.isfunction(textish):
- textish = textish()
- if isinstance(textish, bytes):
- textish = textish.decode()
- return textish
-
-
def verbose_report(text):
if current_verbosity() >= Verbosity.verbose:
base_report(text)
@@ -61,4 +51,5 @@ def report(text):
def base_report(text):
- current_reporter()(to_text(text))
+ assert isinstance(text, str), f"unexpected non-str {text=}"
+ current_reporter()(text)
diff --git a/contrib/python/hypothesis/py3/hypothesis/version.py b/contrib/python/hypothesis/py3/hypothesis/version.py
index 4858f7fb0c..29e2144b92 100644
--- a/contrib/python/hypothesis/py3/hypothesis/version.py
+++ b/contrib/python/hypothesis/py3/hypothesis/version.py
@@ -8,5 +8,5 @@
# v. 2.0. If a copy of the MPL was not distributed with this file, You can
# obtain one at https://mozilla.org/MPL/2.0/.
-__version_info__ = (6, 108, 2)
+__version_info__ = (6, 108, 4)
__version__ = ".".join(map(str, __version_info__))
diff --git a/contrib/python/hypothesis/py3/ya.make b/contrib/python/hypothesis/py3/ya.make
index 63eb354c8e..4efa89329d 100644
--- a/contrib/python/hypothesis/py3/ya.make
+++ b/contrib/python/hypothesis/py3/ya.make
@@ -2,7 +2,7 @@
PY3_LIBRARY()
-VERSION(6.108.2)
+VERSION(6.108.4)
LICENSE(MPL-2.0)