mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-03 01:53:24 +08:00
Use Incomplete instead of Any in __getattr__ (#8903)
This commit is contained in:
@@ -1,17 +1,17 @@
|
||||
from _typeshed import Incomplete
|
||||
from collections.abc import Generator, Iterable
|
||||
from typing import Any
|
||||
|
||||
class HTMLParser: # actually html5lib.HTMLParser
|
||||
def __getattr__(self, __name: str) -> Any: ... # incomplete
|
||||
def __getattr__(self, __name: str) -> Incomplete: ...
|
||||
|
||||
class Filter: # actually html5lib.filters.base.Filter
|
||||
def __getattr__(self, __name: str) -> Any: ... # incomplete
|
||||
def __getattr__(self, __name: str) -> Incomplete: ...
|
||||
|
||||
class SanitizerFilter: # actually html5lib.filters.sanitizer.Filter
|
||||
def __getattr__(self, __name: str) -> Any: ... # incomplete
|
||||
def __getattr__(self, __name: str) -> Incomplete: ...
|
||||
|
||||
class HTMLSerializer: # actually html5lib.serializer.HTMLSerializer
|
||||
def __getattr__(self, __name: str) -> Any: ... # incomplete
|
||||
def __getattr__(self, __name: str) -> Incomplete: ...
|
||||
|
||||
class BleachHTMLParser(HTMLParser):
|
||||
tags: list[str] | None
|
||||
@@ -24,4 +24,4 @@ class BleachHTMLSerializer(HTMLSerializer):
|
||||
def escape_base_amp(self, stoken: str) -> Generator[str, None, None]: ...
|
||||
def serialize(self, treewalker, encoding: str | None = ...) -> Generator[str, None, None]: ...
|
||||
|
||||
def __getattr__(__name: str) -> Any: ... # incomplete
|
||||
def __getattr__(__name: str) -> Incomplete: ...
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
from _typeshed import Incomplete
|
||||
from collections.abc import Container, Iterable, MutableMapping
|
||||
from re import Pattern
|
||||
from typing import Any, Protocol
|
||||
@@ -44,4 +45,4 @@ class LinkifyFilter(Filter):
|
||||
def __init__(
|
||||
self, source, callbacks=..., skip_tags: Container[str] | None = ..., parse_email: bool = ..., url_re=..., email_re=...
|
||||
) -> None: ...
|
||||
def __getattr__(self, item: str) -> Any: ... # incomplete
|
||||
def __getattr__(self, item: str) -> Incomplete: ...
|
||||
|
||||
Reference in New Issue
Block a user