-
Notifications
You must be signed in to change notification settings - Fork 18k
net: ParseIP
returns nil instead of IP to a seemingly valid IPv6
#69752
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
That's not valid, there's too many digits in |
According to https://datatracker.ietf.org/doc/html/rfc4291#section-2.2
Meaning that the example at hand is invalid. I don't thinkg this behavior change is covered by Go 1 Compatibility Promise, correct? |
https://go.dev/cl/461605 is the change that added this behavior, which references #57760. So, this change does seem deliberate. I'm not sure what the right path forward is here. CC @neild @ianlancetaylor who reviewed the CL. |
Reopening for now to await input from Damien and/or Ian. |
CC @mpetrunic |
Unless I'm missing something, Go 1.22 and prior had a bug which caused us to parse this address anyway. (#57760) The bug was fixed in Go 1.23. This isn't a violation of the compatibility promise, since we reserve the right to fix bugs. I don't think there's anything for us to do here. |
Thank you @neild and @seankhliao ! I apologize for the noise. |
Go version
go1.23.2
Output of
go env
in your module/workspace:What did you do?
I parsed an IP using this code:
What did you see happen?
https://go.dev/play/p/bJUjbkLm_bg (Go 1.23)
What did you expect to see?
https://go.dev/play/p/bJUjbkLm_bg?v=goprev (Go 1.22)
The text was updated successfully, but these errors were encountered: