Skip to content

Replace Rotur groups with Rotur orgs - #88

Merged
Mistium merged 28 commits into
mainfrom
t3/rotur-orgs-replace-groups
Nov 29, 2026
Merged

Mistium merged 28 commits into
mainfrom
t3/rotur-orgs-replace-groups

Conversation

@Mistium

@Mistium Mistium commented Nov 28, 2026 •

Copy link
Copy Markdown
Member

Rotur orgs replace Rotur groups in MistWarp. An org account now owns projects and spaces directly (owner is the org's username, ownerId its Rotur id, ownerType: "org"). Group tags, group pages and the group endpoints are removed.

Depends on rotur/api#266 (https://git.rotur.dev/rotur/api/pulls/266), which adds the /v2/integrations/mistwarp/orgs/<id> and /users/<id>/orgs endpoints this calls. Merge that first.

What changes

  • Publishers. Org members with the Rotur apps or admin permission create, edit, manage and delete org content as owners. Students never publish for an org.
  • Moving content. Any publisher can move their own content into an org they publish for. Only an org admin (or a site admin) can move org content out (canMoveOut).
  • Lookups. Orgs are looked up by Rotur id, so renames keep access. Snapshots are cached for 60 s (404 for 10 s, failures for 15 s), and concurrent lookups share one fetch.
  • Rotur waits are kept off the save path. The viewer's own org list is checked before the org itself. Commits, editor uploads, branch changes and remixes warm org access before they take the project save lock. Websocket broadcasts only read the cache.
  • Space writes after a Rotur check. These re-read the space and write it under a short per-space lock, then re-check curator authority there. This covers edits, curators, judges, scores, votes, joins, leaves, comments, follows and thumbnails. An edit applies only the fields that changed. If the owner moved or the curator was removed meanwhile, it answers 409 space_changed.
  • Outages. If Rotur is unreachable, creating, updating, transferring, rating, leaving and removing your own entry answer 503 rotur_unavailable. A move into an org that Rotur says can't own content answers 403 org_unavailable.
  • Notifications. Owner notifications for org content go to up to 25 publishers, skipping the actor. Every purchase is sent.
  • The org page (GET /v1/orgs/:name) shows public content to everyone. Unlisted, private and unshared content (with keyed thumbnails) is shown to publishers only.
  • Smoke tests. scripts/e2e_smoke.py runs an org challenge flow, including concurrent votes and edits against slow Rotur org lists, and a studio thumbnail check. The vote and curator race checks fail on the commits before the fixes.

Version

opal.json goes from 1.7.0 to 2.0.0. This is a major bump because the group endpoints and the groupTag fields are removed.

Checks

  • osl-ci test: 67/67 suites pass.
  • osl-ci lsp check main.osl: no errors.
  • scripts/check_conventions.py: ok.
  • e2e_smoke.py: 463 steps, 0 failures, 0 server errors.

Reviewed adversarially: eight DeepSeek V4.1 Flash rounds (the ninth could not run once the provider quota ran out), then nineteen Opus rounds until a round found nothing new.

Screenshots

These were taken in Chromium and Firefox against this branch with scratch-gui t3/rotur-orgs-replace-groups.

Org page, Chromium.
org projects

Org members, Firefox.
org members

Moving a project as a publisher who isn't an org admin. Only an org admin can move it out.
move out locked

Managing an org studio as an admin.
manage space

Preview (tailnet dev server, stays up only while the dev units run): http://archlinux.tailb819f2.ts.net:8602/users/mistwarp. It runs this branch against #88 with a mocked Rotur org integration.

…ing publisher as the challenge participant, and give creation refusals a code
…by id, keep renames and erasure off org records, and retry org fan-outs after an outage
… concurrent callers, list only org-owned spaces, and say who may move a listed space out
… list before asking Rotur about an org, cap the org page lists, and let a publisher leave a challenge another publisher entered
…tur on subscribe, match broadcast viewers by id, warm each org once, and refuse moves into an org that can't own content
…ations at 25, send every purchase, and answer 503 on own-content guards while Rotur is down
…hers out of judge invite answers, and skip the org fan-out for whoever already got the reply
… count only sent org notifications toward the cap
…te admin, skip Rotur for students, and leave the actor out of the org notification count
… org lookup for live hosts who already edit, hide private publishers' scores from curators outside the org, rename submittedBy, and check space visibility before the reaction lock
…e org, and use the plain project role for students on subscribe
…otes and submissions under a per-space lock after the Rotur checks, and smoke test an org challenge
…g judges while Rotur is down, and make the smoke votes really overlap
…, and refuse leaving with 503 while Rotur can't tell
…d keep locked challenge fields when saving a space edit
…ter scoring, delete spaces under the space lock, and smoke test deleting an org challenge
…, refuse it if the owner moved, and remove judges and publish results under the space lock
…e and cancel curators and invite judges under the space lock
…om cache for public challenge views, and smoke test a curator removed during an edit
…ant rules, recheck challenge date order under the space lock, and let an entry's owner remove it without the curator recheck
…ce lock on a fresh read, and smoke test comments and follows
@Mistium
Mistium merged commit 95d3e8d into main Nov 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant