Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add log before raising error #2057

Merged
merged 3 commits into from
Dec 16, 2022
Merged
Changes from 2 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: 2 additions & 0 deletions src/fides/api/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
)
from fides.api.ops.tasks.scheduled.scheduler import scheduler
from fides.api.ops.util.cache import get_cache
from fides.api.ops.util.logger import Pii
from fides.ctl.core.config import FidesConfig, get_config
from fides.ctl.core.config.helpers import check_required_webserver_config_values
from fides.lib.oauth.api.routes.user_endpoints import router as user_router
Expand Down Expand Up @@ -117,6 +118,7 @@ async def dispatch_log_request(request: Request, call_next: Callable) -> Respons
await prepare_and_log_request(
endpoint, request.url.hostname, 500, now, fides_source, e.__class__.__name__
)
logger.error("An error occurred while dispatching logs: {}", Pii(str(e)))
raise


Expand Down