1
0
mirror of https://github.com/ppy/osu.git synced 2024-10-01 09:47:29 +08:00
Commit Graph

3372 Commits

Author SHA1 Message Date
Bartłomiej Dach
6948035a3c
Ensure score submission attempt completion before notifying spectator server when exiting play early
When a `SubmittingPlayer` gameplay session ends with the successful
completion of a beatmap, `PrepareScoreForResultsAsync()` ensures that
the score submission request is sent to and responded to by osu-web
before calling `ISpectatorClient.EndPlaying()`.

While previously this was mostly an implementation detail, this becomes
important when considering that more and more server-side flows (replay
upload, notifying about score processing completion) hook into
`EndPlaying()`, and assume that by the point that message arrives at
osu-spectator-server, the score has already been submitted and has been
assigned a score ID that corresponds to the score submission token.

As it turns out, in the early-exit path (when the user exits the play
midway through, retries, or just fails), the same ordering guarantees
were not provided. The score's submission ran concurrently to the
spectator client `EndPlaying()` call, therefore creating a network
race. osu-server-spectator components that implciitly relied on the
ordering provided by the happy path, could therefore fail to unmap the
score submission token to a score ID.

Note that as written, the osu-server-spectator replay upload flow is
not really affected by this, as it self-corrects by essentially polling
the database and trying to unmap the score submission token to a score
ID for up to 30 seconds. However, this change would have the benefit of
reducing the polls required in such cases to just one DB retrieval.
2022-12-21 22:23:26 +01:00
Dean Herbert
b64a5cbda6 Merge branch 'master' into guard-url-protocols 2022-12-19 15:46:45 +09:00
Bartłomiej Dach
fea0895f16
Call spectator EndPlaying() immediately after score submission
As it turns out, in current `master`, if a gameplay session ends
normally (i.e. by the player completing the beatmap in full), then
the spectator server `EndPlaying()` method will not be called until
`SubmittingPlayer.OnExiting()`, which in practice turns out to be
the moment where the user exits from the post-gameplay results screen
back to song select.

