Add MatrixTransport (A1) — step-2 PR B
- matrix.py: Transport implementation over the Matrix client-server HTTP API directly (token auth, /sync long-poll, /send) using the existing httpx dependency — no Matrix SDK; four endpoints total. Deviation from the presented plan (matrix-nio) flagged in the PR - First sync learns position and skips backlog, so room history is never delivered as context (A1); own messages and non-message events filtered; sender MXID passed through for the orchestrator's operator allowlist - Sync loop backs off (capped at 60s) and retries indefinitely on homeserver errors, mirroring B2's polling posture - Encrypted rooms unsupported: bot rooms are created unencrypted until E2E lands (operator decision; room recreated accordingly) - NISSE_MATRIX_TEST_ROOM_ID added: the live smoke test binds only to the dedicated test room, never the production room - 8 unit tests over a mocked HTTP layer; live integration test verified against the real homeserver Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
5dad5cf90f
commit
5db6d9d96e
4 files changed
+380
No files matched your search
@@ -16,4 +16,6 @@ NISSE_MATRIX_HOMESERVER=https://matrix.example
|
||||
NISSE_MATRIX_USER_ID=@nisse-dev:example
|
||||
NISSE_MATRIX_TOKEN=syt_your_matrix_access_token
|
||||
NISSE_MATRIX_ROOM_ID=!roomid:example
|
||||
# Dedicated room for the live integration test; never the production room.
|
||||
NISSE_MATRIX_TEST_ROOM_ID=!testroomid:example
|
||||
NISSE_MATRIX_OPERATORS=@you:example
|
||||
Reference in new issue
Block a user