Repository navigation
Description
π Reproduction steps
- Self-hosted Appwrite 2.5.0 with Console image
appwrite/new:1.2.74-self-hosted. - Organization β Members β Invite a new email address.
- Open the invite link (
/join?membershipId=β¦&userId=β¦&secret=β¦&teamId=β¦) in a private window, i.e. not signed in.
π Expected behavior
The "Accept invitation" screen is shown and the invite can be accepted, as in 1.1.107-self-hosted (fix for #13724).
π Actual Behavior
A spinner is shown indefinitely. GET /v1/account returns 401 once, no further requests are made, and there is no error in the browser console. Users who are already signed in are not affected.
Cause: a render loop on the invite screen.
- For a guest, the account query ends with 401,
useAuth().isLoadingbecomesfalse, and the screen switches fromloadingtoaccept. - The
acceptscreen rendersAuthFlowAccountSwitcher, which callsuseAuth()again. - The new observer refetches the failed query on mount, because
retryOnMountdefaults totrueinconsoleAccountQueryOptions()(src/lib/react-query/hooks/auth.ts). - The screen returns to
loading, the switcher unmounts, the cached 401 is replayed, and the cycle repeats.
Adding retryOnMount: false to consoleAccountQueryOptions() fixes it. With this change applied to 1.2.74-self-hosted, the invite is accepted normally, and sign-in and the organization pages keep working.
| Console image | Guest on /join |
|---|---|
1.1.107-self-hosted |
works |
1.1.159-self-hosted |
endless spinner |
1.2.74-self-hosted |
endless spinner |
π² Appwrite version
Different version (specify in environment)
π» Operating system
Linux
π§± Your Environment
Appwrite 2.5.0 (also reproduced with 2.3.0), self-hosted with Docker Compose, Console appwrite/new:1.2.74-self-hosted. Reproduced on a fresh installation without modifications.
π Have you spent some time to check if this issue has been raised before?
- I checked and didn't find similar issue
Related: #13724
π’ Have you read the Code of Conduct?
- I have read the Code of Conduct
Activity
VishalDipake commentedon Oct 17, 2026
Hi! I'd like to work on this issue.
From the description, it looks like the repeated loading may be caused by the failed auth query being retried when the account switcher mounts. I'll investigate
consoleAccountQueryOptions()and the related auth flow, then test a fix to ensure invited users can accept invitations without signing in first.Please let me know if there's any additional context or a preferred approach I should follow.