Skip to content

Commit

Permalink
Address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
q0w committed Jan 22, 2023
1 parent ac23db6 commit 6b93a08
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lintrunner_adapters/adapters/refurb_linter.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import logging
import re
import sys
from textwrap import dedent
import textwrap

from lintrunner_adapters import LintMessage, LintSeverity, add_default_options
from lintrunner_adapters._common.lintrunner_common import run_command
Expand Down Expand Up @@ -47,7 +47,7 @@ def _test_results_re() -> None:
def format_lint_message(message: str, code: str, show_disable: bool) -> str:
formatted = f"{message}\n"
if show_disable:
formatted += dedent(
formatted += textwrap.dedent(
f"""
To disable, use
[tool.refurb]
Expand Down Expand Up @@ -101,7 +101,7 @@ def check_files(
if match["column"] is not None and not match["column"].startswith("-")
else None,
code=LINTER_CODE,
severity=severities.get(match["code"], LintSeverity.ERROR),
severity=severities.get(match["code"], LintSeverity.ADVICE),
original=None,
replacement=None,
)
Expand All @@ -117,6 +117,7 @@ def main() -> None:
parser.add_argument(
"--config-file",
required=True,
default="pyproject.toml",
help="path to pyproject.toml config file",
)
parser.add_argument(
Expand Down

0 comments on commit 6b93a08

Please sign in to comment.