oidc-client-ts
oidc-client-ts copied to clipboard
getJson: Network Error with sessionMonitor: true
Hello,
I have a working setup of oidc-client-ts, but getting this annoying error.
[UserManager] getUser: user loaded
[UserManager] signinSilentCallback: success
[UserManager] getUser: user loaded
[JsonService] getJson: Network Error
error @ webpack-internal:///…idc-client-ts.js:91
getJson @ webpack-internal:///…dc-client-ts.js:506
[SessionMonitor] _start: Error from getCheckSessionIframe: Failed to fetch
error @ webpack-internal:///…idc-client-ts.js:91
SessionMonitor._start @ webpack-internal:///…c-client-ts.js:1628
oidc-client-ts.js?5540:53 [UserManager] signinSilent: success, signed in subject 1e189eaf-0e7e-43d9-b5ac-601ad958271c
Here is my config:
{
client_id: config.applicationId,
redirect_uri: `${config.hostBaseUrl}/callback`,
post_logout_redirect_uri: `${config.hostBaseUrl}`,
silent_redirect_uri: `${config.hostBaseUrl}/silent-callback`,
scope: `openid profile email ${config.applicationId}`,
authority: config.idpServerUrl,
loadUserInfo: true,
monitorSession: true,
userStore: new WebStorageStateStore({ store: localStorage }),
};
Despite the fact that flow is working and new token received, I would really like to know what the error indicates or how can I debug it? It is probably happening within the iframe request, but my knowledge of the source code is limited.
I've been experiencing this and it's usually the metadata document (.well-known/openid-configuration) that fails to fetch. It's not a failure status code, it just gets aborted. The workaround for now is to fetch it manually and pass it in with settings.
I've been experiencing this and it's usually the metadata document (.well-known/openid-configuration) that fails to fetch
The question is why does it fail with the library, for others it does seem to work...