mirror of
https://github.com/msoedov/agentic_security.git
synced 2026-08-09 03:06:05 +02:00
fix(report):
This commit is contained in:
@@ -26,7 +26,7 @@ def plot_security_report(table: Table) -> io.BytesIO:
|
|||||||
try:
|
try:
|
||||||
return _plot_security_report(table=table)
|
return _plot_security_report(table=table)
|
||||||
except (TypeError, ValueError, OverflowError, IndexError, Exception) as e:
|
except (TypeError, ValueError, OverflowError, IndexError, Exception) as e:
|
||||||
logger.error(f"Error in generating the security report: {e}")
|
logger.error(f"Error in generating the security report: {e} {table}")
|
||||||
return io.BytesIO()
|
return io.BytesIO()
|
||||||
|
|
||||||
|
|
||||||
@@ -40,11 +40,7 @@ def generate_identifiers(data: pd.DataFrame) -> list[str]:
|
|||||||
Returns:
|
Returns:
|
||||||
list[str]: A list of generated identifiers. Returns a list with an empty string in case of an error.
|
list[str]: A list of generated identifiers. Returns a list with an empty string in case of an error.
|
||||||
"""
|
"""
|
||||||
try:
|
return _generate_identifiers(data=data)
|
||||||
_generate_identifiers(data=data)
|
|
||||||
except (TypeError, ValueError, Exception) as e:
|
|
||||||
logger.error(f"Error in generate_identifiers: {e}")
|
|
||||||
return [""]
|
|
||||||
|
|
||||||
|
|
||||||
def _plot_security_report(table: Table) -> io.BytesIO:
|
def _plot_security_report(table: Table) -> io.BytesIO:
|
||||||
|
|||||||
Reference in New Issue
Block a user