A user, koltl, reports an issue where 2FA prevents password reset, receiving an “Invalid authentication code” error after entering the 2FA code. codinghorror confirms the bug, and featheredtoast identifies it as a fixable bug in the code, providing a commit link. koltl asks how to apply the fix, and featheredtoast instructs to visit the site’s upgrade page at /admin/upgrade.
I just installed Discourse on a VPS and recovered from a backup. I have 2FA on my account and when I sign on using the email (and link it sends me) w/o using password, it will ask for 2FA code which does work. But when I want request to reset to password, I open the link and it asks for 2FA which I put in, and it gives me,
Invalid authentication code. Each code can only be used once.