File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -1048,6 +1048,9 @@ def oidc_callback():
10481048 return redirect (url_for ('main.login' ))
10491049
10501050 # Exchange code for token
1051+ current_app .logger .info (f"Exchanging code at { oidc_config .token_endpoint } " )
1052+ current_app .logger .info (f"Redirect URI: { url_for ('main.oidc_callback' , _external = True )} " )
1053+
10511054 token_response = requests .post (
10521055 oidc_config .token_endpoint ,
10531056 data = {
@@ -1060,9 +1063,12 @@ def oidc_callback():
10601063 timeout = 10
10611064 )
10621065
1066+ current_app .logger .info (f"Token response status: { token_response .status_code } " )
1067+ current_app .logger .info (f"Token response body: { token_response .text } " )
1068+
10631069 if token_response .status_code != 200 :
10641070 current_app .logger .error (f"Token endpoint returned { token_response .status_code } : { token_response .text } " )
1065- flash ('Failed to obtain access token from identity provider. ' , 'error' )
1071+ flash (f 'Failed to obtain access token: { token_response . text } ' , 'error' )
10661072 return redirect (url_for ('main.login' ))
10671073
10681074 token = token_response .json ()
You can’t perform that action at this time.
0 commit comments