pyupgrade
pyupgrade copied to clipboard
Remove inheriting from object when creating classes with type()
Just as
class A(object): pass
is re-written as
class A: pass
, so should
A = type("A", (object,), {})
be re-written as
A = type("A", (), {})
See https://github.com/python/cpython/pull/19553
I am going to attempt this one. @asottile could you assign me?
I don't use the assign feature because if someone abandons working on it then it'll look like it's in progress forever and people will be discouraged from even attempting