Skip to content

Commit

Permalink
[codemod] Del (object) from 50 inc aml/people_understanding/set_mod…
Browse files Browse the repository at this point in the history
…els/utils.py

Summary: Python3 makes the use of `(object)` in class inheritance unnecessary. Let's modernize our code by eliminating this.

Test Plan: Sandcastle

Reviewed By: palmje

Differential Revision: D48718377

fbshipit-source-id: 7610e272ab06bf042142222b523ac425be99eb8f
  • Loading branch information
r-barnes authored and facebook-github-bot committed Aug 28, 2023
1 parent 9d25185 commit 1e309c4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion antlir/antlir2/dnf/driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class AntlirError(Exception):
pass


class LockedOutput(object):
class LockedOutput:
def __init__(self, file):
self._file = file
self._lock = threading.Lock()
Expand Down
6 changes: 3 additions & 3 deletions antlir/bzl/tests/shapes/shape_bzl_shims.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def fail(msg: str, attr=None):
raise Fail(msg)


class structs(object):
class structs:
@staticmethod
def is_struct(x) -> bool:
return dataclasses.is_dataclass(x)
Expand All @@ -74,7 +74,7 @@ def as_json(x):
return globals()["__struct_to_json"](x)


class types(object):
class types:
@staticmethod
def is_bool(x):
return type(x) == bool
Expand All @@ -100,7 +100,7 @@ def is_tuple(x):
return type(x) == tuple


class collections(object):
class collections:
@staticmethod
def uniq(it):
return list(set(it))
Expand Down

0 comments on commit 1e309c4

Please sign in to comment.