Re: Trouble with VirtualEnv on Windows

2012-10-15 Thread Jani Tiainen
Hi, Don't forget "yolk". Very powerful tool to display virtualenv contents in readable format. You can install it with pip install yolk. 15.10.2012 9:00, Frank Bieniek kirjoitti: Hi, do a "pip freeze" after you have activated your environment, this way you see the packages that are visible t

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Zheng Li
Isn't it because MyISAM does not support transaction? BTW I am using django 1.3.1, mysql 5.5, innodb mysql> SELECT @@GLOBAL.tx_isolation, @@tx_isolation; +---+-+ | @@GLOBAL.tx_isolation | @@tx_isolation | +---+-+ | REPEATABLE

Help getting my GeoDjango setup.

2012-10-15 Thread JJ Zolper
Hello everyone, So I've installed GDAL, PostGIS, PROJ.4, and GEOS. I have Postgres set up too. What I need help on is the logistics of getting the GeoDjango portion of my website up and running. I already have my website code I'm just trying to add in GeoDjango so I can handle geographic opera

Re: Overriding admin save event

2012-10-15 Thread Lachlan Musicman
On Tuesday, October 16, 2012, Lachlan Musicman wrote: > Hola, > > I wanted to override the save event in the admin so that users were > redirected to a different page. > > I found this page describing how to do it: > > http://www.ibm.com/developerworks/opensource/library/os-django-admin/index.html

Re: Overriding admin save event

2012-10-15 Thread Lachlan Musicman
On Tue, Oct 16, 2012 at 1:44 PM, Lachlan Musicman wrote: >> Hola, >> >> I wanted to override the save event in the admin so that users were >> redirected to a different page. > > Of course, further reading has turned up signals. Is this the current > recommended method? > > eg: > > from django.db.

Re: Overriding admin save event

2012-10-15 Thread Lachlan Musicman
On Tue, Oct 16, 2012 at 12:52 PM, Lachlan Musicman wrote: > Hola, > > I wanted to override the save event in the admin so that users were > redirected to a different page. Of course, further reading has turned up signals. Is this the current recommended method? eg: from django.db.models.signals

Overriding admin save event

2012-10-15 Thread Lachlan Musicman
Hola, I wanted to override the save event in the admin so that users were redirected to a different page. I found this page describing how to do it: http://www.ibm.com/developerworks/opensource/library/os-django-admin/index.html#listing10 It recommends two methods and describes one: "There are

Craziest conference idea ever - announcing next DjangoCon Europe

2012-10-15 Thread Ola Sitarska
Hi guys & girls! Just wanted to let you know that we launched DjangoCon Europe 2013 website. This time we've decided to put some more magic and came up with this crazy idea of throwing a fun Django conference in a real CIRCUS tent, so make sure to check it out: http://2013.djangocon.eu/ We're

Craziest conferenece idea ever - announcing next DjangoCon EU

2012-10-15 Thread Ola Sitarska
Hi guys! Just wanted to let you know that we launched DjangoCon Europe 2013 website. This time we've decided to put some more magic and came up with this crazy idea of throwing a fun Django conference in a real CIRCUS tent, so make sure to check it out: http://2013.djangocon.eu/ We're gonna s

csrf cookie and varnish

2012-10-15 Thread Àlex Pérez
Today I had a problem with CSRF protection of Djando and varnish, the varnish basically detects that a cookie (the CSRF) and does not perform its task (cache requests). The solutions found on google have not convinced me. And I tried an idea, delete all cookies when I'm not on a website that requi

django-pci-auth

2012-10-15 Thread Alex Clark
Hello Djangonauts! I'm about to develop a Django app for PCI auth compliance for a client. It's open source under the same BSD license that Django users. I'm interested in any and all feedback as I develop this application over the course of the next two months. You can track the project and

Re: User can't edit anything

2012-10-15 Thread Nikolas Stevenson-Molnar
Being 'staff' only means that the user can access the admin area, not that they can do anything there. Double check that they have permissions (or are a member of a group which has permissions) to edit each content type you want them to be able to edit. _Nik On 10/12/2012 2:02 PM, Shawn H wrote:

bug in use of mark_safe and i18n _ ?

2012-10-15 Thread Federico Marani
Hi, I am using a form which defines this field: terms = forms.BooleanField( error_messages={'required': _('You must accept the terms and conditions')}, label="", help_text=_(mark_safe("I understand and accept the terms of use and privacy policy of this site.")) ) unf

Re: User can't edit model even after permissions are issued

2012-10-15 Thread Shawn H
Yes. I can connect as the super user and edit, add and delete. On Sunday, October 14, 2012 9:48:32 AM UTC-5, Karen Tracey wrote: > > On Fri, Oct 12, 2012 at 4:52 PM, Shawn H > > wrote: > >> I'm new to Django, and I'm using the admin site to manage my users. I >> have one app installed, and it

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Tom Evans
On Mon, Oct 15, 2012 at 3:28 PM, Karen Tracey wrote: > On Mon, Oct 15, 2012 at 9:43 AM, Tom Evans wrote: >> >> On Mon, Oct 15, 2012 at 1:50 PM, Zheng Li wrote: >> > get_or_create shouldn't give duplicate entry error >> > anyone help. >> > >> >> This is incorrect, and a common misconception: get_

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Karen Tracey
On Mon, Oct 15, 2012 at 9:43 AM, Tom Evans wrote: > On Mon, Oct 15, 2012 at 1:50 PM, Zheng Li wrote: > > get_or_create shouldn't give duplicate entry error > > anyone help. > > > > This is incorrect, and a common misconception: get_or_create() is not > atomic. If this happens, you will get dupli

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Tom Evans
On Mon, Oct 15, 2012 at 1:50 PM, Zheng Li wrote: > get_or_create shouldn't give duplicate entry error > anyone help. > This is incorrect, and a common misconception: get_or_create() is not atomic. If this happens, you will get duplicate key errors: Thread A calls get_or_create(a='a', b='b') Thre

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Reinout van Rees
On 15-10-12 14:50, Zheng Li wrote: get_or_create shouldn't give duplicate entry error Perhaps you have existing data that violates your unique-together constraint? Data that existed before that constraint was in place? Check it directly in your database by searching for that a=a, b=b entry.

