Skip to content

Commit

Permalink
DeepSource issue: Useless inheritance from object
Browse files Browse the repository at this point in the history
The class is inheriting from `object`, which is implicit under Python 3,
hence can be safely removed from bases.
  • Loading branch information
DimitriPapadopoulos committed Sep 27, 2021
1 parent 214dbf1 commit fba52f1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions codespell_lib/_codespell.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
# file1 .. fileN Files to check spelling


class QuietLevels(object):
class QuietLevels:
NONE = 0
ENCODING = 1
BINARY_FILE = 2
Expand All @@ -92,7 +92,7 @@ class QuietLevels(object):
FIXES = 16


class GlobMatch(object):
class GlobMatch:
def __init__(self, pattern):
if pattern:
# Pattern might be a list of comma-delimited strings
Expand All @@ -111,14 +111,14 @@ def match(self, filename):
return False


class Misspelling(object):
class Misspelling:
def __init__(self, data, fix, reason):
self.data = data
self.fix = fix
self.reason = reason


class TermColors(object):
class TermColors:
def __init__(self):
self.FILE = '\033[33m'
self.WWORD = '\033[31m'
Expand All @@ -132,7 +132,7 @@ def disable(self):
self.DISABLE = ''


class Summary(object):
class Summary:
def __init__(self):
self.summary = {}

Expand All @@ -152,7 +152,7 @@ def __str__(self):
width=15 - len(key)) for key in keys])


class FileOpener(object):
class FileOpener:
def __init__(self, use_chardet, quiet_level):
self.use_chardet = use_chardet
if use_chardet:
Expand Down
2 changes: 1 addition & 1 deletion codespell_lib/tests/test_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def test_constants():
assert EX_DATAERR == 65


class MainWrapper(object):
class MainWrapper:
"""Compatibility wrapper for when we used to return the count."""

@staticmethod
Expand Down

0 comments on commit fba52f1

Please sign in to comment.