From 067019ea47615b537727ecb58708660e061c4736 Mon Sep 17 00:00:00 2001 From: Glyph Date: Mon, 27 Mar 2023 17:34:55 -0700 Subject: [PATCH 1/3] updated versions --- tox.ini | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tox.ini b/tox.ini index ab1055c2e..231011375 100644 --- a/tox.ini +++ b/tox.ini @@ -52,9 +52,11 @@ basepython = py38: python3.8 py39: python3.9 py310: python3.10 + py311: python3.11 pypy3: pypy3 pypy38: pypy3.8 + pypy39: pypy3.9 deps = {[default]deps} From 1081156ae2f84804dac49c7ccd714cdbc1f0416c Mon Sep 17 00:00:00 2001 From: Glyph Date: Tue, 28 Mar 2023 00:35:11 -0700 Subject: [PATCH 2/3] add very odd manual end-of-process teardown for hypothesis --- src/klein/test/test_plating.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/klein/test/test_plating.py b/src/klein/test/test_plating.py index 06595382e..c11f2fc2b 100644 --- a/src/klein/test/test_plating.py +++ b/src/klein/test/test_plating.py @@ -3,6 +3,7 @@ """ +import atexit import json from string import printable from typing import Any @@ -147,6 +148,17 @@ def jsonComposites(children): jsonObjects = st.recursive(jsonAtoms, jsonComposites, max_leaves=200) +@atexit.register +def invalidateJsonStrategy() -> None: + """ + hypothesis RecursiveStrategy hangs on to a threadlocal object which causes + disttrial to hang for some reason. + + Possibly related to U{this }. + """ + jsonObjects.limited_base._threadlocal = None + + def transformJSONObject(jsonObject, transformer): """ Recursively apply a transforming function to a JSON serializable From ef9ffd8922fb18eece2228c7f36f8b41502c9a0d Mon Sep 17 00:00:00 2001 From: Glyph Date: Tue, 28 Mar 2023 00:36:19 -0700 Subject: [PATCH 3/3] upgrade isort to a version that works --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 68a556d36..e6684cbd5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -19,7 +19,7 @@ repos: - pyflakes==2.4.0 - repo: https://github.com/PyCQA/isort - rev: 5.10.1 + rev: 5.12.0 hooks: - id: isort args: ["--filter-files"]