Re: Channels - unbalanced load for threaded workers

2017-05-18 Thread Andrew Godwin
Yes. Running with no --threads option will give you the best spread, but result in more RAM usage. Rather than relying on process statistics via htop or similar, I'd suggest benchmarking actual throughput, as that's the thing you want to optimise for at the end of the day; it might be that one way

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-18 Thread djangorobert
On Wednesday, May

Re: Django Channels error : et connection to 'ws://www.openchat.us/chat/stream/' failed: Error during WebSocket handshake: Unexpected response code: 404 connect @ websocketbridge.js:118 (index):174 Di

2017-05-18 Thread djangorobert
here is what i am seeing in the bash command line after entering the command: daphne -p 27411 myproject.asgi:channel_layer

Re: Django Channels error : et connection to 'ws://www.openchat.us/chat/stream/' failed: Error during WebSocket handshake: Unexpected response code: 404 connect @ websocketbridge.js:118 (index):174 Di

2017-05-18 Thread djangorobert
here is the error that i am seeing after i enter the command daphne -p 27411 myproject.asgi:channel_layer

ModelForm not submitting data

2017-05-18 Thread Vipul Ujawane
*#views.py* def check(request): if request.method == 'POST': form = UploadForm(request.POST, request.FILES) form.save() return HttpResponseRedirect("/") else: form = UploadForm() return render(request, 'upload.html', {'form': form}) def

Re: Selenium mess

2017-05-18 Thread XaviP
My experiences with django-selenium-Firefox were really painful. When finally switch to phantomjs, all was better, but from time to time, the tests still freeze in travis-ci. Hope it helps. El dimecres, 17 maig de 2017 16:45:18 UTC+2, Antonis Christofides va escriure: > > Hi, > > I am the

Re: Django not showing updated data

2017-05-18 Thread George Kleanthous
Hi, This is the view def taxes(request): taxes = Tax.objects.all() return render (request, ‘app/taxes.html', {"data":taxes}) > On 18 May 2017, at 3:19 PM, Antonis Christofides > wrote: > > Hi, > > it's hard to tell without more

TypeError: expected string or bytes-like object

2017-05-18 Thread vitalysweb
Hello, i have problem in migration, in my* "model.py"* file i added a new table and new fields (into the exisiting table) and thats what i got when i do *""..manage.py migrate..."" :* Operations to perform: Apply all migrations: utilisateur Running migrations: Applying

Django Channels error : et connection to 'ws://www.openchat.us/chat/stream/' failed: Error during WebSocket handshake: Unexpected response code: 404 connect @ websocketbridge.js:118 (index):174 Discon

2017-05-18 Thread djangorobert
not quite sure what im doing wrong with the django channels multichat example but seem to be getting this error: connection to 'ws://www.openchat.us/chat/stream/' failed: Error during WebSocket handshake: Unexpected response code: 404 connect @ websocketbridge.js:118 (index):174 Disconnected

Re: vs {{ form }}

2017-05-18 Thread guettli
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 you use? With or without table? > >{{ form }} vs {{ form }} > > > Both of these are

Re: Signal limitations with custom models!

2017-05-18 Thread Uzair Tariq
Thanks man! Actually i was thinking the same thing as mentioned in the question because that's the only valid logical reason i can come up with after viewing the ticket. Anyways *Thanks again* On Thursday, May 18, 2017 at 2:53:57 AM UTC+5, James Schneider wrote: > > > > On May 17, 2017 7:59 AM,

Re: Database Routing

2017-05-18 Thread Derek
You'll need to post actual code and error stack traces if you want people to help. On Wednesday, 17 May 2017 15:08:55 UTC+2, Joe wrote: > > I am in the process of setting up a django server. I am trying to connect > our 4 legacy DBs to her. I have created a separate app for each DB, added >

Re: Django not showing updated data

2017-05-18 Thread m712 - Developer
You most likely have a variable as a rest of query that's defined at module level. Something like: records = models.Record.objects.all() def my_view(request):     ... You need to put your variables inside views if you want them fresh every view. Otherwise Django will fetch it when you start

Re: Django not showing updated data

2017-05-18 Thread Antonis Christofides
Hi, it's hard to tell without more information. It could be a caching issue, if you are using a cache. If possible, please show us the code of the view that is causing the error (if it's not too long). Regards, A. Antonis Christofides http://djangodeployment.com On 2017-05-18 11:41,

Re: accessing foreign key value in views.py

