Skip to content

Commit 2f7890a

Browse files
brittanyreymeta-codesync[bot]
authored andcommitted
Fix invalid-annotation pyrefly ignores in test_support.py
Summary: Replace invalid *args: ... and **kwargs: ... annotations with *args: object and **kwargs: object. Eliminates 2 pyrefly suppression comments. Reviewed By: alexmalyshev Differential Revision: D99478963 fbshipit-source-id: a01f807b62691d11505066e1d8e85cfd4c17d349
1 parent 68edde6 commit 2f7890a

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

cinderx/PythonLib/cinderx/test_support.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,7 @@ def failUnlessJITCompiled(func: Callable[..., TRet]) -> Callable[..., TRet]:
203203
# when wrapper() is eventually called.
204204
exc: RuntimeError = re
205205

206-
# pyrefly: ignore [invalid-annotation]
207-
def wrapper(*args: ...) -> None:
206+
def wrapper(*args: object) -> None:
208207
raise RuntimeError(
209208
f"JIT compilation of {func.__qualname__} failed with {exc}"
210209
)
@@ -229,8 +228,7 @@ def fail_if_deopt(func: Callable[..., TRet]) -> Callable[..., TRet]:
229228
if not cinderx.jit.is_enabled():
230229
return func
231230

232-
# pyrefly: ignore [invalid-annotation]
233-
def wrapper(*args: ..., **kwargs: ...) -> TRet:
231+
def wrapper(*args: object, **kwargs: object) -> TRet:
234232
cinderx.jit.get_and_clear_runtime_stats()
235233
r = func(*args, **kwargs)
236234
# pyre-ignore[6]

0 commit comments

Comments
 (0)