Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Instant messaging with WebSocket #344

Merged
merged 7 commits into from
May 25, 2024
Merged

Conversation

blu3eee
Copy link
Contributor

@blu3eee blu3eee commented May 24, 2024

[Backend]

  • Apply changes in database models for conversations, messages, and conversation participants
  • API endpoints for /conversations (create conversations, get conversation messages, and get users/accounts' conversations)
  • Added tests for said endpoints

[DevOps]

use uvicorn instead of daphne to run asgi backend app so it can be hot-reloaded on dev environment
- change in database models for conversations, messages, and conversation participants
- api endpoints for conversation related information
- api endpoint for user's conversation at `/accounts/{accountID}/conversations`
- tests for said endpoints
- setup websocket for messaging system
- receiving messages from the server to clients in real-time.
Copy link
Contributor

@shotoh shotoh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

left a few comments

mesh/conversation/views.py Outdated Show resolved Hide resolved
mesh/conversation/views.py Outdated Show resolved Hide resolved
mesh/tests/chat_wsclient_pytests.py Outdated Show resolved Hide resolved
mesh/conversation/views.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@misslame misslame left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you update dependencies? i have never seen this view in github before kinda cool. I will approve for now but shotoh had good questions about the exceptions.

Pipfile Show resolved Hide resolved
Pipfile Show resolved Hide resolved
mesh/conversation/views.py Show resolved Hide resolved
earlier I removed daphne from dependencies as I thought we don't need it anymore for the ASGI server, but apparently we do need it for the Django channels layer when performing test with `channels.testing`
Reference: django/channels#1942
@blu3eee blu3eee merged commit b658d9c into dev May 25, 2024
@blu3eee blu3eee deleted the leaf/jack/store-conversations branch May 25, 2024 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants