Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion prospector/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,8 @@ def execute(self) -> None:
loc = Location(self.config.workdir, None, None, None, None)
msg = (
f"Tool {toolname} failed to run "
f"(exception was raised, re-run prospector with -X to see the stacktrace)"
"(exception was raised, re-run prospector with --direct-tool-stdout to better see the tool error "
"or --die-on-tool-error to see the stacktrace)"
)
message = Message(
toolname,
Expand Down
20 changes: 1 addition & 19 deletions prospector/tools/mypy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,25 +126,7 @@ def run(self, found_files: FileFinder) -> list[Message]:

def _run_std(self, args: list[str]) -> list[Message]:
messages = []
try:
sources, options = mypy.main.process_options(args, fscache=self.fscache)
except (SystemExit, Exception) as e:
message = "The error(s) will be displayed before the messages" if isinstance(e, SystemExit) else str(e)
messages.append(
Message(
"mypy",
code="fatal-options-error",
message=message,
location=Location(
path="",
module=None,
function=None,
line=0,
character=0,
),
)
)
return messages
sources, options = mypy.main.process_options(args, fscache=self.fscache)
options.output = "json"
try:
res = mypy.build.build(sources, options, fscache=self.fscache)
Expand Down
2 changes: 1 addition & 1 deletion prospector/tools/pyroma/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"BusFactor": "PYR19",
}

PYROMA_CODES = {}
PYROMA_CODES: dict[str, str] = {}


def _copy_codes() -> None:
Expand Down
Loading