Skip to content

Commit

Permalink
Convert FBCODE to use the Ruff Formatter
Browse files Browse the repository at this point in the history
Summary:
Converts the directory specified to use the Ruff formatter. This is the last big diff to convert all of Fbcode to Ruff.

pomsky_fix_bugs

drop-conflicts
bypass-github-export-checks
allow-large-files

Reviewed By: amyreese

Differential Revision: D66886610

fbshipit-source-id: 8276a7f6164efec189ca0b87e535543ed5bc3615
  • Loading branch information
Thomas Polasek authored and facebook-github-bot committed Dec 6, 2024
1 parent eabfbc7 commit cbd70cd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions idb/common/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def package_exists(package_name: str) -> bool:

@overload
def swallow_exceptions(
f: Callable[P, Awaitable[T]]
f: Callable[P, Awaitable[T]],
) -> Callable[P, Awaitable[T | None]]: ...


Expand All @@ -61,7 +61,7 @@ def swallow_exceptions(f: Callable[P, T]) -> Callable[P, T | None]: ...


def swallow_exceptions(
f: Callable[P, T] | Callable[P, Awaitable[T]]
f: Callable[P, T] | Callable[P, Awaitable[T]],
) -> Callable[P, T | None] | Callable[P, Awaitable[T | None]]:
if asyncio.iscoroutinefunction(f):

Expand Down
1 change: 0 additions & 1 deletion idb/grpc/xctest.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ def make_request(

coverage_object = None
if collect_coverage:

coverage_object = XctestRunRequest.CodeCoverage(
collect=True,
enable_continuous_coverage_collection=enable_continuous_coverage_collection,
Expand Down
2 changes: 1 addition & 1 deletion idb/utils/contextlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ async def __aexit__(self, typ, value, traceback): # noqa C901


def _asynccontextmanager(
func: Callable[..., AsyncIterator[_T]]
func: Callable[..., AsyncIterator[_T]],
) -> Callable[..., AsyncContextManager[_T]]:
"""@asynccontextmanager decorator.
Typical usage:
Expand Down

0 comments on commit cbd70cd

Please sign in to comment.