MCPcopy Index your code
hub / github.com/RustPython/RustPython / _check_packed_address

Method _check_packed_address

Lib/ipaddress.py:419–424  ·  view source on GitHub ↗
(self, address, expected_len)

Source from the content-addressed store, hash-verified

417 self.version))
418
419 def _check_packed_address(self, address, expected_len):
420 address_len = len(address)
421 if address_len != expected_len:
422 msg = "%r (len %d != %d) is not permitted as an IPv%d address"
423 raise AddressValueError(msg % (address, address_len,
424 expected_len, self.version))
425
426 @classmethod
427 def _ip_int_from_prefix(cls, prefixlen):

Callers 2

__init__Method · 0.80
__init__Method · 0.80

Calls 2

lenFunction · 0.85
AddressValueErrorClass · 0.85

Tested by

no test coverage detected