Daphne is a HTTP, HTTP2 and WebSocket protocol server for ASGI, and developed to power Django Channels.
Questions tagged [daphne]
259 questions
2
votes
0 answers
Django Channels running through daphne in azure rejects websockets connections (503 error)
I'm developing a web app using Django Channels. It needs to serve HTTP requests and also accept websockets connections. In local everything runs fine, but I'm having trouble in Azure. It rejects the websockets connections (HTTP code 503). I've tried…

Daniel
- 61
- 4
2
votes
1 answer
Django Channels Daphne uvicorn
I wrote Django Channels for practice.
Use Daphne
daphne project.asgi:application
Everything works well.
Use uvicorn
uvicorn project.asgi:application
Error on the page
(index):16 WebSocket connection to'ws://127.0.0.1:8000/ws/chat/123/' failed: Error…

dudulu
- 754
- 6
- 17
2
votes
0 answers
nginx setup for Django Channels 3 using Daphne and Supervisor
I have created a Django application with channels. Now I am configuring it for production in AWS EC2. I can access the app when running the python manage.py runserver 0.0.0.0:8000. The apps that I deployed to AWS were using wsgi only and need only…

Abhijith Konnayil
- 4,067
- 6
- 23
- 49
2
votes
2 answers
Why am I getting this error when installing daphne?
First time attempting to run
py -m pip install daphne
from my django project directory:
WARNING: Failed to write executable - trying to use .deleteme logic
ERROR: Could not install packages due to an OSError: [WinError 2] The system can
not find…

Sean
- 192
- 1
- 1
- 14
2
votes
1 answer
Request do not reach FastAPI Server
I was working on Flask microservice and I needed to rewrite it with FastAPI but I had a problem that I had not with Flask.
The problem is that I send a request which is not reaching the server indefinitely. To unstuck the request for example with…

brilleta
- 21
- 2
2
votes
0 answers
Django channels working with WS:// but not with WSS://
I followed explanations from django-channels tutorial and was able to run a chat locally.
However, it does not work in production.
Here is the output from debugger :
WebSocket connection to 'wss://www.example.com/ws/chat/lobby/' failed: Error…

Paul Noon
- 656
- 1
- 8
- 25
2
votes
1 answer
simple django channels app not running with daphne
I’m trying to get django channels running with daphne but I always end up with this
x8/backback/mysite » daphne mysite.asgi:application 1 ↵
Traceback (most recent call…

Lily H.
- 164
- 2
- 10
2
votes
0 answers
Deploy django with apache, django channels 3 and daphne in wss
Os Ubuntu 20 LTS
i have a problem with my project in production, and i don't understand where and whats it's going wrong, thease are the files and the responses:
000-default.conf:
.....
RewriteEngine on
RewriteCond…

umbertowski
- 21
- 1
2
votes
0 answers
Threading stopped working after upgrading Django from 3.0.8 to 3.1.5 and channels from 2.4.0 to 3.0.3
So I've developped Django app using Django 3.0.8 and served it as an asgi app with channels 2.4.0 and daphne. At that point in time those were the latest versions.
The application was working nicely with web sockets and django views working…

Jerry Shaw
- 256
- 4
- 9
2
votes
0 answers
Django+Channels+Heroku deployment with Daphne: Closing Postgre connections
My Django webapp deploys fine, however my db connections max out after a few queries to Postgres.
Here is my understanding of my problem:
Db connections to Postgres are opened for every query but not closed and this results is a db timeout once max…

CMo
- 21
- 2
2
votes
0 answers
djanago channels CRITICAL Listen failure: Couldn't listen on 0.0.0.0:x: [Errno 98] Address already in use
I am trying to deploy my ASGI application.
I have followed the exact docs of https://channels.readthedocs.io/en/latest/deploying.html
But when I am checking my logs i am ending up with:
CRITICAL Listen failure: Couldn't listen on 0.0.0.0:x: [Errno…

saibhaskar
- 435
- 6
- 21
2
votes
0 answers
Django Channels doesn't release memory used by websocket after disconnect
Basically I have a django docker-container and I'm looking at memory usage through the docker stats. I'm using channels for websocket connections.
When the first connection starts, memory usage goes from 60 to 65 mb. Throughout the connection memory…
2
votes
1 answer
Deploying django, channels and websockets with nginx and daphne
I am trying to deploy a django app that uses channels and websockets, with nginx and daphne.
When I was using uwsgi, here was my nginx file:
upstream django {
server unix:/run/uwsgi/devAppReporting.sock;
}
server {
listen 8090;
…

Larry Martell
- 3,526
- 6
- 40
- 76
2
votes
0 answers
Daphne on Google App Engine Flexible for Django Channels app: 502 Bad Gateway Error nginx
I'm new to web development so I appreciate some hand-holding by the smart folks here. I'm trying to switch from gunicorn to Daphne for my Django app on GAE Flex, since I need to use Django Channels.
Previously the site worked fine with gunicorn as…

oktested
- 81
- 1
- 7
2
votes
1 answer
Python Django App deployment on Azure app service with celery and websocket
I'm trying to move my Django application from Heroku to Azure app service.
The Application is consists of Websocket and Rest API.
So the Web part of the application is running on a daphne web server and worker part is running on celery.
In Heroku,…

Muthu Kumar
- 885
- 2
- 14
- 25