Last active
March 27, 2024 20:46
-
-
Save axilaris/b1d26a9564cabd00ddaf2d854879e285 to your computer and use it in GitHub Desktop.
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
const ws = new WebSocket('ws://localhost:8000/ws/notifications/'); |
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
application = ProtocolTypeRouter({ | |
"websocket": URLRouter([ | |
path("/ws/notifications/", consumers.NotificationConsumer.as_asgi()), | |
]), | |
}) |
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
App.js:59 WebSocket connection to 'ws://localhost:8000/ws/notifications/' failed: | |
App.js:71 WebSocket error Event | |
App.js:75 WebSocket closed CloseEvent |
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
System check identified 1 issue (0 silenced). | |
March 27, 2024 - 20:17:02 | |
Django version 4.1.5, using settings 'backend.settings' | |
Starting development server at http://127.0.0.1:8000/ | |
Quit the server with CONTROL-C. | |
Forbidden: /api/user | |
WARNING:django.request:Forbidden: /api/user | |
[27/Mar/2024 20:17:07] "GET /api/user HTTP/1.1" 403 58 | |
Forbidden: /api/user | |
WARNING:django.request:Forbidden: /api/user | |
[27/Mar/2024 20:17:07] "GET /api/user HTTP/1.1" 403 58 | |
Not Found: /ws/notifications/ | |
WARNING:django.request:Not Found: /ws/notifications/ | |
Not Found: /ws/notifications/ | |
WARNING:django.request:Not Found: /ws/notifications/ | |
[27/Mar/2024 20:17:07,174] - Broken pipe from ('127.0.0.1', 51873) | |
[27/Mar/2024 20:17:07] "GET /ws/notifications/ HTTP/1.1" 404 2233 |
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
#ASGI_APPLICATION = "user_api.asgi.application" | |
#ASGI_APPLICATION = "backend.asgi.application" | |
#ASGI_APPLICATION = "backend/backend/asgi.py" | |
ASGI_APPLICATION = 'backend.routing.application' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment