Skip to content

Classroom surface renders a transient server error as the terminal "this course does not exist" card #1450

Description

@wyuc

What happens

components/classroom/ClassroomSurface.tsx collapses any completed load that did not land a stage into outcome = 'unavailable', and renders that as notFound. lib/classroom/load-classroom.ts turns a non-OK /api/classroom response into null, and the stage-meta sidecar independently reports 'unavailable' for 5xx or timeout. So a course that exists, whose document store returns null (share-store or browser-store course), plus a momentary 503 from /api/classroom and /api/stage-meta/<id>, produces the not-found card: a factual claim with no retry affordance, only "back to home". The pane variant reaches the same claim after its ~31 s backoff.

This predates #1399 (the standalone page already went straight to not-found when a load completed without a stage); #1399 made the state machine explicit, which is what makes it easy to see now. Noted during the #1399 round-2 review.

Expected

Keep "unavailable because of an error" distinct from "absent" (positive 404/410), and either keep probing or give the terminal card a retry when it was reached without a positive answer. The notFound docstring in ClassroomSurface.tsx ("nothing here to retry") should hold true once fixed.

Related

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions