Skip to main content

chat for projects we help maintain @ ckc

Project description

django-chit-chat CKC

chat for projects we help maintain @ ckc

installing

pip install django-chit-chat
# settings.py
INSTALLED_APPS = (
    "django.contrib.auth",
    "django.contrib.contenttypes",
    "django.contrib.sessions",
    "django.contrib.staticfiles",

    # ... add chit_chat
    "chit_chat",
)
# routing.py
from channels.auth import AuthMiddlewareStack
from django.core.asgi import get_asgi_application
from channels.routing import ProtocolTypeRouter, URLRouter

import chit_chat.routing


application = ProtocolTypeRouter({
    'http': get_asgi_application(),
    'websocket': AuthMiddlewareStack(
        URLRouter(
            chit_chat.routing.websocket_urlpatterns
        )
    ),
})
# urls.py
from rest_framework import routers

from chit_chat.viewsets import RoomViewSet


router = routers.SimpleRouter()
router.register('chatrooms', RoomViewSet)

urlpatterns = router.urls

distributing

# change version in setup.cfg
$ ./setup.py sdist
$ twine upload dist/*

tests

$ docker build -t django-chit-chat . && docker run django-chit-chat pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-chit-chat-0.0.2.tar.gz (10.7 kB view details)

Uploaded Source

File details

Details for the file django-chit-chat-0.0.2.tar.gz.

File metadata

  • Download URL: django-chit-chat-0.0.2.tar.gz
  • Upload date:
  • Size: 10.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.7.9

File hashes

Hashes for django-chit-chat-0.0.2.tar.gz
Algorithm Hash digest
SHA256 70eba850a80098bb385b25ccd3bf573f43c1a1b2a3acc4d8c8444b0a4078d2e1
MD5 7a2f141c5e05a1a70ecee1b2ddff1381
BLAKE2b-256 26f9f7b63b4fc0729190196eb6e1c40f95b80bf0aa74d08c58a1705f31f53e65

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page