1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-14 15:57:24 +08:00
Commit Graph

1534 Commits

Author SHA1 Message Date
QuantumSno
71c42167e7 Updated wording on realm comments 2023-08-10 10:17:12 -04:00
QuantumSno
5443f89dca Assuming its still set to tab, removes binding for toggle chat so itll be set to the new default 2023-08-01 16:58:52 -04:00
QuantumSno
426bc52fd5 Updated schema_version number and added braces around some migration cases to help with re-using variable names 2023-08-01 14:27:37 -04:00
Dean Herbert
30baac0f3d Avoid reprocessing scores which already failed an upgrade previously
Closes https://github.com/ppy/osu/issues/24301.
2023-07-26 16:22:10 +09:00
OliBomby
e7a9175aea fix skin using wrong stream 2023-07-18 13:08:05 +02:00
OliBomby
63dd8bd991 use base.GetFileContents to get file stream 2023-07-18 12:40:48 +02:00
OliBomby
bcdf531039 truncate end time before start time 2023-07-18 12:28:35 +02:00
OliBomby
5d82190b70 Merge remote-tracking branch 'upstream/master' into legacy-export 2023-07-18 12:18:49 +02:00
OliBomby
c02684d985 truncate hit object end time 2023-07-18 12:18:43 +02:00
Zyf
b672b49e02 Scoring : Implement v1 to v3 conversion. 2023-07-15 23:20:49 +02:00
Dean Herbert
480259b8d2 Ensure migration is never run on scores with new-enough TotalScoreVersions 2023-07-14 20:02:25 +09:00
OliBomby
1d837a8725 Move all conversion code to LegacyBeatmapExporter 2023-07-13 00:20:01 +02:00
OliBomby
3052c317e1 change .osz2 to .olz (osu lazer zip) 2023-07-12 15:04:06 +02:00
OliBomby
465cc759f0 Add xmldoc to clarify the purpose of BeatmapExporter 2023-07-12 14:49:49 +02:00
OliBomby
b577b6b6ae Export legacy converted beatmaps as .osz and non-converted beatmaps as .osz2 2023-07-11 21:04:09 +02:00
OliBomby
2db25722cb It works now 2023-07-11 20:18:54 +02:00
OliBomby
06e5ef88c0 legacy export broken 2023-07-11 02:30:16 +02:00
Bartłomiej Dach
9e4ffc8c12
Split helper method for populations from replay 2023-07-10 21:10:01 +02:00
Bartłomiej Dach
e12255bbe5
Do not run legacy conversion with ScoreV2 mod present 2023-07-09 17:48:25 +02:00
Bartłomiej Dach
9377622cd4
Add backwards migration to populate ScoreV2 mod for already-imported scores 2023-07-09 17:48:24 +02:00
Dean Herbert
d72765b6f8
Merge pull request #24114 from peppy/editor-save-local-score-management
Ensure scores always have the correct linked `BeatmapInfo`
2023-07-07 15:40:54 +09:00
Dean Herbert
8978f2ddd8 Remove all usage of !something!.something
aka don't mix NRT forgiving syntax with not syntax
2023-07-07 10:15:33 +09:00
Bartłomiej Dach
1473abd909
Remove outdated xmldoc 2023-07-06 22:01:02 +02:00
Dean Herbert
a98a36872e Bring realm library up-to-date 2023-07-06 13:37:43 +09:00
Dean Herbert
9ff6b3fcd3 Merge branch 'master' into editor-save-local-score-management 2023-07-06 12:28:44 +09:00
Dean Herbert
f2aa80f413 Rename and adjust xmldoc on TotalScoreVersion 2023-07-04 20:04:02 +09:00
Dean Herbert
aee89e5e4b Rewrite comment regarding LegacyTotalScore 2023-07-04 19:59:57 +09:00
Dean Herbert
dd9998127e Count missing beatmaps as errored items 2023-07-04 18:35:03 +09:00
Dean Herbert
a0c3fa9c13 Move preconditions to realm migration step to simplify marker version logic 2023-07-04 17:53:53 +09:00
Dean Herbert
1629024111 ILegacyScoreProcessor -> ILegacyScoreSimulator 2023-07-04 17:32:54 +09:00
Dean Herbert
d74b1e148d Make ScoreInfo.BeatmapInfo nullable 2023-07-04 14:50:34 +09:00
Dean Herbert
67650831bd Remove unnecessary null check 2023-07-04 14:19:25 +09:00
Dean Herbert
4203e2183d
Merge branch 'master' into diffcalc-total-scorev1 2023-07-04 14:15:24 +09:00
Dan Balasescu
c6ad184d94 Move Ruleset method to ILegacyRuleset interface 2023-06-29 17:24:37 +09:00
Dan Balasescu
ddd870e843 Make LegacyTotalScore nullable 2023-06-29 17:19:10 +09:00
Dan Balasescu
09bc8e45de Refactoring 2023-06-28 16:14:32 +09:00
Dean Herbert
99e55bb9c0 Add logging and Debug.Fail on detached beatmap detection 2023-06-28 12:21:05 +09:00
Dean Herbert
8e80e2fa32 Fix incorrect realm copy logic when a beatmap becomes detached from its set
The code here was assuming that if the beatmap which is having changes
copied across does not exist within the `BeatmapSet.Beatmaps` list, it
was not yet persisted to realm.