Re: get_or_create gave IntegrityError: (1062, "Duplicate entry) error sometimes

2012-10-15 Thread Zheng Li
get_or_create shouldn't give duplicate entry error anyone help. On 2012/10/13, at 11:06, Wei Wei wrote: > I am new to Django. But does the error message literally mean you have > duplicated records against your unique_together constriction? > > On Sat, Oct 13, 2012 at 9:47 AM, Zheng Li wrote:

Re: Adding a new row to the database in user form

2012-10-15 Thread Nicolas Emiliani
On Mon, Oct 15, 2012 at 3:16 AM, Satinderpal Singh < satinder.goray...@gmail.com> wrote: > Hello, > I want to add a new row in the existing database table by using add > button in the html form from the user as user can create as much rows > in the table as he needed, how will i add this? > Thanks

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Jason Sibre
Hi, Just a hunch, but it kinda smells like your web server isn't executing the CGI script. I'd suggest checking into what is necessary to get your server to execute CGI, vs serving it up as text. On Oct 15, 2012, at 5:40 AM, Pervez Mulla wrote: > Instead of CGI server path , I places perl scr

Re: Trouble with VirtualEnv on Windows

2012-10-15 Thread Frank Bieniek
Hi, do a "pip freeze" after you have activated your environment, this way you see the packages that are visible to the python interpreter inside your virtual env. Possible Problem You have installed all packaged before you created the virtual env. -> virtual env shows no components. pip instal

Re: Trouble with VirtualEnv on Windows

2012-10-15 Thread Joshua Russo
Sweet! Thank you! On Monday, October 15, 2012 12:56:37 AM UTC-4, Jani Tiainen wrote: > > Because the setup procedure used there is faulty. > > This is what happens: > > When installing Python install package will bind .PY(C) file execution > to use _always_ main installation. It won't follow an

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Pervez Mulla
Instead of CGI server path , I places perl script in static folder and given path for that . On Mon, Oct 15, 2012 at 4:09 PM, Pervez Mulla wrote: > responseText: #!/usr/bin/perl -T use CGI; use DBI; use strict; use > warnings; use netsharkusr; my $cgi = CGI->new; my $username = > $cgi->param("us

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Pervez Mulla
responseText: #!/usr/bin/perl -T use CGI; use DBI; use strict; use warnings; use netsharkusr; my $cgi = CGI->new; my $username = $cgi->param("username"); my $password = $cgi->param("password"); my $tempuser = new netsharkusr(); if($tempuser->readbyusername($username) eq 1) { if($tempuser->{username

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Sergiy Khohlov
please provide error 2012/10/15 Pervez Mulla : > On error note its printing all pelr script itself. > > > On Mon, Oct 15, 2012 at 3:31 PM, Sergiy Khohlov wrote: >> >> please provide error message >> >> 2012/10/15 Pervez Mulla : >> > Thank You for your response Sergiy , >> > >> > I already try'd t

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Pervez Mulla
On error note its printing all pelr script itself. On Mon, Oct 15, 2012 at 3:31 PM, Sergiy Khohlov wrote: > please provide error message > > 2012/10/15 Pervez Mulla : > > Thank You for your response Sergiy , > > > > I already try'd to run this script as shown in Django DOC as u given .but > > s

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Sergiy Khohlov
please provide error message 2012/10/15 Pervez Mulla : > Thank You for your response Sergiy , > > I already try'd to run this script as shown in Django DOC as u given .but > still it didnt work:( > > Thank You > Pervez > > On Mon, Oct 15, 2012 at 1:28 PM, Sergiy Khohlov wrote: >> >> https://d

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Pervez Mulla
Thank You for your response Sergiy , I already try'd to run this script as shown in Django DOC as u given .but still it didnt work:( Thank You Pervez On Mon, Oct 15, 2012 at 1:28 PM, Sergiy Khohlov wrote: > https://docs.djangoproject.com/en/dev/ref/settings/#std:setting-LOGIN_URL > > set

Re: How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Sergiy Khohlov
https://docs.djangoproject.com/en/dev/ref/settings/#std:setting-LOGIN_URL set this one in setting.py 2012/10/15 Pervez Mulla : > Hi, > > I have login.html , login,js ang login.pl. > > I want to integrate basic login page in Django with perl back-end from where > Am reading my DB. > I was trying

How can I integrate simple Custom login page in Django.......?

2012-10-15 Thread Pervez Mulla
Hi, I have login.html , login,js ang login.pl. I want to integrate basic login page in Django with perl back-end from where Am reading my DB. I was trying to integrate it from last day but come out with empty .There might be some settings in setting.py. Below is my code -- login.ht