All Questions
Tagged with websocket django-channels
580
questions
0
votes
0
answers
19
views
React front end triggering WebSocket.onmessage twice
I'm new to React and am currently trying to create a real time chat app. I'm nearly finished. the last feature needed is that the React component pasted below needs to receive messages from the Django ...
1
vote
1
answer
97
views
Django Channels on IIS using FASTCGI
I am deploying a Django app using an IIS server. In this Django app, I have implemented Django Channels to use websockets. Locally, everything is working fine with websocket connections, and I am able ...
0
votes
0
answers
36
views
Issue sending messages to a channel group in Django
I sat up a system with a user, member and team models. What i am trying to achieve with sockets, is for one of the team members to notify everyone on the team about an achievement.
Clientside:
Svelte ...
0
votes
0
answers
420
views
Django Channels Config - Django / Docker / Gunicorn / Daphne / Nginx
I have deployed an app, pypilot.app using django / nginx / docker / daphne / gunicorn on a digital ocean droplet. Daphne is for Django Channels which works no problem in development to display ...
0
votes
1
answer
111
views
AttributeError: 'set' object has no attribute 'decode'
I started learning Django for a school project and I'm doing a chat project using websocket server, but when reloading the app I get this error even tho I'm not calling decode() anywhere. I'm using ...
0
votes
1
answer
66
views
django channels took to long to shut down and was killed error in backend
I used django channels in this project and created a consumer in the following code:
class WSConsumer(WebsocketConsumer):
def connect(self):
self.room_name = self.scope["url_route"][&...
1
vote
1
answer
52
views
Websocket jwt authentification keeps handshaking and disconnecting
I have this custom jwt auth-middleware in django:
class JWTAuthMiddleware:
def __init__(self, inner):
self.inner = inner
async def __call__(self, scope, receive, send):
print(": ...
0
votes
0
answers
23
views
Django channels async websocket group_send not working
I've created an async web socket with the below code:
class AgentSessionAsyncConsumer(AsyncJsonWebsocketConsumer):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
...
0
votes
0
answers
39
views
Audio bytes chunks getting corrupted during streaming using Django and Websockets
I am trying to implement an audio streaming transcription service using django and websockets. The implementation works but the chunks get corrupted after some time like after tenth or eleventh chunk ...
0
votes
0
answers
24
views
Django channels web socket not working with nginx and gunicorn in the cloud server
This is my project configuration for Django channels, gunicorn and nginx.
In local machine the django websocket works great. but after deploying to the cloud server it shows this console error:
Mar 27 ...
1
vote
0
answers
11
views
Websockets stopped working after adding nginx and gunicorn
I am making a django-react app, and I use django channels for my websockets in order to create live chat. After adding gunicorn and nginx however, my websockets are no longer able to connect from my ...
0
votes
1
answer
218
views
error "Failed to execute send on Websocket: Still in CONNECTING state" in Django Channels Production environment using SSL
I'm currently deploying an application using Django Channels in Production environment.
The target application is based on the sample app from the official django channel documentation.
https://...
0
votes
0
answers
38
views
Will I need a consumers.py, asgi,py and routing.py using Tradier's websocket API?
So I'm trying to stream market data via the tradier API with websockets. Here are 2 links to the docs:
https://documentation.tradier.com/brokerage-api/streaming/websocket-streaming
https://...
0
votes
0
answers
23
views
How can one enable a mix of authenticated and unauthenticated websockets using Django Channels?
I'm running a Django application with DRF and Channels and I've configured a number of websockets, one of which I need to be open/insecure. However, all I can figure out is how to enable/disable ...
1
vote
1
answer
277
views
django.core.exceptions.SynchronousOnlyOperation You cannot call this from an async context - use a thread or sync_to_async
I am using Django channels to implemented web sockets.
I want to get database queries using ORM inside consumers.py.
This is my code:
import json
from channels.generic.websocket import ...