Invitation accept page shows no target line for a legacy workspace label when no description is resolved

Open Beginner friendly
#38 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
76/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
fastapi, python

Research direction

Read the accept route in server/orcaster_server/auth/router.py and the template in server/orcaster_server/auth/templates/accept_invite.html, then review the existing cases in server/tests/test_invitation_join.py:462-475. Add coverage for both unresolved-description paths and check that the raw legacy label never appears; done when both render a fallback line while the resolved-description case still passes. Add the required Unreleased CHANGELOG entry.

Written by the indexing model from the issue text.

Description

bug P3 server

Problem

The accept page should always tell the visitor what the invitation is for. If it cannot name the workspace, it should still show a safe and true line. The raw workspace:<uuid> label must not be shown.

For an older invitation whose label is workspace:<uuid>, the router clears the label without checking whether a description was resolved (server/orcaster_server/auth/router.py:232-235). The template shows the description first, then the label, then nothing (server/orcaster_server/auth/templates/accept_invite.html:16-17). If both are empty, the page has no invite-target line.

Steps to reproduce

  1. Have an invitation with label workspace:<uuid>.
  2. Make the description unresolved. Any of these does it: AuthConfig.describe_invitation is None (server/orcaster_server/auth/config.py:79, the default); the callback returns None because the payload has no workspace_id, has an unknown role, or the workspace does not exist (server/orcaster_server/workspaces/seam.py:45-80).
  3. Open GET /auth/accept/{token}.
  4. The page answers 200 with the title, the name field and the passkey button, but does not say which workspace or role the visitor is joining.

The existing test covers only the case where a description is resolved (server/tests/test_invitation_join.py:462-475).

Proposed change

Hide the placeholder label only when a description was resolved. When no description exists, show a neutral line, for example Invitation for: an invitation (exact wording to be decided in review). The raw workspace:<uuid> string is never shown. Withheld and expired invitations keep their current behavior.

Acceptance criteria

  • A GET test with a legacy workspace:<uuid> label and an AuthConfig without describe_invitation returns 200 and renders the fallback line.
  • A GET test with a legacy label and a callback that returns None returns 200 and renders the same fallback.
  • When a description is resolved, the page still shows the description and not the label (existing test stays green).
  • The raw workspace:<uuid> string is not in the response body in any of these cases.
  • Existing invitations and flows keep working without config changes.
  • CHANGELOG entry under Unreleased.

Open question

What is the exact neutral wording?

Dominant language
Python
Stars
0
Forks
0
Avg merge
1d 1h
Merged PRs (30d)
10

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from AInvirion/orcaster

All issues in AInvirion/orcaster

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.