Re: Channels 2.0 close code and http response status

2018-06-24 Thread Kirill Tyushchakov
e it > immediately with a custom WebSocket close code (you can do all of that > inside connect, I think). > > Andrew > > On Thu, Jun 21, 2018 at 2:52 PM Kirill Tyushchakov > wrote: > >> Hello everyone! >> I'm new in Django Channels. I'm using Channels 2.0 an

Channels 2.0 close code and http response status

2018-06-21 Thread Kirill Tyushchakov
Hello everyone! I'm new in Django Channels. I'm using Channels 2.0 and I have few questions about it. I'm using JsonWebsocketConsumer class for my consumer and I wrote my definition of connect method like this: def connect(self): user = self.scope.get('user') if user.is_anonymous: