@@ -116,7 +116,7 @@ class TestInput:
116116 expected_pw_count = 0 ,
117117 expected_static_count = 2 ,
118118 # Lack of ty support, see https://github.com/astral-sh/ty/issues/2348.
119- rendering_types = cycle (['static' ]), # ty: ignore[invalid-argument-type]
119+ rendering_types = cycle (['static' ]),
120120 detection_probability_recommendation = cycle ([0 ]),
121121 ),
122122 id = 'Static only' ,
@@ -125,7 +125,7 @@ class TestInput:
125125 TestInput (
126126 expected_pw_count = 2 ,
127127 expected_static_count = 0 ,
128- rendering_types = cycle (['client only' ]), # ty: ignore[invalid-argument-type]
128+ rendering_types = cycle (['client only' ]),
129129 detection_probability_recommendation = cycle ([0 ]),
130130 ),
131131 id = 'Client only' ,
@@ -134,7 +134,7 @@ class TestInput:
134134 TestInput (
135135 expected_pw_count = 1 ,
136136 expected_static_count = 1 ,
137- rendering_types = cycle (['static' , 'client only' ]), # ty: ignore[invalid-argument-type]
137+ rendering_types = cycle (['static' , 'client only' ]),
138138 detection_probability_recommendation = cycle ([0 ]),
139139 ),
140140 id = 'Mixed' ,
@@ -143,7 +143,7 @@ class TestInput:
143143 TestInput (
144144 expected_pw_count = 2 ,
145145 expected_static_count = 2 ,
146- rendering_types = cycle (['static' , 'client only' ]), # ty: ignore[invalid-argument-type]
146+ rendering_types = cycle (['static' , 'client only' ]),
147147 detection_probability_recommendation = cycle ([1 ]),
148148 ),
149149 id = 'Enforced rendering type detection' ,
@@ -207,7 +207,7 @@ async def pre_nav_hook(context: AdaptivePlaywrightPreNavCrawlingContext) -> None
207207async def test_adaptive_crawling_parsel (test_urls : list [str ]) -> None :
208208 """Top level test for parsel. Only one argument combination. (The rest of code is tested with bs variant.)"""
209209 predictor = _SimpleRenderingTypePredictor (
210- rendering_types = cycle (['static' , 'client only' ]), # ty: ignore[invalid-argument-type]
210+ rendering_types = cycle (['static' , 'client only' ]),
211211 detection_probability_recommendation = cycle ([0 ]),
212212 )
213213
@@ -693,7 +693,7 @@ async def test_adaptive_context_helpers_on_changed_selector(test_urls: list[str]
693693 dynamically changed text instead of the original static text.
694694 """
695695 browser_only_predictor_no_detection = _SimpleRenderingTypePredictor (
696- rendering_types = cycle (['client only' ]), # ty: ignore[invalid-argument-type]
696+ rendering_types = cycle (['client only' ]),
697697 detection_probability_recommendation = cycle ([0 ]),
698698 )
699699 expected_h3_tag = f'<h3>{ _H3_CHANGED_TEXT } </h3>'
@@ -719,7 +719,7 @@ async def request_handler(context: AdaptivePlaywrightCrawlingContext) -> None:
719719async def test_adaptive_context_query_non_existing_element (test_urls : list [str ]) -> None :
720720 """Test that querying non-existing selector returns `None`"""
721721 browser_only_predictor_no_detection = _SimpleRenderingTypePredictor (
722- rendering_types = cycle (['client only' ]), # ty: ignore[invalid-argument-type]
722+ rendering_types = cycle (['client only' ]),
723723 detection_probability_recommendation = cycle ([0 ]),
724724 )
725725
@@ -746,8 +746,7 @@ async def request_handler(context: AdaptivePlaywrightCrawlingContext) -> None:
746746 TestInput (
747747 expected_pw_count = 0 ,
748748 expected_static_count = 2 ,
749- # Lack of ty support, see https://github.com/astral-sh/ty/issues/2348.
750- rendering_types = cycle (['static' ]), # ty: ignore[invalid-argument-type]
749+ rendering_types = cycle (['static' ]),
751750 detection_probability_recommendation = cycle ([0 ]),
752751 ),
753752 id = 'Static only' ,
@@ -756,7 +755,7 @@ async def request_handler(context: AdaptivePlaywrightCrawlingContext) -> None:
756755 TestInput (
757756 expected_pw_count = 2 ,
758757 expected_static_count = 0 ,
759- rendering_types = cycle (['client only' ]), # ty: ignore[invalid-argument-type]
758+ rendering_types = cycle (['client only' ]),
760759 detection_probability_recommendation = cycle ([0 ]),
761760 ),
762761 id = 'Client only' ,
@@ -765,7 +764,7 @@ async def request_handler(context: AdaptivePlaywrightCrawlingContext) -> None:
765764 TestInput (
766765 expected_pw_count = 2 ,
767766 expected_static_count = 2 ,
768- rendering_types = cycle (['static' , 'client only' ]), # ty: ignore[invalid-argument-type]
767+ rendering_types = cycle (['static' , 'client only' ]),
769768 detection_probability_recommendation = cycle ([1 ]),
770769 ),
771770 id = 'Enforced rendering type detection' ,
0 commit comments