There is seemingly no reasonable cause for not calling this earlier. In
fact the solo spectator flow looks more broken without this call than
with, because without it the spectator view just hangs until the
spectated player exits gameplay, and *only then* shows results, rather
than do it upon normal gameplay completion.
2022-12-17 21:35:43 +01:00
Dean Herbert
27c497145f Fix the MOTHERLOAD of undetected issues that are now visible thanks to net6.0 2022-12-16 18:16:26 +09:00
Dan Balasescu
caa0b7c290 Move score token to BeginPlaying 2022-12-12 13:59:27 +09:00
Dan Balasescu
4a65f5c864 Add score token to spectator state 2022-12-09 19:09:51 +09:00
Dean Herbert
896f2d8f74 Fix multiple instances of last hitobject time being calculated incorrectly 2022-12-01 18:04:06 +09:00
Bartłomiej Dach
894ef15e79
Merge branch 'master' into update-framework 2022-11-26 16:19:36 +01:00
Dan Balasescu
7bc8908ca9 Partial everything 2022-11-27 00:00:27 +09:00
Dean Herbert
53b03df93d Combine TriangleButton and RoundedButton classes 2022-11-24 16:26:57 +09:00
Dean Herbert
b381b4fd2d Merge branch 'master' into update-framework 2022-11-24 01:27:58 +09:00
Dean Herbert
06ce8130c2 Apply changes in line with framework NRT updates 2022-11-18 18:13:15 +09:00
Dean Herbert
d59befc9d3 Fix initial visual state of positions before sort runs 2022-11-18 16:08:27 +09:00
Dean Herbert
aff218dfd5 Redirect through validity function rather than overriding Sort 2022-11-18 16:03:40 +09:00
Dean Herbert
20af8217f4 Tidy up bindable flow 2022-11-18 15:50:41 +09:00
Dean Herbert
e4f522aad1 Fix inspections / typos 2022-11-18 15:47:37 +09:00
Dean Herbert
d17c091d63 Move constant to a better location 2022-11-18 15:47:31 +09:00
Dean Herbert
3faa7f5f74
Merge branch 'master' into gameplay-leaderboard-fix 2022-11-18 15:44:30 +09:00
Dan Balasescu
219d049edf
Merge pull request #21140 from maromalo/long-standard
Standardise scores to `long` type
2022-11-18 15:26:33 +09:00
Dan Balasescu
57b8495c7a Merge branch 'master' into long-standard 2022-11-18 14:24:04 +09:00
Dean Herbert
e4d134a820 Reduce time waited on a score submission token from 60 to 30s 2022-11-18 14:07:40 +09:00
Dawid Sośnia
0dbf491872
Merge branch 'master' into gameplay-leaderboard-fix 2022-11-17 22:06:51 +01:00
Piggey
eb691266c1 cleanup 2022-11-17 21:50:39 +01:00
Piggey
fa00fc5c6d change scoresType to be a bindable 2022-11-17 13:27:56 +01:00
Piggey
dea2a6ed8d override sort() function in SoloGameplayLeaderboard 2022-11-17 12:12:36 +01:00
Dean Herbert
489dca79a1 Remove upper limit for pooling 2022-11-15 12:31:25 +09:00
Dean Herbert
308ed1abd1 Fix number of judgements shown potentially exceeding upper limit 2022-11-15 12:31:25 +09:00
Dean Herbert
59a8603728 Ensure flowing animation starts correctly from zero 2022-11-15 12:04:40 +09:00
Dean Herbert
aef6ee23eb Apply pooling support to ColourHitErrorMeter 2022-11-15 12:04:40 +09:00
Dean Herbert
a86b50d62a Apply nullability to BarHitErrorMeter 2022-11-15 11:33:27 +09:00
Dean Herbert
576f462f59 Add pooling support to BarHitErrorMeter 2022-11-15 11:33:27 +09:00
maromalo
1911120afe
Merge branch 'master' into long-standard 2022-11-12 09:52:11 -03:00
Dan Balasescu
db25e9e9c8 Merge branch 'master' into combo-colour-brightness-limit 2022-11-11 15:31:28 +09:00
Piggey
0011f4e7be fix comment lol 2022-11-09 19:59:04 +01:00
Piggey
ab53fb17d3 change displayed text from #? to - 2022-11-09 19:53:36 +01:00
Dean Herbert
1aa0e40f2f Add "Component" prefix to lookup naming 2022-11-09 17:46:43 +09:00
Dean Herbert
e75c3b3f94 Rename SkinnableTarget to GlobalSkinLookup 2022-11-09 17:46:43 +09:00
Piggey
d48c56818f change positionText to display "#?" if tracked score is being 51st on the leaderboard 2022-11-08 20:02:21 +01:00
maromalo
8eef2ba8de quality shenanigans 2022-11-06 20:12:26 -03:00
maromalo
b7ef9b176d Make score type consistent 2022-11-06 19:59:27 -03:00
Bartłomiej Dach
84179fb087
Merge branch 'master' into combo-colour-brightness-limit 2022-11-05 16:48:56 +01:00
Dean Herbert
4154be6cda Adjust auto-skip to skip multiple times if necessary 2022-11-03 13:52:29 +09:00
Dean Herbert
aef3c7918c Add total skip count to SkipOverlay 2022-11-03 13:52:24 +09:00
Dean Herbert
3ec9686e58 Fix test failures and rename configuration value to match better 2022-11-02 18:15:18 +09:00
Dean Herbert
37300ba9e2 Standardise "Visual Settings" components to fix mismatched paddings and labels 2022-11-02 14:01:57 +09:00
Dean Herbert
50b6fe4acb Localise new label 2022-11-02 14:01:03 +09:00
Dean Herbert
61fc3c8cc0 Add setting to visual settings toolbox 2022-11-02 13:58:34 +09:00
Dean Herbert
d8aa06ea92 Standardise "Visual Settings" components to fix mismatched paddings and labels 2022-11-02 13:55:56 +09:00
Dean Herbert
1035b5fb19 Fix hold to pause button not working when HUD is hidden 2022-10-30 21:38:45 +09:00
Joseph Madamba
87328dd1f5 Fix bar hit error meter labels not clearing when setting to none 2022-10-27 23:59:01 -07:00