Import Match and Pattern from re, not typing (#8277)

This commit is contained in:
Alex Waygood
2022-07-12 14:32:48 +01:00
committed by GitHub
parent 27db37240a
commit 6348a58b8b
78 changed files with 142 additions and 90 deletions

View File

@@ -1,5 +1,6 @@
from logging import Logger
from typing import Any, Match, Pattern
from re import Match, Pattern
from typing import Any
from xml.etree.ElementTree import Element
from markdown import Markdown

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.blockprocessors import BlockProcessor
from markdown.extensions import Extension

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.blockprocessors import BlockProcessor
from markdown.extensions import Extension

View File

@@ -1,4 +1,4 @@
from typing import Pattern
from re import Pattern
from markdown.extensions import Extension
from markdown.treeprocessors import Treeprocessor

View File

@@ -1,4 +1,4 @@
from typing import Pattern
from re import Pattern
from markdown.blockprocessors import BlockProcessor, ListIndentProcessor
from markdown.extensions import Extension

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.extensions import Extension
from markdown.preprocessors import Preprocessor

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.extensions import Extension
from markdown.inlinepatterns import InlineProcessor

View File

@@ -1,4 +1,4 @@
from typing import Pattern
from re import Pattern
from markdown.extensions import Extension
from markdown.treeprocessors import Treeprocessor

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.extensions import Extension
from markdown.preprocessors import Preprocessor

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from markdown.extensions import Extension
from markdown.treeprocessors import Treeprocessor

View File

@@ -1,5 +1,6 @@
import typing
from typing import Any, ClassVar, Match
import re
from re import Match
from typing import Any, ClassVar
from xml.etree.ElementTree import Element
def build_inlinepatterns(md, **kwargs): ...
@@ -94,7 +95,7 @@ class LinkInlineProcessor(InlineProcessor):
class ImageInlineProcessor(LinkInlineProcessor): ...
class ReferenceInlineProcessor(LinkInlineProcessor):
NEWLINE_CLEANUP_RE: ClassVar[typing.Pattern[str]]
NEWLINE_CLEANUP_RE: ClassVar[re.Pattern[str]]
def evalId(self, data, index, text): ...
def makeTag(self, href, title, text): ...

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from . import util

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern
from re import Pattern
from typing import Any
from . import util

View File

@@ -1,4 +1,5 @@
from typing import Any, Pattern, overload
from re import Pattern
from typing import Any, overload
PY37: bool
__deprecated__: dict[str, tuple[str, Any]]