Re: https / nginx / uwsgi / django problems with authentification

2011-07-20 Thread Roberto De Ioris
> Hi, > > I'm not sure whether I have to change my django configuration or my > nginx cofiguration. > (Thus posted to gmane.comp.python.django.user and to > gmane.comp.web.nginx.english) > > I have following setup: > > - nginx listening on https > - most static contents like .css .js images

Is there a way to insert data from a csv file into my database?

2011-07-20 Thread Eiram
Greetings, I'm a newbie in databases, and I was wondering if there is possible to insert data from a csv file into one of the tables of my database. I heard that you can use a tool called pgloader, but I don't know how to use this tool or if it is possible to do this with django. Does anyone

Re: problem with BooleanField form

2011-07-20 Thread ed
I'm using the following javascript, so I can't check the HTML, can I? How would I go about debugging this? function bookmark_save() { var item = $(this).parent(); var data = { url: item.find("#id_url").val(), title: item.find("#id_title").val(),

https / nginx / uwsgi / django problems with authentification

2011-07-20 Thread Gelonida N
Hi, I'm not sure whether I have to change my django configuration or my nginx cofiguration. (Thus posted to gmane.comp.python.django.user and to gmane.comp.web.nginx.english) I have following setup: - nginx listening on https - most static contents like .css .js images served by nginx -

Re: Receiving [Django] ERROR via email even if DEBUG = True

2011-07-20 Thread SmileyChris
It certainly sounds like DEBUG isn't actually True. To test, from a manage.py shell: from django.conf import settings assert settings.DEBUG No error there? -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web

Re: How to disable specific field validaton in form?

2011-07-20 Thread SmileyChris
Would it be acceptable to just not bind the form at all in the situation where you want to return the more complex form? Something like: YourForm(initial=dict(request.POST.items())) -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this

Re: problem with BooleanField form

2011-07-20 Thread SmileyChris
It should definitely be {'share': True} if you've checked the box and submitted the form. Have you ensured your checkbox inside the form tag you're submitting in HTML? -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion

problem with BooleanField form

2011-07-20 Thread ed
I'm learning Django by following the turorials in Django 1.0 Website Development by Ayman Hourieh. I've been banging my head for a while on this and I know it's probably something really simple that I'm missing. I'm using the following form: class BookmarkSaveForm(forms.Form): share =

Re: 'settings' referenced before assignment

2011-07-20 Thread ydjango
Thank you. That was exactly the issue. I renamed the local variable. On Jul 20, 2:04 pm, Ian Clelland wrote: > On Wed, Jul 20, 2011 at 1:14 PM, ydjango wrote: > > Occasionally I see this error in my app, > > > UnboundLocalError: local variable

Re: 'settings' referenced before assignment

2011-07-20 Thread Ian Clelland
On Wed, Jul 20, 2011 at 1:14 PM, ydjango wrote: > Occasionally I see this error in my app, > > UnboundLocalError: local variable 'settings' referenced before > assignment > > I have in my views .py > > from django.conf import settings > other imports... > > def

Pycrypto----> DLL load failed: The specified module could not be found.

2011-07-20 Thread Lycan
Hello In my views.py i have this line of code "from Crypto.Hash import SHA256", it works fine on localhost.But when i try to launch my live website(using Apache 2.2 and mod_wsgi), I am seeing the following error: ImportError at /accounts/profile/apps DLL load failed: The specified module could

'settings' referenced before assignment

2011-07-20 Thread ydjango
Occasionally I see this error in my app, UnboundLocalError: local variable 'settings' referenced before assignment I have in my views .py from django.conf import settings other imports... def new_view(request): if not request.user.is_authenticated(): return

Re: Improperly Configured Remote User Middleware

2011-07-20 Thread John
I changed my uat instance to point at PostgreSQL instead of SQLite and now it works. I touched nothing relating to this issue, but it looks like it worked itself out. I would imagine there was some caching of something somewhere that was not getting overwritten. Thanks anyway. On Jul 20, 12:35 

Re: get django/lighttpd "hello world" page

2011-07-20 Thread Phil
thanks Javier. On Jul 20, 8:13 pm, Javier Guerra Giraldez wrote: > On Wed, Jul 20, 2011 at 2:02 PM, Phil wrote: > >            "host" => "my ip address", > > sometimes flup (and other fastcgi launchers) bind only to the > 127.0.0.1 IP.  if you want to put

Re: get django/lighttpd "hello world" page

2011-07-20 Thread Javier Guerra Giraldez
On Wed, Jul 20, 2011 at 2:02 PM, Phil wrote: >            "host" => "my ip address", sometimes flup (and other fastcgi launchers) bind only to the 127.0.0.1 IP. if you want to put the webserver and webapp on different machines, be sure to bind to all IPs (typically setting

Re: get django/lighttpd "hello world" page

2011-07-20 Thread Phil
thanks Javier! I switched it to port 8080 now. I have a "lighttpd/lighttpd.conf" with the following... server.document-root = "/var/www" $HTTP["host"] =~ "(^|\.)mydomain\.com$" { fastcgi.server = ( "/var/www/mydomain.fcgi" => ( "main" => ( # Use host / port instead of

Re: get django/lighttpd "hello world" page

2011-07-20 Thread Javier Guerra Giraldez
On Wed, Jul 20, 2011 at 1:42 PM, Phil wrote: > if I can get a standard HTML to display on port 80 with lighttpd does > that still mean I have to use a different port for fcgi? absolutely. the port used between the webserver and webapp must _not_ be the same where the browsers

Re: get django/lighttpd "hello world" page

2011-07-20 Thread Phil
if I can get a standard HTML to display on port 80 with lighttpd does that still mean I have to use a different port for fcgi? On Jul 18, 10:59 pm, Javier Guerra Giraldez wrote: > On Mon, Jul 18, 2011 at 4:55 PM, Phil wrote: > > I did run "./manage.py

Improperly Configured Remote User Middleware

2011-07-20 Thread John
I am trying to get sso working with apache and Django. I have the REMOTE_USER being filled correctly with mod_auth_kerb, and I followed the simple directions listed at https://docs.djangoproject.com/en/dev/howto/auth-remote-user/ in an attempt to enable Django's REMOTE_USER authentication. I am

Running Django on a Shared-Hosting Provider with Apache

2011-07-20 Thread Rick Beacham
Running Django on a Shared-Hosting Provider with Apache When i go to run the mysite.fcgi it prints out itself in the browser..Is there something wrong here? I have followed the steps to the tee.. http://localhost/mysite.fcgi print out this: import sys, os # Add a custom Python path.

Re: Odp: Re: Django admin - utf8 filename

2011-07-20 Thread urukay
Why not to change filename during the upload? Radovan http://www.yau.sk On 19. Júl, 17:24 h., galgal wrote: > OK I managed to do that - I can upload utf8 files now. > But after uploading it i can't see file form field to change file:/ -- You received this message

Re: How to best use gunicorn with multiple virtualenv's

2011-07-20 Thread Shawn Milochik
I just create a different user account for each application I'm running. So each user account has its own virtualenv, gunicorn, etc. Obviously just one nginx instance. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

How to disable specific field validaton in form?

2011-07-20 Thread galgal
I need to disable field validation in ModelForm. I want this validation not to validate some field. I have some situations (AJAX rendering form) when I want to return more complex form with additional fields. I pass POST to the form and render new one with post fields saved. Some new fields are

Re: Pasta root

2011-07-20 Thread Tom Evans
On Wed, Jul 20, 2011 at 1:47 PM, Andre Terra wrote: > Oh, I didn't know that. Has that always been the case or was that feature > added in a recent version? > > Anyway, thanks, Tom! > > > Cheers, > AT > 4 years ago :) https://code.djangoproject.com/changeset/5379 Cheers

Re: creating dynamic forms with django

2011-07-20 Thread ken paul
Hey you know the link actually has what I want thanks Kenneth On Wed, Jul 20, 2011 at 3:27 PM, ken paul wrote: > Thank man but what I mean is like you create a dynamic class > ||new_class=type('myform',(forms.Form),{attrib})|| but the dict with attribs > is a bit complex coz

Re: Pasta root

2011-07-20 Thread Andre Terra
Oh, I didn't know that. Has that always been the case or was that feature added in a recent version? Anyway, thanks, Tom! Cheers, AT On Wed, Jul 20, 2011 at 9:44 AM, Tom Evans wrote: > On Wed, Jul 20, 2011 at 1:01 PM, Andre Terra wrote: > >

Re: Pasta root

2011-07-20 Thread Tom Evans
On Wed, Jul 20, 2011 at 1:01 PM, Andre Terra wrote: > From what I'm seeing, you haven't created your own context processor, > and the default processors do not add MEDIA_URL to the context. > django.core.context_processors.media adds MEDIA_URL to the context, and is in

Re: creating dynamic forms with django

2011-07-20 Thread ken paul
Thank man but what I mean is like you create a dynamic class ||new_class=type('myform',(forms.Form),{attrib})|| but the dict with attribs is a bit complex coz the form attributes have there own attributes and widgets Kenneth On Wed, Jul 20, 2011 at 1:00 PM, NISA BALAKRISHNAN <

Komodo IDE better screenshots (worth reading!)

2011-07-20 Thread Cal Leeming [Simplicity Media Ltd]
For me, looks are extremely important when it comes to an IDE, especially when I spend 12+ hours a day doing nothing but Django/Python development. When looking at Komodo, I *almost* rejected it on the basis that all the available screenshots looks hideous. OSX:

Receiving [Django] ERROR via email even if DEBUG = True

2011-07-20 Thread Federico Capoano
Hi, i'm using django 1.4 alpha from SVN. I get email notification for errors on my local machine which I use to develop. How can I turn these notifications off? DEBUG is True on my settings.py. Thanks -- You received this message because you are subscribed to the Google Groups "Django

Re: DeprecationWarning displayed in test, not in dev

2011-07-20 Thread Andre Terra
Great! Thank you Tom and Russ for the heads up. Cheers, AT On 7/20/11, Tom Evans wrote: > On Wed, Jul 20, 2011 at 3:24 AM, Russell Keith-Magee > wrote: >> The problem here actually lies with Python. >> >> For some reason, Python 2.7 changed

Re: Pasta root

2011-07-20 Thread Andre Terra
>From what I'm seeing, you haven't created your own context processor, and the default processors do not add MEDIA_URL to the context. In other words, MEDIA_URL will always be null unless you explicitly pass it to the template. You could do this on every view, or write a context processor that

Re: DeprecationWarning displayed in test, not in dev

2011-07-20 Thread Tom Evans
On Wed, Jul 20, 2011 at 3:24 AM, Russell Keith-Magee wrote: > The problem here actually lies with Python. > > For some reason, Python 2.7 changed the reporting behavior of Warnings > so that DeprecationWarning is ignored by default [1]. So, because > you're developing in

Re: creating dynamic forms with django

2011-07-20 Thread NISA BALAKRISHNAN
may be dis link helps u: http://uswaretech.com/blog/2008/10/dynamic-forms-with-django/ On Wed, Jul 20, 2011 at 12:46 PM, ken paul wrote: > hey can anyone get a way of writing dynamic form classes with django. I > have tried but putting the attributes became a bit hard. >

Re: Pasta root

2011-07-20 Thread Jussiê Vieira Toledo
ok, sorry I did not see that it was only in English. At first everything is configured ok, and processors of the templates here's the code: TEMPLATE_CONTEXT_PROCESSORS = ( "django.core.context_processors.auth" "django.core.context_processors.request" #

creating dynamic forms with django

2011-07-20 Thread ken paul
hey can anyone get a way of writing dynamic form classes with django. I have tried but putting the attributes became a bit hard. Kenneth -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: NameError at /admin/

2011-07-20 Thread lokesh
Hi, In admin.py yourprojectname is missing. Instead of from news.models import Articles, try from yourprojectname.news.models import Articles. Lokesh S On Jul 18, 7:06 pm, arthur_mwai wrote: > I wanted to register an app called "news" in the admin site and i got > this

Re: How to get parent id in inline html

2011-07-20 Thread Burcu Hamamcıoğlu
I found the solution; change_view view sends a parameter named "object_id" to the html. This was enough helpfull for me. 20 Temmuz 2011 00:03 tarihinde Burcu Hamamcıoğlu yazdı: > Hi all, I've customized edit_inline.html for my inline section. I > need parent model's id/pk

How to best use gunicorn with multiple virtualenv's

2011-07-20 Thread Benedict Verheyen
Hi, I just discovered gunicorn after some problems with wsgi. It seems like a very clean setup together with supervisord. However, it's not clear to me how you set it up when you have multiple virtualenvs. It's easy enough to install gunicorn in a virtualenv and then specify a upstream in