diff --git a/nonebot_plugin_tetris_stats/games/tetrio/bind.py b/nonebot_plugin_tetris_stats/games/tetrio/bind.py index d1f7f4d..3ee5673 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/bind.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/bind.py @@ -81,7 +81,7 @@ async def _(nb_user: User, account: Player, event_session: EventSession, bot_inf name=bot_info.user_name, ), prompt='io查我', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/list.py b/nonebot_plugin_tetris_stats/games/tetrio/list.py index 4d18fd8..812dfaa 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/list.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/list.py @@ -89,7 +89,7 @@ async def _( for i in league.data.entries if isinstance(i, Entry) ], - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/query/v1.py b/nonebot_plugin_tetris_stats/games/tetrio/query/v1.py index 158f940..b8100f4 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/query/v1.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/query/v1.py @@ -93,7 +93,7 @@ async def make_query_image_v1(player: Player) -> bytes: sprint=sprint_value, blitz=blitz_value, ), - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/query/v2.py b/nonebot_plugin_tetris_stats/games/tetrio/query/v2.py index dcf9638..389b239 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/query/v2.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/query/v2.py @@ -188,7 +188,7 @@ async def make_query_image_v2(player: Player) -> bytes: if blitz.data.record is not None else None, zen=Zen(level=zen.data.level, score=zen.data.score), - _lang=get_lang(), + lang=get_lang(), ), ), ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/rank/all.py b/nonebot_plugin_tetris_stats/games/tetrio/rank/all.py index 53711ee..dc3ca15 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/rank/all.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/rank/all.py @@ -83,7 +83,7 @@ async def make_image_v1(latest_data: TETRIOLeagueStats, compare_data: TETRIOLeag for i in zip(latest_data.fields, compare_data.fields, strict=True) }, updated_at=latest_data.update_time, - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: @@ -111,7 +111,7 @@ async def make_image_v2(latest_data: TETRIOLeagueStats, compare_data: TETRIOLeag for i in zip(latest_data.fields, compare_data.fields, strict=True) }, updated_at=latest_data.update_time, - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/rank/detail.py b/nonebot_plugin_tetris_stats/games/tetrio/rank/detail.py index d361850..03fa926 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/rank/detail.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/rank/detail.py @@ -123,7 +123,7 @@ async def make_image(rank: ValidRank, latest: TETRIOLeagueStats, compare: TETRIO vs_holder=latest_data.high_vs.username.upper(), ), updated_at=latest.update_time.replace(tzinfo=UTC).astimezone(ZoneInfo('Asia/Shanghai')), - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/record/blitz.py b/nonebot_plugin_tetris_stats/games/tetrio/record/blitz.py index a766bcc..8ac6735 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/record/blitz.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/record/blitz.py @@ -146,7 +146,7 @@ async def make_blitz_image(player: Player) -> bytes: level=stats.level, ), play_at=blitz.data.record.ts, - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/record/sprint.py b/nonebot_plugin_tetris_stats/games/tetrio/record/sprint.py index f9cb52e..d79801c 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/record/sprint.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/record/sprint.py @@ -146,7 +146,7 @@ async def make_sprint_image(player: Player) -> bytes: ), ), play_at=sprint.data.record.ts, - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tetrio/unbind.py b/nonebot_plugin_tetris_stats/games/tetrio/unbind.py index 457620d..849c95e 100644 --- a/nonebot_plugin_tetris_stats/games/tetrio/unbind.py +++ b/nonebot_plugin_tetris_stats/games/tetrio/unbind.py @@ -69,7 +69,7 @@ async def _(nb_user: User, event_session: EventSession, bot_info: UserInfo = Bot name=bot_info.user_name, ), prompt='io绑定{游戏ID}', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/top/bind.py b/nonebot_plugin_tetris_stats/games/top/bind.py index 8cb8d1d..739cc57 100644 --- a/nonebot_plugin_tetris_stats/games/top/bind.py +++ b/nonebot_plugin_tetris_stats/games/top/bind.py @@ -55,7 +55,7 @@ async def _( name=bot_info.user_name, ), prompt='top查我', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/top/query.py b/nonebot_plugin_tetris_stats/games/top/query.py index fcb60a6..4e395d7 100644 --- a/nonebot_plugin_tetris_stats/games/top/query.py +++ b/nonebot_plugin_tetris_stats/games/top/query.py @@ -96,7 +96,7 @@ async def make_query_image(profile: UserProfile) -> bytes: apl=history.apl, apm_trending=Trending.KEEP, ), - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/top/unbind.py b/nonebot_plugin_tetris_stats/games/top/unbind.py index dc84558..5a34e18 100644 --- a/nonebot_plugin_tetris_stats/games/top/unbind.py +++ b/nonebot_plugin_tetris_stats/games/top/unbind.py @@ -57,7 +57,7 @@ async def _( name=bot_info.user_name, ), prompt='top绑定{游戏ID}', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tos/bind.py b/nonebot_plugin_tetris_stats/games/tos/bind.py index 798bc0d..9b6a0a2 100644 --- a/nonebot_plugin_tetris_stats/games/tos/bind.py +++ b/nonebot_plugin_tetris_stats/games/tos/bind.py @@ -55,7 +55,7 @@ async def _( name=bot_info.user_remark or bot_info.user_displayname or bot_info.user_name, ), prompt='茶服查我', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tos/query.py b/nonebot_plugin_tetris_stats/games/tos/query.py index 9e5382e..d1065c3 100644 --- a/nonebot_plugin_tetris_stats/games/tos/query.py +++ b/nonebot_plugin_tetris_stats/games/tos/query.py @@ -304,7 +304,7 @@ async def make_query_image(user_info: UserInfoSuccess, game_data: GameData, even challenge=f'{int(user_info.data.pb_challenge):,}' if user_info.data.pb_challenge != '0' else 'N/A', marathon=f'{int(user_info.data.pb_marathon):,}' if user_info.data.pb_marathon != '0' else 'N/A', ), - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/games/tos/unbind.py b/nonebot_plugin_tetris_stats/games/tos/unbind.py index 68f89ed..c6e10f7 100644 --- a/nonebot_plugin_tetris_stats/games/tos/unbind.py +++ b/nonebot_plugin_tetris_stats/games/tos/unbind.py @@ -60,7 +60,7 @@ async def _( name=bot_info.user_name, ), prompt='茶服绑定{游戏ID}', - _lang=get_lang(), + lang=get_lang(), ), ) ) as page_hash: diff --git a/nonebot_plugin_tetris_stats/utils/render/schemas/base.py b/nonebot_plugin_tetris_stats/utils/render/schemas/base.py index ec63dd1..22b13d2 100644 --- a/nonebot_plugin_tetris_stats/utils/render/schemas/base.py +++ b/nonebot_plugin_tetris_stats/utils/render/schemas/base.py @@ -8,7 +8,7 @@ from ...typedefs import Lang, Number class Base(BaseModel): - _lang: Lang + lang: Lang class Avatar(BaseModel):