Commit Graph
310 Commits
Author SHA1 Message Date
Hay1tsme 96a252cbf3 ongeki: fix act 3 database upgrade script 2025-03-29 11:25:07 -04:00
Hay1tsme 62e61ec975 Merge pull request 'O.N.G.E.K.I. bright MEMORY Act.3 support added' (#204) from feature/ongeki_act3 into develop
Reviewed-on: https://gitea.tendokyu.moe/Hay1tsme/artemis/pulls/204
2025-03-29 15:23:45 +00:00
Hay1tsme f939d4976e chuni: make total columns BigInt, for #203 2025-03-29 11:22:12 -04:00
Dniel97 fbcc53aeae ongeki: update ongeki_static_tech_music_uk 2025-03-26 21:20:22 +01:00
Hay1tsme c1fa528e45 chuni: fix frontend 500 if no profile is available 2025-03-25 11:30:44 -04:00
Hay1tsme 017cdecbaa db: fix missing param in add_arcade_owner 2025-03-25 11:22:37 -04:00
Hay1tsme b6d22ef41d frontend: arcade management rework 2025-03-25 10:43:26 -04:00
Hay1tsme 882560a790 adb: fix semantics with FelicaLookupEx 2025-03-21 09:47:44 -04:00
Hay1tsme 376b77be29 frontend: serial rollover after 9999 generated serials 2025-03-20 14:53:28 -04:00
Hay1tsme 399f983bea allnet: fix download order response, billing logging 2025-03-02 04:10:06 -05:00
Hay1tsme 0f52b89033 remove deprecated warn 2025-02-21 23:51:59 -05:00
akanyan fa667d15f2 ongeki: proper handling of music ranking list 2025-01-06 18:39:49 +00:00
Hay1tsme e93fcfd706 Merge pull request 'Fix: AimeDB Felica LookupEx rename package parameter' (#188) from SoulGateKey/artemis:lookup_fix into develop
Reviewed-on: https://gitea.tendokyu.moe/Hay1tsme/artemis/pulls/188
2024-12-19 06:41:02 +00:00
Kevin Trocolli b81d5c9cc5 adb: fix minor logging typo 2024-12-19 01:37:50 -05:00
Hay1tsme 6a305d2514 Merge pull request '[database] fix invalid transaction being left open' (#187) from beerpsi/artemis:fix/invalid-transaction into develop
Reviewed-on: https://gitea.tendokyu.moe/Hay1tsme/artemis/pulls/187
2024-12-19 06:14:45 +00:00
beerpsi d6d98d20cb fix: typing shenanigans 2024-12-12 20:47:34 +07:00
SoulGateKey 5ecc7984c7 Fix: AimeDB Felica LookupEx rename package parameter 2024-12-08 08:44:32 +08:00
Kevin Trocolli a8f5ef1550 allnet: properly dfi encode downloadorder responses 2024-12-01 14:19:55 -05:00
beerpsi 476a911df9 [database] fix invalid transaction being left open 2024-11-25 20:13:51 +07:00
beerpsi 58a5177a30 use SQL's limit/offset pagination for nextIndex/maxCount requests (#185)
Instead of retrieving the entire list of items/characters/scores/etc. at once (and even store them in memory), use SQL's `LIMIT ... OFFSET ...` pagination so we only take what we need.

Currently only CHUNITHM uses this, but this will also affect maimai DX and O.N.G.E.K.I. once the PR is ready.

Also snuck in a fix for CHUNITHM/maimai DX's `GetUserRivalMusicApi` to respect the `userRivalMusicLevelList` sent by the client.

### How this works

Say we have a `GetUserCharacterApi` request:

```json
{
    "userId": 10000,
    "maxCount": 700,
    "nextIndex": 0
}
```

Instead of getting the entire character list from the database (which can be very large if the user force unlocked everything), add limit/offset to the query:

```python
select(character)
.where(character.c.user == user_id)
.order_by(character.c.id.asc())
.limit(max_count + 1)
.offset(next_index)
```

The query takes `maxCount + 1` items from the database to determine if there is more items than can be returned:

```python
rows = ...

if len(rows) > max_count:
    # return only max_count rows
    next_index += max_count
else:
    # return everything left
    next_index = -1
```

This has the benefit of not needing to load everything into memory (and also having to store server state, as seen in the [`SCORE_BUFFER` list](https://gitea.tendokyu.moe/Hay1tsme/artemis/src/commit/2274b42358d9ef449ca541a46ce654b846ce7f7c/titles/chuni/base.py#L13).)

Reviewed-on: https://gitea.tendokyu.moe/Hay1tsme/artemis/pulls/185
Co-authored-by: beerpsi <beerpsi@duck.com>
Co-committed-by: beerpsi <beerpsi@duck.com>
2024-11-16 19:10:29 +00:00
beerpsi 789d50c406 use AsyncSession directly
see the warnings in https://docs.sqlalchemy.org/en/14/orm/extensions/asyncio.html#using-asyncio-scoped-session
2024-11-14 13:10:14 +07:00
beerpsi bc7524c8fc fix: make database async 2024-11-14 12:36:22 +07:00
Midorica b7a006f7ee core: pushing changes regarding MySQL ssl toggle that is now mandatory 2024-11-12 10:53:02 -05:00
daydensteve c2d4abcc26 db and import updates for userbox, avatar, voice, and map icon 2024-11-03 16:37:05 -05:00
Kevin Trocolli 0cef797a8a mai2: rework photo uploads, relates to #67 2024-10-06 03:47:10 -04:00
ppc f47175a144 [mai2] add buddies plus support (#177)
Adds favorite music support (there's an option in the results screen to star a song), handlers for new methods and fixes upsert failures for `userFavoriteList`.
The `UserIntimateApi` has been added but didn't seem to add any data during testing, and `CreateTokenApi`/`RemoveTokenApi` have also been added but I think they're only used during guest play.

---
Tested on 1.45 with no errors/game crashes (see logs). Card Maker hasn't been tested as I don't have a setup to play with.

Reviewed-on: https://gitea.tendokyu.moe/Hay1tsme/artemis/pulls/177
Co-authored-by: ppc <albie@ppc.moe>
Co-committed-by: ppc <albie@ppc.moe>
2024-09-23 17:21:29 +00:00
ppc 1db020b5fc fix generated keychip validation failures 2024-09-09 16:53:14 +00:00
Hay1tsme d1048694d4 Fix --config option not being respected, fixes #172 2024-09-06 10:36:57 -04:00
Kevin Trocolli 5c497032f1 frontend: "Edit Card" -> "Card Information" 2024-08-09 02:43:39 -04:00
Kevin Trocolli 06a7fdb1b1 frontend: implement add/edit card 2024-08-09 02:37:34 -04:00
Hay1tsme 68bbde209a aimedb: add warning for all-zero access code/idm 2024-07-18 13:30:46 -04:00
Hay1tsme 02cee4198d aimedb: block all-zero access codes and idms 2024-07-18 13:26:57 -04:00
Kevin Trocolli 6a43e0eada update keychip serial generation code 2024-07-09 15:10:42 -04:00
Hay1tsme d7e8c9b490 frontend: fix event log buttons 2024-07-06 23:20:04 -04:00
Hay1tsme c65c71e89e card: add memos 2024-07-06 23:13:41 -04:00
Kevin Trocolli 44fb6037cf chuni: add missing alembic script 2024-06-29 00:08:11 -04:00
Hay1tsme 4446ff1f21 mai2: add present support 2024-06-28 15:48:27 -04:00
Hay1tsme 7242a187ab sao: fix sao_hero_log_data nullability 2024-06-28 12:25:33 -04:00
Kevin Trocolli 601cec9075 sao: you already know what it is 2024-06-27 10:02:19 -04:00
Kevin Trocolli 177f851368 sao: cleanup 2024-06-27 00:07:10 -04:00
Kevin Trocolli 40a66614bc sao: fix user_hero_log_id 2024-06-27 00:04:23 -04:00
Kevin Trocolli 171131493f sao: fix new issues 2024-06-26 23:57:07 -04:00
Kevin Trocolli c13b096190 sao: split massive upgrade in half and hope it works 2024-06-26 23:31:59 -04:00
Kevin Trocolli 5eb2ef8311 sao: schema fixes 3: the misery never ends 2024-06-26 23:01:47 -04:00
Kevin Trocolli f27f789269 sao: alembic sucks sometimes. 2024-06-26 22:37:56 -04:00
Kevin Trocolli 7206af83cb sao: fix upgrade script 2024-06-26 22:30:12 -04:00
Kevin Trocolli e91f84fecc sao: backport changes from diana 2024-06-25 14:02:53 -04:00
Kevin Trocolli 6ae11f96a2 aimedb: fix idm zfill issue 2024-06-24 22:28:22 -04:00
Hay1tsme 8f9e9d4766 fix downgrade script issue referenced in #156 2024-06-24 13:37:10 -04:00
Kevin Trocolli bdbb22f164 logic fix 2024-06-23 22:19:27 -04:00