[codex] add native WebSocket gateways#126
Merged
Merged
Conversation
0b12067 to
b748f14
Compare
824205d to
469f89f
Compare
469f89f to
042c8d1
Compare
This was referenced May 9, 2026
Closed
ItayTheDar
added a commit
that referenced
this pull request
May 10, 2026
* feat: add websocket gateways (#126) * test(cli): add e2e test that generates a gateway and runs it as a websocket app Loads the scaffolded chat_gateway.py via importlib, wires it into a Module, boots a uvicorn server, and verifies the generated `ping` handler returns `pong` over a real websocket connection. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * ci(cli): exercise `pynest generate gateway` in CLI smoke matrix Adds a `pynest generate gateway -n chat -p src` step to the CLI test workflow and asserts the generated file exists with the expected @WebSocketGateway decorator across all app-type variants. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * ci(cli): boot generated gateway and verify it responds to a real ping Adds a Blank-only step that loads the scaffolded chat_gateway.py, boots it via PyNestFactory + uvicorn, opens a websocket to /chat and asserts the {event:ping} → {event:pong} round-trip. Gated to the Blank matrix variant since DB-backed apps would fail to boot without their database. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
nest.websocketswith native FastAPI WebSocket gateway support:@WebSocketGateway,@SubscribeMessage,MessageBody,ConnectedSocket, lifecycle hooks,ExecutionContext, andWebSocketServerhelpers.pynest generate gatewayscaffolding.Stacking note
This PR targets
auspicious-dartbecause it depends on PR #125's DI/container rewrite. Once PR #125 lands inmain, this PR can be retargeted tomain.Validation
uv run --group test python -m pytest tests→ 156 passeduv run --group docs mkdocs build --clean→ passedgit diff --check→ passed