Skip to content

Feature: fastapi#11

Open
inventionpro wants to merge 2 commits into
mainfrom
feature-fastapi
Open

Feature: fastapi#11
inventionpro wants to merge 2 commits into
mainfrom
feature-fastapi

Conversation

@inventionpro

Copy link
Copy Markdown
Contributor

No description provided.

Replaces Flask/waitress with Starlette/uvicorn behind a thin Flask-compat
shim (app/router.py, app/compat.py, app/responses.py), so existing route
bodies stay unchanged. Business logic stays synchronous and runs via
Starlette's threadpool; the /stream SSE endpoint is upgraded to a real
async asyncio.Queue + StreamingResponse so many long-lived connections
don't rely on a thread-per-connection poll loop.

Fixes a status-code bug in the compat shim where FileResponse status
codes were never applied, which silently turned custom error pages
(404.html, /pfp and /attachment 404s) into HTTP 200 responses.
Accept any non-expired channel key on message send instead of only the
latest-by-seq key, so clients holding a still-valid older key aren't
rejected with 'Invalid or outdated encryption key'. Guard key rotation
to return the existing valid key instead of minting a duplicate, closing
the race that produced coexisting valid keys. Clarify member-change key
expiry comments.
@inventionpro inventionpro self-assigned this Jul 7, 2026
@inventionpro inventionpro added the enhancement New feature or request label Jul 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants