mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-28 22:34:22 +00:00
chore(docs): update docs to use logger.exception
This commit is contained in:
1 parent
6557ce8d51
commit
f03d230761
2 files changed
+6
-6
No files matched your search
@@ -113,7 +113,7 @@ class <Service>(ServiceParentClass):
|
||||
)
|
||||
|
||||
except Exception as error:
|
||||
logger.error(
|
||||
logger.exception(
|
||||
f"{<provider_specific_field>} -- {error.__class__.__name__}[{error.__traceback__.tb_lineno}]: {error}"
|
||||
)
|
||||
|
||||
@@ -124,7 +124,7 @@ class <Service>(ServiceParentClass):
|
||||
# - GCP: project_id and location
|
||||
# - Azure: subscription
|
||||
|
||||
logger.error(
|
||||
logger.exception(
|
||||
f"{<provider_specific_field>} -- {error.__class__.__name__}[{error.__traceback__.tb_lineno}]: {error}"
|
||||
)
|
||||
|
||||
@@ -161,7 +161,7 @@ class <Service>(ServiceParentClass):
|
||||
f"{error.__class__.__name__}[{error.__traceback__.tb_lineno}]: {error}"
|
||||
)
|
||||
else:
|
||||
logger.error(
|
||||
logger.exception(
|
||||
f"{<provider_specific_field>} -- {error.__class__.__name__}[{error.__traceback__.tb_lineno}]: {error}"
|
||||
)
|
||||
continue
|
||||
@@ -173,7 +173,7 @@ class <Service>(ServiceParentClass):
|
||||
# - GCP: project_id and location
|
||||
# - Azure: subscription
|
||||
|
||||
logger.error(
|
||||
logger.exception(
|
||||
f"{<item>.region} -- {error.__class__.__name__}[{error.__traceback__.tb_lineno}]: {error}"
|
||||
)
|
||||
```
|
||||
|
||||
Reference in new issue
Block a user