Skip to content

Fix notification spam on websocket connection handshake failures#36349

Merged
bdach merged 5 commits intoppy:masterfrom
peppy:spectator-connection-disconnect-notify
Jan 15, 2026
Merged

Fix notification spam on websocket connection handshake failures#36349
bdach merged 5 commits intoppy:masterfrom
peppy:spectator-connection-disconnect-notify

Conversation

@peppy
Copy link
Copy Markdown
Member

@peppy peppy commented Jan 15, 2026

RFC

Closes #36336 (and probably other issues I need to link).

Have not tested yet (@bdach did you have a way to repro that specific error code in your previous testing?)

@peppy peppy requested a review from bdach January 15, 2026 08:33
@peppy peppy added the area:online functionality Deals with online fetching / sending but don't change much on a surface UI level. label Jan 15, 2026
/// </summary>
public static LocalisableString APIDisconnect => new TranslatableString(getKey(@"api_disconnect"), @"Connection to API was lost. Can't continue with online play.");

/// <summary>
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I combined these because I don't think this is really adding anything. When you get kicked from multiplayer it's pretty obvious already, so using a single message to convey all online-service-interruption issues makes more sense to me.

@bdach
Copy link
Copy Markdown
Collaborator

bdach commented Jan 15, 2026

did you have a way to repro that specific error code in your previous testing?

I do not.

@peppy peppy moved this to Pending Review in osu! team task tracker Jan 15, 2026

onError?.Invoke(exception);

if (exception is WebSocketException wse && wse.Message != @"The remote party closed the WebSocket connection without completing the close handshake.")
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did you mean

Suggested change
if (exception is WebSocketException wse && wse.Message != @"The remote party closed the WebSocket connection without completing the close handshake.")
if (exception is WebSocketException wse && wse.Message == @"The remote party closed the WebSocket connection without completing the close handshake.")

return;
}

if (getCurrentScreen() is Player)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure what the intent of this is

Suggested change
if (getCurrentScreen() is Player)
if (getCurrentScreen() is SpectatorPlayer)

is closer to what I would expect here, don't see much point posting notifications about spectator disconnecting when someone's watching a local replay

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it also affects replay upload, so at very least would need to match SubmittingPlayer as well.

If you want to be more granular I'd propose those two being switched on.

Copy link
Copy Markdown
Collaborator

@bdach bdach Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it affecting replay upload is more our problem than the user's but it makes sense I guess.

would prefer SpectatorPlayer || SubmittingPlayer over the current guard

@peppy peppy force-pushed the spectator-connection-disconnect-notify branch from ffd0bb5 to 1313883 Compare January 15, 2026 09:09
@its0ka
Copy link
Copy Markdown

its0ka commented Jan 19, 2026

so you actually did some code work for russians, just not something that actually helps the connection... i mentioned this already but got ignored, please answer this time: everything under osu.ppy.sh is whitelisted, is it really impossible for you to at least change bm*.ppy.sh to bm*.osu.ppy.sh?

@peppy
Copy link
Copy Markdown
Member Author

peppy commented Jan 20, 2026

so you actually did some code work for russians, just not something that actually helps the connection... i mentioned this already but got ignored, please answer this time: everything under osu.ppy.sh is whitelisted, is it really impossible for you to at least change bm*.ppy.sh to bm*.osu.ppy.sh?

Thanks for the suggestion, but that would come with wildcard SSL concerns (not impossible to resolve), and there's no guarantee they won't block the new subdomains.

We've reached out to the russian authorities and heard back from them, are the beatmap mirrors still completely blocked?

@its0ka
Copy link
Copy Markdown

its0ka commented Jan 20, 2026

there's no guarantee they won't block the new subdomains.

no osu domains are blocked. it's a domain whitelist (on cloudflare, OVH, DO, ...) and osu.ppy.sh is actually whitelisted, but not anything.ppy.sh like bm and spectator (not because there is something bad, but because they weren't noticed)

are the beatmap mirrors still completely blocked?

they weren't completely blocked for everyone, only ~35% of internet users in russia are affected now, but more and more people will complain as the government expands their block to more cities (they do it slowly since april 2025). you will see on status.ppy.sh if the block gets lifted.

@its0ka
Copy link
Copy Markdown

its0ka commented Feb 1, 2026

Anything new? Will forum purges continue forever, Kim? (Asking the unknown moderator)

@ppy ppy locked and limited conversation to collaborators Feb 1, 2026
@ppy ppy unlocked this conversation Feb 1, 2026
@peppy
Copy link
Copy Markdown
Member Author

peppy commented Feb 1, 2026

nothing new. please contact your government agencies to out more pressure. we are already in discussion to attempt to fix this.

@its0ka
Copy link
Copy Markdown

its0ka commented Feb 1, 2026

I did. Does this mean bm*.ppy.sh -> bm*.osu.ppy.sh is not happening?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:online functionality Deals with online fetching / sending but don't change much on a surface UI level. size/M

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

The remote party closed the WebSocket connection without completing the close handshake

3 participants