Skip to content

Commit

Permalink
more logging data_server_call_back
Browse files Browse the repository at this point in the history
  • Loading branch information
burnout87 committed Oct 25, 2023
1 parent 898cca6 commit 76a1c8e
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cdci_data_analysis/flask_app/dispatcher_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,10 @@ def __init__(self, app,
# this can be set since it's a call_back and job_id and session_id are available
self.logger.info(f"before setting scratch_dir: job_id: {self.par_dic['job_id']} callback: {data_server_call_back}, resolve_job_url: {resolve_job_url}")
self.set_scratch_dir(session_id=self.par_dic['session_id'], job_id=self.par_dic['job_id'])
self.set_session_logger(self.scratch_dir, verbose=verbose, config=config)
self.logger.info(f"scratch_dir set {self.scratch_dir}, job_id: {self.par_dic['job_id']} callback: {data_server_call_back}, resolve_job_url: {resolve_job_url}")
self.set_scws_call_back_related_params()
self.logger.info(f"set_scws_call_back_related_params executed")
else:
self.set_scws_related_params(request)

Expand Down Expand Up @@ -200,6 +203,7 @@ def __init__(self, app,
"and resubmit you request.")
if data_server_call_back:
message = "The token provided is expired, please resubmit you request with a valid token."
self.logger.info(message)
sentry.capture_message(message)

raise RequestNotAuthorized(message)
Expand All @@ -210,6 +214,7 @@ def __init__(self, app,
"and resubmit you request.")
if data_server_call_back:
message = "The token provided is expired, please resubmit you request with a valid token."
self.logger.info(message)

Check warning on line 217 in cdci_data_analysis/flask_app/dispatcher_query.py

View check run for this annotation

Codecov / codecov/patch

cdci_data_analysis/flask_app/dispatcher_query.py#L217

Added line #L217 was not covered by tests
sentry.capture_message(message)

raise RequestNotAuthorized(message)
Expand Down

0 comments on commit 76a1c8e

Please sign in to comment.