Commit Graph

16 Commits

Author SHA1 Message Date
pre-commit-ci[bot]
aa9387c53a chore(linter): auto fix by pre-commit hooks 2025-11-25 03:09:02 +00:00
咕谷酱
db430db01b fix(fetcher): handle token timeout gracefully 2025-11-25 11:08:51 +08:00
MingxuanGame
819f52450c refactor(fetcher): implement passive rate limiter for API requests 2025-11-23 13:42:21 +00:00
MingxuanGame
8f4a9d5fed feat(fetcher): use client_credentials grant type to avoid missing refresh token (#62)
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-10-25 20:01:50 +08:00
MingxuanGame
dfd656f2fb style(project): remove from __future__ import annotations 2025-10-03 17:15:41 +00:00
MingxuanGame
d23f32f08d refactor(log): refactor the whole project
format: {time:YYYY-MM-DD HH:mm:ss} [{level}] | {name} | {message}
{name} is:
- Uvicorn: log from uvicorn server (#228B22)
- Service: log from class of `app.service` (blue)
- Fetcher: log from fetchers (magenta)
- Task: log from `app.tasks` (#FFD700)
- System: log from `system_logger` (red)
- Normal: log from `log(name)` (#FFC1C1)
- Default: the module name of caller

if you are writing services or tasks, you can just call `logger.`, we will pack it with name `Service` or `Task`
if you want to print fetcher logs, system-related logs, or normal logs, use `logger = (fetcher_logger / system_logger / log)(name)`
2025-10-03 11:53:05 +00:00
MingxuanGame
3f6776847e feat(beatmap,score): update beatmaps from Bancho & deleting scores (#50)
New API:

- DELETE /api/private/score/{score_id}: delete a score
- POST /api/private/beatmapsets/{beatmapset_id}/sync: request for syncing a beatmapset

New configuration:

- OLD_SCORE_PROCESSING_MODE
2025-10-02 13:36:09 +08:00
MingxuanGame
e553b0cc40 fix(fetcher): URL encode scope in authorization URL 2025-09-13 17:15:06 +00:00
pre-commit-ci[bot]
7625cd99f5 chore(deps): auto fix by pre-commit hooks 2025-08-26 13:18:11 +08:00
咕谷酱
8adc88bf00 Remove retry logic from BaseFetcher API requests
Simplified the BaseFetcher class by removing the max_retries parameter and all related retry and reauthorization logic. API requests now fail immediately on authentication errors, and token clearing is handled by a new _clear_tokens method. This change streamlines error handling and reduces complexity.
2025-08-26 13:18:11 +08:00
MingxuanGame
598fcc8b38 refactor(project): make pyright & ruff happy 2025-08-22 08:21:52 +00:00
咕谷酱
80d4237c5d ruff fix 2025-08-22 00:07:19 +08:00
咕谷酱
b3fff65e35 fix token 2025-08-18 17:41:10 +08:00
MingxuanGame
f6c375caf3 feat(fetcher): refresh access_token automatically 2025-08-10 11:44:09 +00:00
MingxuanGame
c5fc6afc18 feat(redis): use asyncio 2025-07-31 14:38:10 +00:00
MingxuanGame
cca4a2f1be feat(fetcher): add data fetcher 2025-07-26 16:06:53 +08:00