Re: wrong imports channel ?

2018-04-12 Thread Andrew Godwin
Channels 2 has different objects and import paths - code from Channels 1
(like you have there) isn't compatible.

Andrew

On Thu, Apr 12, 2018 at 12:37 AM, Jules LE BRIS 
wrote:

> Hi,
>
> I would like to do something like this in views.py :
>
> message = {"message":msg}
> Channel('chat').send(message, immediately=True)
>
> but the import : from channels import Channel doen't work. I'm using
> channels==2.0.2.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/b7684c27-9568-4321-a70b-29e58c550b3d%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAFwN1uqCuYwJYkFpnQ%3DtcVXjNNZQi-5fx9GNj%2BmZkADntv1jLQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: wrong imports channel ?

2018-04-12 Thread N. Srinivasan
Thank you Sir!

On Thu, Apr 12, 2018 at 3:37 AM, Jules LE BRIS  wrote:

> Hi,
>
> I would like to do something like this in views.py :
>
> message = {"message":msg}
> Channel('chat').send(message, immediately=True)
>
> but the import : from channels import Channel doen't work. I'm using
> channels==2.0.2.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/b7684c27-9568-4321-a70b-29e58c550b3d%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAEAcyBZpVtPgJhHdrvYR5Wg-em0nM%3DEdcqxJ9gvhHfWeP91ziA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


wrong imports channel ?

2018-04-12 Thread Jules LE BRIS
Hi,

I would like to do something like this in views.py :

message = {"message":msg}
Channel('chat').send(message, immediately=True)

but the import : from channels import Channel doen't work. I'm using 
channels==2.0.2.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/b7684c27-9568-4321-a70b-29e58c550b3d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.