Skip to content

Commit

Permalink
chore: Disable certain Pylint findings
Browse files Browse the repository at this point in the history
Disable the warning regarding too many arguments or return statements,
because I don't have time at the moment to refactor to address them.

* https://docs.astral.sh/ruff/rules/too-many-arguments/
* https://docs.astral.sh/ruff/rules/too-many-return-statements/
  • Loading branch information
jmgate committed Apr 24, 2024
1 parent af677a1 commit dd52a94
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion shell_logger/html_utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -858,7 +858,7 @@ def sgr_4bit_color_and_style_to_html(sgr: str) -> str:
return f'<span style="{sgr_to_css.get(sgr) or str()}">'


def sgr_8bit_color_to_html(sgr_params: List[str]) -> str:
def sgr_8bit_color_to_html(sgr_params: List[str]) -> str: # noqa: PLR0911
"""
Convert 8-bit SGR colors to HTML.
Expand Down
8 changes: 4 additions & 4 deletions shell_logger/shell_logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ def append(path: Path) -> ShellLogger:
loaded_logger = json.load(jf, cls=ShellLoggerDecoder)
return loaded_logger

def __init__(
def __init__( # noqa: PLR0913
self,
name: str,
*,
Expand Down Expand Up @@ -484,7 +484,7 @@ def finalize(self) -> None:
self, jf, cls=ShellLoggerEncoder, sort_keys=True, indent=4
)

def log(
def log( # noqa: PLR0913
self,
msg: str,
cmd: str,
Expand Down Expand Up @@ -726,7 +726,7 @@ class ShellLoggerEncoder(json.JSONEncoder):
json.dump(data, jf, cls=ShellLoggerEncoder)
"""

def default(self, obj: object) -> object:
def default(self, obj: object) -> object: # noqa: PLR0911
"""
Serialize an object; that is, encode it in a string format.
Expand Down Expand Up @@ -789,7 +789,7 @@ def __init__(self):
json.JSONDecoder.__init__(self, object_hook=self.dict_to_object)

@staticmethod
def dict_to_object(obj: dict) -> object:
def dict_to_object(obj: dict) -> object: # noqa: PLR0911
"""
Convert a ``dict`` to a corresponding object.
Expand Down

0 comments on commit dd52a94

Please sign in to comment.