Describe the bug
When logging in on PyPI via https://pypi.org/account/login/, the login flow appears to succeed through username/password and the second factor code entry, but the session is immediately invalidated. After submitting the 2FA code, I am redirected to a page that still shows “Log in” and “Register” (no account/menu visible), with a banner message at the top: “Session invalidated”. In the browser network tab, the request to https://pypi.org/account/two-factor returns HTTP 303.
Expected behavior
After successfully entering username/password and a valid 2FA code, I should be logged in and see my account/session (e.g., account menu / profile link), without any “Session invalidated” message.
To Reproduce
- Go to
https://pypi.org/account/login/
- Enter PyPI username (nickname) and password, submit
- Enter the 2FA authentication code, submit
- Observe that the page still shows “Log in” / “Register” and a banner “Session invalidated”
- Open DevTools → Network: request to
https://pypi.org/account/two-factor shows 303 status
My Platform
- Browser: Google Chrome Version 143.0.7499.170 (Official Build) (arm64)
Additional context
- The visible UI after completing 2FA looks like an unauthenticated state (no account information shown).
- Network:
https://pypi.org/account/two-factor returns 303 during the 2FA step.
- Nickname:
eugene.evstafev
Describe the bug
When logging in on PyPI via
https://pypi.org/account/login/, the login flow appears to succeed through username/password and the second factor code entry, but the session is immediately invalidated. After submitting the 2FA code, I am redirected to a page that still shows “Log in” and “Register” (no account/menu visible), with a banner message at the top: “Session invalidated”. In the browser network tab, the request tohttps://pypi.org/account/two-factorreturns HTTP 303.Expected behavior
After successfully entering username/password and a valid 2FA code, I should be logged in and see my account/session (e.g., account menu / profile link), without any “Session invalidated” message.
To Reproduce
https://pypi.org/account/login/https://pypi.org/account/two-factorshows 303 statusMy Platform
Additional context
https://pypi.org/account/two-factorreturns 303 during the 2FA step.eugene.evstafev