mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-24 21:01:52 +08:00
@@ -1,7 +1,3 @@
|
||||
# Error: is not present in stub
|
||||
# =============================
|
||||
netaddr.core.a # This is a temporary module attribute used to detect python version
|
||||
|
||||
# Error: is not present at runtime
|
||||
# ================================
|
||||
netaddr.ip.iana.XMLRecordParser.__getattr__ # __init__ has `self.__dict__.update(kwargs)`
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
version = "0.9.*"
|
||||
version = "0.10.*"
|
||||
upstream_repository = "https://github.com/drkjam/netaddr"
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
from netaddr.contrib.subnet_splitter import SubnetSplitter as SubnetSplitter
|
||||
from netaddr.core import (
|
||||
INET_ATON as INET_ATON,
|
||||
INET_PTON as INET_PTON,
|
||||
NOHOST as NOHOST,
|
||||
ZEROFILL as ZEROFILL,
|
||||
|
||||
@@ -9,6 +9,7 @@ Z: Final = 2
|
||||
ZEROFILL: Final = 2
|
||||
N: Final = 4
|
||||
NOHOST: Final = 4
|
||||
INET_ATON: Final = 8
|
||||
|
||||
class AddrFormatError(Exception): ...
|
||||
class AddrConversionError(Exception): ...
|
||||
|
||||
@@ -77,6 +77,10 @@ class IPAddress(BaseIP):
|
||||
def __lshift__(self, numbits: int) -> Self: ...
|
||||
def __rshift__(self, numbits: int) -> Self: ...
|
||||
def __bool__(self) -> bool: ...
|
||||
def to_canonical(self) -> Self: ...
|
||||
def is_global(self) -> bool: ...
|
||||
def is_ipv4_private_use(self) -> bool: ...
|
||||
def is_ipv6_unique_local(self) -> bool: ...
|
||||
|
||||
class IPListMixin:
|
||||
def __iter__(self) -> Iterator[IPAddress]: ...
|
||||
@@ -162,13 +166,19 @@ def largest_matching_cidr(ip: _IPAddressAddr, cidrs: Iterable[_IPNetworkAddr]) -
|
||||
def all_matching_cidrs(ip: _IPAddressAddr, cidrs: Iterable[_IPNetworkAddr]) -> list[IPNetwork]: ...
|
||||
|
||||
IPV4_LOOPBACK: IPNetwork
|
||||
IPV4_PRIVATE: tuple[IPNetwork | IPRange, ...]
|
||||
IPV4_PRIVATE_USE: list[IPNetwork]
|
||||
IPV4_PRIVATEISH: tuple[IPNetwork | IPRange, ...]
|
||||
IPV4_LINK_LOCAL: IPNetwork
|
||||
IPV4_MULTICAST: IPNetwork
|
||||
IPV4_6TO4: IPNetwork
|
||||
IPV4_RESERVED: tuple[IPNetwork | IPRange, ...]
|
||||
IPV4_NOT_GLOBALLY_REACHABLE: list[IPNetwork]
|
||||
IPV4_NOT_GLOBALLY_REACHABLE_EXCEPTIONS: list[IPNetwork]
|
||||
IPV6_LOOPBACK: IPNetwork
|
||||
IPV6_PRIVATE: tuple[IPNetwork, ...]
|
||||
IPV6_UNIQUE_LOCAL: IPNetwork
|
||||
IPV6_PRIVATEISH: tuple[IPNetwork, ...]
|
||||
IPV6_LINK_LOCAL: IPNetwork
|
||||
IPV6_MULTICAST: IPNetwork
|
||||
IPV6_RESERVED: tuple[IPNetwork, ...]
|
||||
IPV6_NOT_GLOBALLY_REACHABLE: list[IPNetwork]
|
||||
IPV6_NOT_GLOBALLY_REACHABLE_EXCEPTIONS: list[IPNetwork]
|
||||
|
||||
Reference in New Issue
Block a user