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
2 changes: 1 addition & 1 deletion dojo/metrics/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ class MetricsType(_MetricsTypeEntry, Enum):
ENDPOINT = ("finding__severity", "mitigated")


def query_counts(
def query_counts[MetricsQuerySet: (QuerySet[Finding], QuerySet[Endpoint_Status])](
open_qs: MetricsQuerySet,
active_qs: MetricsQuerySet,
accepted_qs: MetricsQuerySet,
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/chefinspect/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def get_description_for_scan_types(self, scan_type):

def convert_score(self, raw_value):
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 0.4:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/nancy/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def convert_cvss_score(self, raw_value):
if raw_value is None:
return "Info"
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 4.0:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/nmap/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ def convert_cvss_score(self, raw_value):
Critical 9.0-10.0
"""
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 4.0:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/openvas/parser_v1/xml_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def get_findings(self, filename, test):

def convert_cvss_score(self, raw_value):
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 4.0:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/ssh_audit/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def convert_cvss_score(self, raw_value):
Critical 9.0-10.0
"""
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 4.0:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion dojo/tools/trivy/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def convert_cvss_score(self, raw_value):
if raw_value is None:
return "Info"
val = float(raw_value)
if val == 0.0:
if val == 0:
return "Info"
if val < 4.0:
return "Low"
Expand Down
2 changes: 1 addition & 1 deletion requirements-lint.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ruff==0.15.0
ruff==0.15.1