From 953d3b062692606bb49f66b6f08d8cbf3f509181 Mon Sep 17 00:00:00 2001 From: Apricot-S Date: Wed, 3 Jun 2026 11:23:41 +0900 Subject: [PATCH 1/3] chore: Update ty --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6617a3f..9d3158c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ lint = [ "ruff>=0.15.0,<0.16", ] typing = [ - "ty>=0.0.17", + "ty>=0.0.42", ] test = [ "pytest>=9.0.2,<10", From afa6becd7f4e6a0c1cf18caa234e6c8bd72f0733 Mon Sep 17 00:00:00 2001 From: Apricot-S Date: Wed, 3 Jun 2026 11:24:34 +0900 Subject: [PATCH 2/3] refactor: Remove the unused suppression comment --- mahjong/hand_calculating/hand.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mahjong/hand_calculating/hand.py b/mahjong/hand_calculating/hand.py index d7918cd..4759e79 100644 --- a/mahjong/hand_calculating/hand.py +++ b/mahjong/hand_calculating/hand.py @@ -535,7 +535,7 @@ def estimate_hand_value( if not is_aotenjou: hand_yaku = yakuman_list else: - scores_calculator.aotenjou_filter_yaku(hand_yaku, config) # ty: ignore[unresolved-attribute] + scores_calculator.aotenjou_filter_yaku(hand_yaku, config) yakuman_list = [] # calculate han From 73e49878a288d69ed8b46ea43ba20ee79cd8c911 Mon Sep 17 00:00:00 2001 From: Apricot-S Date: Wed, 3 Jun 2026 11:48:18 +0900 Subject: [PATCH 3/3] refactor: Add a type hint for hand_yaku --- mahjong/hand_calculating/hand.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mahjong/hand_calculating/hand.py b/mahjong/hand_calculating/hand.py index 4759e79..f57c29e 100644 --- a/mahjong/hand_calculating/hand.py +++ b/mahjong/hand_calculating/hand.py @@ -192,7 +192,7 @@ def estimate_hand_value( config = config or HandConfig() - hand_yaku = [] + hand_yaku: list[Yaku] = [] scores_calculator = scores_calculator_factory() tiles_34 = TilesConverter.to_34_array(tiles)