Skip to content

Commit

Permalink
style: qa
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Kowalleck <[email protected]>
  • Loading branch information
jkowalleck committed Oct 20, 2023
1 parent bb0f7a5 commit a2af2ed
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ exclude =

max-line-length = 120

max-complexity = 20
max-complexity = 10

ignore =
# ignore `self`, `cls` markers of flake8-annotations>=2.0
Expand Down
4 changes: 2 additions & 2 deletions cyclonedx/validation/json.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ def __init__(self, schema_version: 'SchemaVersion') -> None:
# this is the def that is used for generating the documentation
super().__init__(schema_version)

if _missing_deps_error:
if _missing_deps_error: # noqa:C901
__MDERROR = _missing_deps_error

def validate_str(self, data: str) -> Optional[ValidationError]:
raise self.__MDERROR[0] # from functionality_not_implemented_error[1]
raise self.__MDERROR[0] from self.__MDERROR[1]

else:
def validate_str(self, data: str) -> Optional[ValidationError]:
Expand Down
2 changes: 1 addition & 1 deletion cyclonedx/validation/xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(self, schema_version: 'SchemaVersion') -> None:
__MDERROR = _missing_deps_error

def validate_str(self, data: str) -> Optional[ValidationError]:
raise self.__MDERROR[0] # from functionality_not_implemented_error[1]
raise self.__MDERROR[0] from self.__MDERROR[1]
else:
def validate_str(self, data: str) -> Optional[ValidationError]:
return self._validata_data(
Expand Down

0 comments on commit a2af2ed

Please sign in to comment.