Re: Django Channels Error: WebSocket connection to 'ws://openchat.us:24711/' failed: WebSocket is closed before the connection is established.

2017-05-19 Thread James Schneider
On May 19, 2017 8:02 PM, "djangorobert" wrote: var connect = function () { log('connect'); var oldWs = ws; ws = new config.constructor(url, protocols); thats part of what the error points me to in google tools: (index):182 Disconnected

Re: Django Channels Error: WebSocket connection to 'ws://openchat.us:24711/' failed: WebSocket is closed before the connection is established.

2017-05-19 Thread djangorobert
var connect = function () { log('connect'); var oldWs = ws; ws = new config.constructor(url, protocols); thats part of what the error points me to in google tools: (index):182 Disconnected from chat socket VM170 websocketbridge.js:118 WebSocket connection to

Re: Building correct queryset

2017-05-19 Thread Andrew Beales
brand = Brand.objects.get(title='mybrand') products = Product.objects.filter(brand=brand).order_by('-score')[:4] ...gets you the top 4 products in order for the brand On Friday, May 19, 2017 at 10:32:49 AM UTC+1, Горобец Дмитрий wrote: > > Hello. I have these two models. I have to show 4 or less

django Select or RadioSelect does not work.

2017-05-19 Thread Poorna Thanneeru
Hi, Below is my code. If I use widget=forms.CheckboxSelectMultiple or SelectMultiple, it works for me. But if I use Select or RadioSelect (I want only one to be selected): this doesn't work. If I use 'Select', I get the list of versions (e.g 5.6 and 5.7). If I select 5.7 and click on

multiple db in admin [how-to]

2017-05-19 Thread Nikos Skalis
Hi guys, Could you please advise in the following: registry is the project, BGP is the app, default is the sqlite db, registry is a postgres db the admin.py looks like this: class MultiDBModelAdmin(admin.ModelAdmin): # A handy constant for the name of the alternate database. using =

Re: Django Channels Error: WebSocket connection to 'ws://openchat.us:24711/' failed: WebSocket is closed before the connection is established.

2017-05-19 Thread djangorobert
One qustion i do have is do I leave it as localhost ? or do i change that to a different IP address or www.openchat.us ? thanks On Friday, May 19, 2017 at 11:53:37 AM UTC-5, djangorobert wrote: > > Hi hoping somebody in the entire Djang Users can help me solve this > problem its been going on

Django Channels Error: WebSocket connection to 'ws://openchat.us:24711/' failed: WebSocket is closed before the connection is established.

2017-05-19 Thread djangorobert
Hi hoping somebody in the entire Djang Users can help me solve this problem its been going on for about a week now Im using the django channels example on github the "Multichat" example I am using webfaction. my website for this test is www.openchat.us but when you go to the site it throws an

Re: Django Channels error : (index):173 Disconnected from chat socket websocketbridge.js:118 WebSocket connection to 'ws://www.openchat.us/chat/stream/' failed: Error during WebSocket handshake: Unexp

2017-05-19 Thread djangorobert
THis is the new error that im getting after fixing my redis configuration in the settings.py WebSocket connection to 'ws://openchat.us:24711/' failed: WebSocket is closed before the connection is established. On Thursday, May 18, 2017 at 2:08:05 PM UTC-5, djangorobert wrote: > > >

Re: Problem with CircularDependency Model

2017-05-19 Thread Melvyn Sopacua
On Friday 19 May 2017 00:19:04 Tobias Dacoir wrote: > No, I am trying to deploy it locally. I have no sqlite DB and no > migrations. For some strange reason I used to just run manage.py > makemigrations and would create the initial migrations for all Apps. > This doesn't work for some reason

Re: vs {{ form }}

2017-05-19 Thread guettli
Am Freitag, 19. Mai 2017 10:46:02 UTC+2 schrieb James Schneider: > > > > On Thu, May 18, 2017 at 8:14 AM, guettli > wrote: > >> >> >> >> Am Mittwoch, 17. Mai 2017 23:14:04 UTC+2 schrieb James Schneider: >>> >>> >>> >>> On May 17, 2017 6:31 AM, "guettli"

Django stringformat:"d"not work in template

2017-05-19 Thread MegaKufa
{% if request.GET.active == catmenu.id|stringformat:"d" %} class="active" {% endif %} -- 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

Building correct queryset

2017-05-19 Thread Горобец Дмитрий
Hello. I have these two models. I have to show 4 or less products on a page for each brand ordered by score. Please, help construct correct queryset. class Brand(models.Model): title = models.CharField( verbose_name='Название бренда', max_length=64, unique=True,

Re: vs {{ form }}

2017-05-19 Thread James Schneider
On Thu, May 18, 2017 at 8:14 AM, guettli wrote: > > > > Am Mittwoch, 17. Mai 2017 23:14:04 UTC+2 schrieb James Schneider: >> >> >> >> On May 17, 2017 6:31 AM, "guettli" wrote: >> >> Hi Russell Keith-Magee, >> >> which version do

Re: Django Internship

2017-05-19 Thread Mannu Gupta
On Wednesday, May 17, 2017 at 3:25:42 PM UTC-4, mark wrote: > > A couple of comments.. > > 1. This list is not for job hunting. Learn how to post correctly on email > lists. In this instance, you need an OT (Off Topic) at the start of your > subject line as this is a list for asking technical

Re: Selecting overlapping elements from ArrayField of DateTimeRangeField

2017-05-19 Thread user0008
I answer to my own question. It can't be done :-) The solution needs raw SQL query + subquery (eg. using JOIN LATERAL: https://dba.stackexchange.com/questions/147129/selecting-only-overlapping-elements-from-array-of-ranges ) W dniu czwartek, 18 maja 2017 12:58:35 UTC+2 użytkownik user0008

Re: Problem with CircularDependency Model

2017-05-19 Thread Tobias Dacoir
No, I am trying to deploy it locally. I have no sqlite DB and no migrations. For some strange reason I used to just run manage.py makemigrations and would create the initial migrations for all Apps. This doesn't work for some reason anymore. So I have to to makemigrations APPname for each app

URL Blocked: This redirect failed because the redirect URI is not whitelisted in the app’s Client OAuth Settings. Make sure Client and Web OAuth Login are on and add all your app domains as Valid OAut

2017-05-19 Thread Ismail Sarenkapic
I'm trying to allow users to login with facebook via django allauth to my website but I am getting the following error: URL Blocked: This redirect failed because the redirect URI is not whitelisted in the app’s Client OAuth Settings. Make sure Client and Web OAuth Login are on and add all your

Re: Django not showing updated data

2017-05-19 Thread Antonis Christofides
1) You hit Ctrl+R or otherwise refresh the page in the browser, and it still shows the old data? 2) How do you know the new record is in the database? 3) What is your RDBMS? 4) Are you using any cache middleware? Antonis Christofides http://djangodeployment.com On 2017-05-18 16:08, George