diff options
author | Alfred Perlstein <alfred@fb.com> | 2021-05-05 17:33:17 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-05 17:33:17 (GMT) |
commit | 565a31804c1139fe7886f38af3b3923653b0c1b3 (patch) | |
tree | 51668e21735777de13b878981d6d941017038316 /Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst | |
parent | cf86996a8e5965ff587040d0c2831c3132081a21 (diff) | |
download | cpython-565a31804c1139fe7886f38af3b3923653b0c1b3.zip cpython-565a31804c1139fe7886f38af3b3923653b0c1b3.tar.gz cpython-565a31804c1139fe7886f38af3b3923653b0c1b3.tar.bz2 |
bpo-35753: Fix crash in doctest with unwrap-able functions (#22981)
Ignore objects that inspect.unwrap throws due to
too many wrappers. This is a very rare case, however
it can easily be surfaced when a module under doctest
imports unitest.mock.call into its namespace.
We simply skip any object that throws this exception.
This should handle the majority of cases.
Diffstat (limited to 'Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst')
-rw-r--r-- | Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst b/Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst new file mode 100644 index 0000000..eddfc25 --- /dev/null +++ b/Misc/NEWS.d/next/Tests/2020-10-25-19-20-26.bpo-35753.2LT-hO.rst @@ -0,0 +1,2 @@ +Fix crash in doctest when doctest parses modules that include unwrappable +functions by skipping those functions. |