Commit 0b85c9ca authored by Christian Meeßen's avatar Christian Meeßen
Browse files

Fix orthography

parent bb3ba5f8
......@@ -93,14 +93,14 @@ class LanguageHandler(ABC):
self.deps[dependency_name].update(versions_str.split(","))
if (
dependency_name in self.errors
and "version not specified" in self.errors[dependency_name]
and "Version not specified" in self.errors[dependency_name]
):
self.errors[dependency_name].remove("version not specified")
self.errors[dependency_name].remove("Version not specified")
if len(self.errors[dependency_name]) == 0:
del self.errors[dependency_name]
def _add_error(self, dependency_name: str, error_text: str):
if error_text == "version not specified":
if error_text == "Version not specified":
if dependency_name in self.deps or dependency_name in self.dev_deps:
return
......@@ -117,8 +117,8 @@ class LanguageHandler(ABC):
self.dev_deps.add(dependency_name)
if (
dependency_name in self.errors
and "version not specified" in self.errors[dependency_name]
and "Version not specified" in self.errors[dependency_name]
):
self.errors[dependency_name].remove("version not specified")
self.errors[dependency_name].remove("Version not specified")
if len(self.errors[dependency_name]) == 0:
del self.errors[dependency_name]
......@@ -100,7 +100,7 @@ class Node(LanguageHandler):
)
elif version == "":
self._add_error(
dependency_name=dep, error_text="version not specified"
dependency_name=dep, error_text="Version not specified"
)
else:
self._add_dep(dependency_name=dep, versions_str=version)
......
......@@ -139,7 +139,7 @@ class Python(LanguageHandler):
if "version" not in version:
self._add_error(
dependency_name=dependency.lower(),
error_text="version not specified",
error_text="Version not specified",
)
else:
self._add_dep(
......@@ -175,7 +175,7 @@ class Python(LanguageHandler):
else:
self._add_error(
dependency_name=package.lower(),
error_text="version not specified",
error_text="Version not specified",
)
if "default" in pipfile_lock_dict:
......@@ -240,7 +240,7 @@ class Python(LanguageHandler):
else:
self._add_error(
dependency_name=libname.lower(),
error_text="version not specified",
error_text="Version not specified",
)
def parse_requirements_txt(self, file_path: str) -> None:
......@@ -271,7 +271,7 @@ class Python(LanguageHandler):
if match is None:
self._add_error(
dependency_name=stripped_down_line.lower(),
error_text="version not specified",
error_text="Version not specified",
)
else:
libname = stripped_down_line[: match.start()]
......
......@@ -115,9 +115,9 @@ class ListUsedLicenses(Service):
"""
md_result = f"> **Description: {self.description}**\n\n"
md_result += "#### found licenses\n\n"
md_result += "|license|libraries|\n"
md_result += "|---|---|\n"
md_result += "#### Found Licenses\n\n"
md_result += "| License | Libraries |\n"
md_result += "|---------|-----------|\n"
# pylint: disable=W0622
for license in self.libraries_per_license:
lib_list = " <br> ".join(self.libraries_per_license[license])
......@@ -125,7 +125,7 @@ class ListUsedLicenses(Service):
md_result += "\n"
if len(self.errors) > 0:
md_result += "#### errors\n\n"
md_result += "#### Errors\n\n"
for language in self.errors:
md_result += f"##### {language}\n\n"
for lib in self.errors[language]:
......@@ -141,7 +141,7 @@ class ListUsedLicenses(Service):
Generates a cli version of the result as a chapter for a report.
"""
cli_result = f"Description: {self.description}\n\n"
cli_result += "##### found licenses #####\n"
cli_result += "##### Found Licenses #####\n"
# pylint: disable=W0622
for license in self.libraries_per_license:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment