Skip to main content

Django backend

Reliable APIs, database operations and Django applications.
Media engineeringReact and TypeScriptAI and retrievalDjango backendPython automationDevOps and reliability

Handle a WebSocket disconnect in a Django Channels consumer

A WebSocket connection can disappear while its consumer still owns group membership or a background coroutine. Put cleanup in the disconnect path and make it safe when connection setup completed only partly. Reject unauthenticated connections before accepting them or joining a private group.

Run Django's deployment checks before a release

Django's deployment checks can catch a release that still uses development-oriented settings. Run them with the same settings module and environment that the deployed process will read. A clean local development check says little about a different production configuration.