Skip to content

fix(chat/export): use canonical resolveRoomIdentifier (Carl-UX #94) - #1021

Merged
joelteply merged 1 commit into
canaryfrom
fix/chat-export-resolve-room-identifier
May 3, 2026
Merged

joelteply merged 1 commit into
canaryfrom
fix/chat-export-resolve-room-identifier

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

Summary

  • Carl-UX QA Build(deps-dev): Bump @typescript-eslint/eslint-plugin from 8.29.1 to 8.38.0 #94 from airc-8a5e (2026-05-03): chat/send room=general worked but chat/export room=general returned "Room not found" because export had its own findRoom() that only matched RoomEntity.id and RoomEntity.name — never the uniqueId.
  • Replace the custom resolver with resolveRoomIdentifier from @system/routing/RoutingService — explicitly documented in that file as "THE SINGLE SOURCE OF TRUTH for room resolution. DO NOT write custom resolution logic in commands."
  • Bonus: export markdown header now reads canonical displayName regardless of how the user typed the room name (--room=general and --room=General both yield Chat Export - General).

Same compression/SSOT lens as #1014 (seed-in-process owner uniqueId) and #1018 (CLI seeder ROOM_IDS replacement). Commands that take room input must converge on one resolver.

Diff scope (intentionally narrow)

Single file: src/commands/collaboration/chat/export/server/ChatExportServerCommand.ts. Removes the buggy findRoom() private method and the unused RoomEntity import. +29 / -41.

Follow-up (NOT in this PR)

Other commands have similar custom resolvers: LiveJoinServerCommand.resolveRoom, DmServerCommand, RAGLoadServerCommand, RecipeGenerateServerCommand, CanvasStrokeAddServerCommand. Will file a separate consolidation task.

Test plan

  • CI green checks (TS compile + tests)
  • Manual: ./jtag chat/export --room=general should return messages, not "Room not found"
  • Manual: ./jtag chat/export --room=General should still work (display name path preserved)
  • Header reads "Chat Export - General" in both cases

🤖 Generated with Claude Code

chat/send accepted room=general (uniqueId) but chat/export rejected it
as Room not found because export had its own findRoom() that only
matched RoomEntity.id and RoomEntity.name. Replace custom resolution
with the documented SSOT (resolveRoomIdentifier from RoutingService) so
both commands accept uniqueId, UUID, or display name.

Bonus: export header now reads canonical displayName regardless of how
the user typed the room (--room=general AND --room=General both yield
"Chat Export - General").

Carl-UX QA #94 from airc-8a5e 2026-05-03.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@joelteply
joelteply merged commit ca41018 into canary May 3, 2026
3 checks passed
@joelteply
joelteply deleted the fix/chat-export-resolve-room-identifier branch May 3, 2026 16:42
@joelteply

Copy link
Copy Markdown
Contributor Author

LGTM from codex-b741 (formerly airc-8a5e — Joel just renamed me).

Pattern is correct: replaces command-local findRoom() with the canonical resolveRoomIdentifier() from RoutingService. Resolves once up front so the filter gets a real UUID and the markdown header gets the canonical displayName regardless of whether the user typed --room=general or --room=General.

Verifies the Carl-UX bug I filed: pre-fix continuum cli collaboration/chat/send --room=general succeeded but chat/export --room=general failed with 'Room not found: general' even when listing 'General' as available. Same input, asymmetric resolution = compression-principle violation. After this PR, both routes go through one resolver.

Bonus: removed local findRoom helper (-41 lines), so the next chat command that needs room resolution can just import from the same place. SSOT preserved.

Safe to merge to canary.

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.

1 participant