-
-
Notifications
You must be signed in to change notification settings - Fork 32.9k
Closed
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytestsTests in the Lib/test dirTests in the Lib/test dirtype-featureA feature request or enhancementA feature request or enhancement
Description
Feature or enhancement
Proposal:
The same IPv6 address can be writed different ways, one of which is extended IPv4 form, like '::1.2.3.4', which may be detect as IPv4 by mistake. Thats why we must be sure, that ipaddress correctly detect this IPv6 address as IPv6, and compare with another forms of this address.
Something like that is needed
@```python
assert ipaddress.IPv6Interface('::1.2.3.4') == ipaddress.IPv6Interface('0000:0000:0000:0000:0000:0000:0102:0304')
assert ipaddress.IPv6Interface('::1.2.3.4').version == 6
### Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
### Links to previous discussion of this feature:
https://github.com/python/cpython/pull/121518
<!-- gh-linked-prs -->
### Linked PRs
* gh-121518
* gh-130678
* gh-130679
<!-- /gh-linked-prs -->
Metadata
Metadata
Assignees
Labels
stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytestsTests in the Lib/test dirTests in the Lib/test dirtype-featureA feature request or enhancementA feature request or enhancement