Skip to content

Fix FedCM issue caused by the recent breaking change#104

Open
agektmr wants to merge 3 commits intomainfrom
fedcm-fix
Open

Fix FedCM issue caused by the recent breaking change#104
agektmr wants to merge 3 commits intomainfrom
fedcm-fix

Conversation

@agektmr
Copy link
Copy Markdown
Collaborator

@agektmr agektmr commented Apr 1, 2026

@agektmr agektmr requested review from ewewraw and rowan-m April 1, 2026 07:07
Copy link
Copy Markdown
Collaborator

@rowan-m rowan-m left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trying to sign in using a federated account on my local dev gives an "ID token verification failed." error in the console and an "Undefined" toast in the UI. It works on main.

/**
* Initializes the IdP by fetching configuration options from the server.
* Resolves the config URLs and client IDs for each IdP.
* @returns The nonce to be used for authentication.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New hint has been added for a return value, but the function does not return it.

this.idps.push(idp);
}
return options.nonce;
return;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should there be a return value here? If not, just remove the return.

@agektmr
Copy link
Copy Markdown
Collaborator Author

agektmr commented Apr 1, 2026

Trying to sign in using a federated account on my local dev gives an "ID token verification failed." error in the console and an "Undefined" toast in the UI. It works on main.

Could you double check that you are signing in using https://idp.locahost ? If it's with https://identity-provider-sesame.appspot.com, it won't work.

@rowan-m
Copy link
Copy Markdown
Collaborator

rowan-m commented Apr 1, 2026

Could you double check that you are signing in using https://idp.locahost ? If it's with https://identity-provider-sesame.appspot.com, it won't work.

Ah, yeah - it's using the remote IdP. How do I change the config to use the localhost one?

@rowan-m
Copy link
Copy Markdown
Collaborator

rowan-m commented Apr 2, 2026

Made sure I'm running against the latest commits, but it still runs against the remote IdP when I use npm run dev:local. Is there something else I need to change or a different command to run?

@agektmr
Copy link
Copy Markdown
Collaborator Author

agektmr commented Apr 2, 2026

I found the root cause but struggling to fix this. Let me nudge you when it starts working.

@agektmr
Copy link
Copy Markdown
Collaborator Author

agektmr commented Apr 3, 2026

@rowan-m there were two issues:

  • SameSite: None was required but missing. No idea why it's been working (and is still working on the staging environment)
  • params sent to the server needs to be JSON parsed. It's passed as a JSON string.

It should work fine by now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants