coder / websocket

Minimal and idiomatic WebSocket library for Go
ISC License
3.91k stars 296 forks source link

Upgrading broken due to vanity rename #464

Closed andig closed 2 months ago

andig commented 2 months ago

From https://github.com/coder/websocket/pull/462:

This will create easily solved breakage on updates but I figure it's best to pull the band aid off as early as possible

They are easily resolvable only by adding replace directives afaikt, at least if downstream modules depend on it. As a result, this will break everybody's go.mod and will make everybody wait for downstream updates. There is no obvious reason for pulling of the "band aid".

It would imho have been much better to not update the module name. Given it is a vanity name anyway there's absolutely no need for doing so. If a rename is needed it should be for a new start instead of breaking the vanity import.

I'd suggest to retract this version and decide either way. The current solution is the worst possible. At least the vanity import should continue forwarding to the old repo.

nhooyr commented 2 months ago

Great point @andig

Sorry for the trouble. Here's what we changed in response:

nhooyr.io/websocket now points to https://github.com/nhooyr/websocket-old/releases/tag/v1.8.16 which is marked as deprecated at the package level & all exported symbols so that people know to transition off it.

There will be no further updates or breakage on nhooyr.io/websocket

github.com/coder/websocket is an entirely separate module now.

Thanks for opening the issue.

nhooyr commented 2 months ago

See also https://pkg.go.dev/nhooyr.io/websocket@v1.8.16#pkg-index

andig commented 2 months ago

Thank you. Did a quick go get -u:

go: upgraded nhooyr.io/websocket v1.8.11 => v1.8.17

This seems great, especially since https://nhooyr.io/websocket points to Coder now. Thank you for changing this so quickly and making developer's life a bit easier!

mafredri commented 2 months ago

Thanks for handling this so quickly @nhooyr and @andig I'm glad this works more conveniently now. Closing, but feel free to re-open if there are still any issues remaining.