Skip to content

Commit

Permalink
Cleanup internal type annotation variables
Browse files Browse the repository at this point in the history
`_format.py` had a few internal variables to make type annotations
shorter to write. However, these can cause issues with sphinx
nitpick. Even though the variables removed in this commit aren't
causing a build failure, removing them is a good precaution.
  • Loading branch information
sirosen committed Jan 5, 2022
1 parent 17384e7 commit cdc2807
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions jsonschema/_format.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@

from jsonschema.exceptions import FormatError

_FormatCheckerFunc = typing.Callable[[typing.Any], bool]
_CheckerRaises = typing.Union[Exception, typing.Tuple[Exception, ...]]


class FormatChecker(object):
"""
Expand All @@ -38,7 +35,10 @@ class FormatChecker(object):

checkers: dict[
str,
tuple[_FormatCheckerFunc, _CheckerRaises],
tuple[
typing.Callable[[typing.Any], bool],
Exception | tuple[Exception, ...],
],
] = {}

def __init__(self, formats=None):
Expand Down

0 comments on commit cdc2807

Please sign in to comment.