In some edge case, it can happen that the beatmap *is* persisted to
realm but not correctly attached to the beatmap set. I don't yet know
how this occurs, but it has caused loss of data for at least two users.

The fix here is to check realm-wide for the beatmap (using its primary
key) rather than only in the list. We then handle the scenario where the
beatmap needs to be reattached to the set as a seprate step.

---

This does raise others questions like "are we even structuring this
correctly? couldn't a single beatmap exist in two different sets?"

Maybe, but let's deal with that if/when it comes up.
2023-06-27 18:20:01 +09:00
Dan Balasescu
0c5c09597c Store old total score as LegacyTotalScore 2023-06-27 14:59:40 +09:00
Dan Balasescu
8e79510793 Add migration for total score conversion 2023-06-26 21:53:21 +09:00
Dean Herbert
df5b389629 Manual fixes to reduce warnings to zero 2023-06-24 01:52:53 +09:00
Dean Herbert
0ab0c52ad5 Automated pass 2023-06-24 01:00:03 +09:00
Dean Herbert
1f17f416a4 Force migration of old-new standardised scores to run once more 2023-06-16 14:04:18 +09:00
Dean Herbert
94b7de4b3f Fix old-new standardised score conversion missing some scores due to not rounding correctly 2023-06-16 14:01:56 +09:00
Bartłomiej Dach
51b5a0863f
Apply migration to new standardised score on normal reimport too 2023-06-15 21:53:15 +02:00
Dean Herbert
d83bf02923
Fix thing 2023-06-15 21:43:41 +02:00
Bartłomiej Dach
6205864c62
Fix score migration not considering mod multipliers 2023-06-13 19:00:13 +02:00
Dean Herbert
422e87f0ec Fix weird usings 2023-06-13 05:30:12 +09:00
Dean Herbert
c1b0c60e79 Ensure all misses are dequeued 2023-06-13 05:24:04 +09:00
Dean Herbert
3304e41a30 Add more commenting 2023-06-13 05:20:29 +09:00
Dean Herbert
afb5a9243a
Fix typo
Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
2023-06-13 05:13:22 +09:00
Dean Herbert
e9fb1f8932 Avoid tracking hit events altogether during migration 2023-06-13 02:15:41 +09:00
Dean Herbert
385f6dbd84 Move local classes to their rightful location 2023-06-13 02:12:23 +09:00
Dean Herbert
87520ae400 Avoid overhead from retrieving MaxCombo inside loop from realm 2023-06-13 02:05:00 +09:00
Dean Herbert
0916ae1671 Add basic profiling output of realm migrations 2023-06-13 01:57:41 +09:00
Dean Herbert
0e9576acfb Remove logging and catch any kind of errors 2023-06-13 01:40:43 +09:00
Dean Herbert
d19f8997fc Account for scores which don't have correct maximum statistics populated 2023-06-13 01:40:43 +09:00
Dean Herbert
f30c1a564f Add basic setup for score migration 2023-06-13 01:40:43 +09:00
Bartłomiej Dach
11694f35fe
Apply NRT in MemoryCachingComponent subclasses too 2023-06-09 13:47:35 +02:00
Dean Herbert
4685ba83e1 Apply NRT to MemoryCachingComponent classes 2023-06-09 19:00:05 +09:00
Bartłomiej Dach
ca25ac446b
Be slightly more specific with error message 2023-06-09 11:20:12 +02:00
Dean Herbert
53f935714e Inline binary reading to avoid polluting RealmAccess with nested class 2023-06-09 17:34:27 +09:00
Dean Herbert
a9071e7afd try-catch more 2023-06-09 17:33:59 +09:00
Dan Balasescu
67562a3856 Catch errors during score parsing 2023-06-09 14:35:29 +09:00
Dan Balasescu
facf7de053 Parse ScoreInfo.IsLegacyScore from replays 2023-06-08 21:38:10 +09:00
Bartłomiej Dach
1f4e79d79d
Merge pull request #23711 from timiimit/add-last-edit-time
Store timestamp of beatmap's last edit time in local database
2023-06-07 16:57:24 +02:00
Salman Ahmed
62cb6a98ca Remove redundant nullable suppression directives 2023-06-07 08:20:41 +03:00
Dean Herbert
e0e013cca1
Fix incorrect realm schema comment
Co-authored-by: timiimit <32331609+timiimit@users.noreply.github.com>
2023-06-06 22:17:05 +09:00
Dean Herbert
878cdb2ed3 Bump schema version 2023-06-06 15:11:37 +09:00
Dean Herbert
18eb15bfa5 Gracefully handle failures in cleaning up pending file deletions 2023-05-31 19:39:43 +09:00
Bartłomiej Dach
2e81cae201
Move comment to more correct place 2023-05-30 23:18:34 +02:00
Dean Herbert
a0be526266 Adjust realm backup procedure to hard fail if running out of attempts
Previously, if the backup procedure failed, startup would continue and
the user's realm database may be deleted. I think in such a fail case
I'd rather the game didn't startup so the user gets in touch (or reads
the log files themselves) rather than potentially losing data.
2023-05-30 13:04:34 +09:00
Dean Herbert
79694897be Ensure a potential exception from cleanupPendingDeletions doesn't mark realm corrupt
The whole restructure here is to move the nested call out of the
`try-catch`. I noticed this while looking at a corrupt database issue a
user reported (https://github.com/ppy/osu/discussions/23694).

It's not the first time we've seen a corrupt database error where the
"corrupt" version works just fine on a second attempt.

Maybe this isn't the issue and it's just a transitive file access violation
but it definitely feels like this should be fixed regardless.
2023-05-30 13:00:17 +09:00
Dan Balasescu
d2380bd840 Remove usages of [ExcludeFromDynamicCompile] 2023-05-08 18:12:56 +09:00
Bartłomiej Dach
510484011c
Mark exporter extensions as untranslatable 2023-05-06 19:42:28 +02:00
Bartłomiej Dach
3f63fd7f4d
Reorder increment to make progress update less weird 2023-05-06 19:39:52 +02:00
Bartłomiej Dach
bb17b684b0
Rename flag 2023-05-06 19:38:41 +02:00
Bartłomiej Dach
a56a5d563c
Unify error message wording 2023-05-06 19:38:05 +02:00
Bartłomiej Dach
3afe198d1d
Remove weird single-use private method 2023-05-06 19:34:22 +02:00
Bartłomiej Dach
e0823ffd03
Move lower and xmldoc GetFilename(TModel) 2023-05-06 19:29:08 +02:00
Bartłomiej Dach
5e64d25b2a
Make UserFileStorage readonly again 2023-05-06 19:26:51 +02:00
Dean Herbert
64d7e0d896 Rename outputStream variable to match base class 2023-05-07 00:24:30 +09:00
Dean Herbert
d2591368a6 More xmldoc fixes 2023-05-06 23:53:35 +09:00
Dean Herbert
0d095c4bb7 Remove non-Live pathway 2023-05-06 23:10:18 +09:00
Dean Herbert
e75ff33d62 Remove redundant xmldoc and reword some remaining 2023-05-06 23:10:09 +09:00
cdwcgt
71864fbb93
remove meanless comment 2023-05-05 21:29:06 +09:00
cdwcgt
4393e53b43
ExportToStream should be public 2023-05-05 21:28:43 +09:00
Dean Herbert
747f912af5 Fix incorrect cancellation logic 2023-05-05 21:08:01 +09:00
Dean Herbert
5d78561aa3 Remove weird catch logic 2023-05-05 21:05:57 +09:00
Dean Herbert
2a3e03695c Simplify ExportAsync, remove weird dedupe logic and unnecessary return success code 2023-05-05 21:05:52 +09:00
Dean Herbert
4ccfebc02b Simplify ExportToStreamAsync implementation 2023-05-05 21:01:10 +09:00
Dean Herbert
fc2d2de34c Fix notification text not including export filename 2023-05-05 16:53:27 +09:00
Dean Herbert
9cafb20fcb Move file missing logging to a better location, and log actual filenames to logs 2023-05-05 16:53:16 +09:00
Dean Herbert
4ec98b0578 Improve xmldoc and fix silly progress text in LegacyArchiveExporter 2023-05-05 16:45:45 +09:00
Dean Herbert
0158102467 Rename class back to original name so I can read the diff 2023-05-05 16:19:10 +09:00
cdwcgt
dd69089117
code quality 2023-04-09 15:51:31 +09:00
cdwcgt
5d64c1b7bf
exception handling 2023-04-09 15:09:18 +09:00
cdwcgt
ce6a87b4a3
Merge remote-tracking branch 'upstream/master' into export 2023-04-09 15:02:47 +09:00
cdwcgt
fc55b96e77
remove CompletionText in Constructor
this will never used

Co-Authored-By: Dean Herbert <pe@ppy.sh>
2023-04-09 14:27:42 +09:00
cdwcgt
49193a2bdd
CompletionText
Co-Authored-By: Dean Herbert <pe@ppy.sh>
2023-04-09 22:25:47 +09:00
cdwcgt
de21b4a2f7
use Live<TModel>
Use RealmAccess only when needed
2023-04-09 22:21:15 +09:00
cdwcgt
1f4da35c8d
notification nullable fix 2023-04-09 22:13:53 +09:00
cdwcgt
13b522e825
repair usage of CancellationToken
Co-Authored-By: n0099 <n@n0099.net>
2023-04-09 22:09:53 +09:00
Cootz
556964eae0
Merge branch 'master' into BitmapUpdatesOnScore 2023-03-16 12:16:42 +03:00
Cootz
7107834b9e Fix truncating bug 2023-03-07 15:43:03 +03:00
Cootz
5191204569 Bring truncating logic back to Export method 2023-03-07 15:39:43 +03:00
cdwcgt
1d5c87039e typo 2023-02-26 15:28:43 +09:00
cdwcgt
e8092bff46 logic fix? 2023-02-26 15:28:24 +09:00
cdwcgt
fdf9544688 cancel handle 2023-02-26 15:28:10 +09:00
cdwcgt
a20e2685be make static name fix 2023-02-25 20:11:08 +09:00
cdwcgt
78201c4649 log to database 2023-02-23 22:17:35 +09:00
cdwcgt
60bdae41b6 make static 2023-02-23 22:17:13 +09:00
cdwcgt
9e1eb50d9b use log 2023-02-23 20:21:04 +09:00
cdwcgt
ba345e5591 delete notify post when duplicate export 2023-02-23 20:10:50 +09:00
Cootz
90aa4288d0 Reduce the allowed length by 5 to account for (99) suffix. Move truncating logic to GetFilename. Update tests. 2023-02-21 18:35:53 +03:00
cdwcgt
d20e1df603 wrong xmldoc
because of 6900d0120a
2023-02-21 20:54:06 +09:00
cdwcgt
04dcd661e0 async logic fix 2023-02-21 20:53:02 +09:00
cdwcgt
0667b83960 Path.GetExtension() will not get null 2023-02-19 02:56:53 +09:00
cdwcgt
229b31520f remove () 2023-02-19 02:42:33 +09:00
cdwcgt
fba99b344c Accidentally deleted using
wtf
2023-02-19 02:41:08 +09:00
cdwcgt
79715fe37b catch when zipWriter dispose
ObjectDisposedException also appear when zipwriter dispose after user request cancel
2023-02-19 02:24:07 +09:00
cdwcgt
8446e7d841 comment 2023-02-19 02:17:24 +09:00
cdwcgt
2a6ea99e6a store exportingModels for all exporter
No one wants to export multiple copies of the same model at the same time, right?
2023-02-19 02:09:59 +09:00
cdwcgt
30985f192e catch ObjectDisposedException 2023-02-19 02:06:07 +09:00
cdwcgt
d611603742 catch OperationCanceledException 2023-02-19 01:45:09 +09:00
cdwcgt
309e9b24e2 split LegacyArchiveExporter 2023-02-19 01:18:27 +09:00
cdwcgt
843d841f5a GetFilename and something other
https://github.com/ppy/osu/pull/21739
2023-02-17 22:23:50 +09:00
cdwcgt
29d6483e17 ConfigureAwait for awaited task 2023-02-17 22:19:24 +09:00
cdwcgt
e84e011d5d Merge branch 'master' into export 2023-02-17 22:15:19 +09:00
cdwcgt
eac0aa79a3 cancellationToken pass, notification adujust 2023-02-17 22:09:09 +09:00
Cootz
e3bdb3d852 Align links in one line 2023-02-17 15:32:36 +03:00
Cootz
fd1beaef87 Fix typo 2023-02-17 15:24:27 +03:00
Cootz
a3b440493a Update xml doc 2023-02-17 15:23:43 +03:00
Cootz
ceed3606cd
Remove redundant comment
Co-authored-by: Dean Herbert <pe@ppy.sh>
2023-02-17 13:46:06 +03:00
Dean Herbert
8c772a723f Expose constant publicly rather than reexposing business 2023-02-17 13:34:19 +09:00
Dean Herbert
96b1498932 Rename max length variable to make sense (it's a filename limit, not path) 2023-02-17 13:33:22 +09:00
Cootz
f1da213bea Add tests 2023-02-16 16:26:57 +03:00
Cootz
387a6f1330 Move logic to Export method 2023-02-15 22:43:43 +03:00
Cootz
fb06a77e2b
Merge branch 'master' into fix-exporting-a-skin-with-too-long-file-name 2023-02-15 22:29:38 +03:00
Cootz
1f586c129c fix applied 2023-02-15 22:15:44 +03:00
Dean Herbert
e71dfd7555 Fix skin export failing if a directory exists with the proposed filename 2023-02-15 16:11:16 +09:00
Dean Herbert
c50ea89bc9 Simplify migration to not rely on old/dynamic schema 2023-02-08 14:24:06 +09:00
Cootz
4ba915268c Change a comment into RealmAccess 2023-02-08 05:46:47 +03:00
PC
7e127dafe2 Update reference 2023-02-07 11:52:47 +03:00
Cootz
a1ee3df453 Improve local variable naming 2023-02-07 03:16:25 +03:00
Cootz
d23e787bc1 Update schema_version 2023-02-05 21:55:50 +03:00
Cootz
4598112586 Add OriginalBeatmapHash to ScoreInfo. Update db schema_version, migration 2023-02-05 21:46:38 +03:00
Susko3
f8537c1cbe Delegate file deletion to ImportTask to allow overriding it 2023-01-22 22:19:04 +01:00
Dean Herbert
cde45cdd3e
Merge pull request #21739 from integerrr/score-export-date
Append date to score export filename
2023-01-10 23:33:38 +09:00
Dean Herbert
a22b7298c6
Adjust english slightly 2023-01-10 22:27:36 +09:00