Ah, yes, sorry, the default serializer in Django cannot serialise model
instances as it's JSON-based:
https://docs.djangoproject.com/en/1.10/topics/serialization/
You can try switching to an alternate serialiser like pickle which does
(but I don't recommend this), or just put the ID of the user in
Thanks for explaining.
I have one problem: when I try to save User object to the channel_session I
get exception: TypeError: Object of type 'User' is not JSON serializable.
What am I doing wrong? Should I somehow define how to JSON serialize the
User object?
On Wednesday, February 1, 2017 at 7:0
Hi,
You're right - a lot of the information only appears in the first "connect"
message. If you want to persist it, you can use a channel session:
http://channels.readthedocs.io/en/stable/getting-started.html#persisting-data
This will let you save information (such as the token, or even a User
obj
Hi,
I am trying to use the query_string parameter and I want to ask what is the
correct way how to use it.
I am using JsonWebsocketConsumer and when debugging I noticed that on the
Handshake the message content contains path, headers, query_string, client,
server, reply_channel and order.
But ev
4 matches
Mail list logo