2017-05-18 Thread Antonis Christofides
Hi, We need more information. We need to know which field causes the problem. Maybe the full error message with full traceback could help. Regards, A. Antonis Christofides http://djangodeployment.com On 2017-05-18 12:53, Amisha Hans wrote: > Hey , > > I am facing a lot of issues regarding

Re: Setting the Date Format in the input fields

2017-05-18 Thread akashmalviya632
well , i am not sure about this ..but you can use javascrpit by creating a -{ new Date() }- bject in it..hope it will work > > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails

Re: Need help in Django User Model customization and authentication

2017-05-18 Thread Ajat Prabha
Thanks for the reply, Scot, I've some questions here: 1. Is setting up groups necessary if I'm creating shared UserProfile? If not, will groups be anyhow beneficial to this new setup? 2. Shall I create shared UserProfile from User? If yes, how can I handle the need for two

Re: Need help in Django User Model customization and authentication

2017-05-18 Thread Ajat Prabha
Thanks for your reply, actually I need two passwords, one being normal alphanumeric and other being PIN-based with proper validation and features provided by Django auth core. Is it possible to do that with just extending User model? On Saturday, 13 May 2017 23:59:14 UTC+5:30, Constantine

Re: How to fix "plural forms expression could be dangerous"

2017-05-18 Thread 'Tom Evans' via Django users
You need to change INTEGER and EXPRESSION for the correct values. I believe for zh you want "nplurals=1; plural=0;" Cheers Tom On Thu, May 18, 2017 at 7:41 AM, Martin Brochhaus wrote: > Hi everyone, > > in my project, I am generating my .po files like this: > >

Django not showing updated data

2017-05-18 Thread gkleanthous.mob
Hi I have a page which shows a list of records from a model. I have an “add new” link which opens a form. User fill the form and clicks save. Then an ajax call is done and the new record is saved to the database. When i visit back the page with the list i do not see the new record, although

How to fix "plural forms expression could be dangerous"

2017-05-18 Thread Martin Brochhaus
Hi everyone, in my project, I am generating my .po files like this: python manage.py makemessages --ignore=node_modules/* --ignore=*migrations/* --ignore=*tests/* --ignore=__init__.py --ignore=submodules/* --ignore=fabfile* -l zh_CN Usually this results in the following line being added to my

Selecting overlapping elements from ArrayField of DateTimeRangeField

2017-05-18 Thread user0008
Hello all! I'm trying to flter query that returns rows from the table along with only elements from the ArrayField that overlap a specified DateTimeTZRange. Example: import datetime from psycopg2.extras import DateTimeTZRange from django.db import models from django.contrib.postgres.fields

Page not showing new model data

2017-05-18 Thread gkleanthous.mob
Hi I have a page which shows a list of records from a model. I have an “add new” link which opens a form. User fill the form and clicks save. Then an ajax call is done and the new record is saved to the database. When i visit back the page with the list i do not see the new record, although

two question: one for a little similarity page use base template, one for mutiple type user.

2017-05-18 Thread Man Single
Two question: First: There are multiple type user, for example: NormalUser, StaffUser, EnterpriseUser, the model like this: class User(AbstractBaseUser): # some auth related field here class NormalUser(User): # extend , not abstract class StaffUser(User): class

accessing foreign key value in views.py

2017-05-18 Thread Amisha Hans
Hey , I am facing a lot of issues regarding this foreign key !. Scenario is a s follows :- models.py class ComponentDeprecation(models.Model): row_id = models.IntegerField(primary_key=True) component = models.ForeignKey('SsComponents', db_column='component') submitter =

Setting the Date Format in the input fields

2017-05-18 Thread Amisha Hans
The default format is : -MM-DD HH:MM:SS i want it as /MM/DD HH:MM:SS for all the inputs ... outputing in the same format was easy : using date and time filters please help me out -- You received this message because you are subscribed to the Google Groups "Django users" group.

Not able to see the dropdown field for Foreignkey ModelForm.

2017-05-18 Thread Vipul Ujawane
This is my code: *#models.py* class Subject(models.Model): departement_code=models.CharField(max_length=2,blank=False)

Re: Channels - unbalanced load for threaded workers

2017-05-18 Thread biwanczuk
Yes, that was my concern that only some processes are loaded. So running more 'runworker' commands with less '--threads' should give better results? W dniu czwartek, 18 maja 2017 02:18:56 UTC+2 użytkownik Andrew Godwin napisał: > > Hi - I am not sure what you are saying exactly. That the load