Skip to content

Conversation

@MidhunSureshR
Copy link
Member

@MidhunSureshR MidhunSureshR commented Dec 5, 2025

Closes #31005

There's a complex sequence of events that occurs when you type a join command.

  1. The join command works by dispatching an Action.ViewRoom action with auto join set to true.
  2. This eventually leads to RoomViewStore.viewRoom where the second if condition (else if (payload.room_alias)) runs and it resolves the room-alias to a room-id and via-server.
  3. Then it again dispatches the same event but with the newly resolved room-id and via_server fields added to the payload.
  4. viewRoom runs again, but now because room-id is present, the first if block runs.
  5. That bit of code sets the state to include the room-alias and via_server.
  6. Then it dispatches a join room action where the room-alias and via_server is taken from state.

Somehow, the state doesn't include the room-alias or via_server so you end up trying to join just with the internal id and this obviously fails with a 404.
In the long term, we probably want to reduce the complexity of the RVS (or even remove it entirely).
But for now, we can explicitly pass the via_server through the join options.

@MidhunSureshR MidhunSureshR added this pull request to the merge queue Dec 8, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Dec 8, 2025
@MidhunSureshR MidhunSureshR added this pull request to the merge queue Dec 8, 2025
Merged via the queue into develop with commit 3b0bc0b Dec 8, 2025
38 of 40 checks passed
@MidhunSureshR MidhunSureshR deleted the midhun/maintainer/fix-join-command-race branch December 8, 2025 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Attempting to join via "/join #alias" causes "You attempted to join using a room ID without providing a list of servers to join through"

3 participants