summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetr Viktorin <encukou@gmail.com>2024-06-27 07:09:22 (GMT)
committerGitHub <noreply@github.com>2024-06-27 07:09:22 (GMT)
commit1167a9a30b4b2f327ed987e845e378990d1ae6bf (patch)
tree35524379ff45d1bcf0e25aefe3f171a3e80b9fae
parent7d9c68513d112823a9a6cdc7453b998b2c24eb4c (diff)
downloadcpython-1167a9a30b4b2f327ed987e845e378990d1ae6bf.zip
cpython-1167a9a30b4b2f327ed987e845e378990d1ae6bf.tar.gz
cpython-1167a9a30b4b2f327ed987e845e378990d1ae6bf.tar.bz2
gh-119521: Remove _IncompleteInputError from the docs (GH-120993)
-rw-r--r--Lib/test/exception_hierarchy.txt1
-rw-r--r--Lib/test/test_baseexception.py3
2 files changed, 3 insertions, 1 deletions
diff --git a/Lib/test/exception_hierarchy.txt b/Lib/test/exception_hierarchy.txt
index 5e83faa..f2649aa 100644
--- a/Lib/test/exception_hierarchy.txt
+++ b/Lib/test/exception_hierarchy.txt
@@ -45,7 +45,6 @@ BaseException
├── StopAsyncIteration
├── StopIteration
├── SyntaxError
- │ └── _IncompleteInputError
│ └── IndentationError
│ └── TabError
├── SystemError
diff --git a/Lib/test/test_baseexception.py b/Lib/test/test_baseexception.py
index 6dc06c5..e599b02 100644
--- a/Lib/test/test_baseexception.py
+++ b/Lib/test/test_baseexception.py
@@ -78,6 +78,9 @@ class ExceptionClassTests(unittest.TestCase):
last_depth = depth
finally:
inheritance_tree.close()
+
+ # Underscore-prefixed (private) exceptions don't need to be documented
+ exc_set = set(e for e in exc_set if not e.startswith('_'))
self.assertEqual(len(exc_set), 0, "%s not accounted for" % exc_set)
interface_tests = ("length", "args", "str", "repr")