Re: Silly Newforms Best Practices Question

2007-05-26 Thread Kenneth Gonsalves
On 27-May-07, at 9:18 AM, SmileyChris wrote: > That's why, like Russ, I also use a forms.py file and do the newforms > import like: > from django.newforms import * i import django.newforms as nforms - so i can use both new and old -- regards kg http://lawgon.livejournal.com

Re: newforms and recaptcha => MultiWidget/MultiField?

2007-05-26 Thread SmileyChris
On May 26, 1:04 am, Bram - Smartelectronix <[EMAIL PROTECTED]> wrote: > hello everyone, > > I'm trying to recreate reCaptcha (http://recaptcha.net/learnmore.html) > in newforms. I did this yesterday: http://smileychris.tactful.co.nz/ramblings/recaptcha/

Re: Silly Newforms Best Practices Question

2007-05-26 Thread SmileyChris
On May 26, 2:53 pm, oggie rob <[EMAIL PROTECTED]> wrote: > Probably not an issue, but if you import as: > from django import newforms as forms > you may want to watch out for namespace issues. That's why, like Russ, I also use a forms.py file and do the newforms import like: from django.newforms

Re: Feisty-updates now contains Python-2.5.1final

2007-05-26 Thread Mike Axiak
Yes, I'm sorry...let me be more clear: Feisty Fawn currently ships with Python 2.5.1c1. Python tried to change its API for dictionaries (which even broke pickle [1]) -- a change with which Django is not compatible [2]. They decided to pull out this change for 2.5.1-final, and as of yesterday

Re: OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 19:36 -0700, David wrote: > My apologies. I am using 0.96, not an SVN checkout of recent vintage. > I'll check out the two tickets mentioned (starting with 3324), and > search tickets first from now on. You don't have to apologise for asking questions. I was hoping to

Re: Feisty-updates now contains Python-2.5.1final

2007-05-26 Thread Jeremy Dunck
On 5/26/07, Forest Bond <[EMAIL PROTECTED]> wrote: > Funny enough, you should note that Feisty _ships_ with Python 2.5 > pre-installed. Feisty shipped with a 2.5.1 release candidate which had regressions that affected Django. A package based on 2.5.1 final was just released this week.

Re: Feisty-updates now contains Python-2.5.1final

2007-05-26 Thread Forest Bond
On Sun, May 27, 2007 at 12:36:04AM -, Mike Axiak wrote: > Ubuntu Feisty Fawn now has Python 2.5 [1] (thanks, Matthias Klose!). > For any apt-compatible system, the following should/might work: Funny enough, you should note that Feisty _ships_ with Python 2.5 pre-installed. No further action

Re: OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 18:02 -0700, David wrote: > I haven't got a lot to go on, output-wise; here's what I ran: > > [EMAIL PROTECTED] intl]$ python manage.py dumpdata fuel > > fuel.tmp > Unable to serialize database: Decimal("0.00") is not JSON serializable To repeat Russell's question: which

Re: OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread David
I haven't got a lot to go on, output-wise; here's what I ran: [EMAIL PROTECTED] intl]$ python manage.py dumpdata fuel > fuel.tmp Unable to serialize database: Decimal("0.00") is not JSON serializable And trying a different format, a different error: [EMAIL PROTECTED] intl]$ python manage.py

Re: Problem with string slicing in templates on non-ascii characters

2007-05-26 Thread Malcolm Tredinnick
On Sun, 2007-05-27 at 10:36 +1000, Malcolm Tredinnick wrote: > On Sat, 2007-05-26 at 15:25 -0700, Almad wrote: > > Hello, > > > > when displaying list of my arcitles, I'm displaying first char of my > > article as heading with {{ page.name.0 }} > > > > However, for non-ascii characters, this

Re: Problem with string slicing in templates on non-ascii characters

2007-05-26 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 15:25 -0700, Almad wrote: > Hello, > > when displaying list of my arcitles, I'm displaying first char of my > article as heading with {{ page.name.0 }} > > However, for non-ascii characters, this char is crippled - see > http://rpgpedia.cz/nastroje/wiki/seznam-clanku/

Feisty-updates now contains Python-2.5.1final

2007-05-26 Thread Mike Axiak
Hello, This seems to warrant an announcement (just given the volume of IRC problems in the recent past)... Ubuntu Feisty Fawn now has Python 2.5 [1] (thanks, Matthias Klose!). For any apt-compatible system, the following should/might work: Add to your apt/sources.list (if it's not in there

Re: OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread Russell Keith-Magee
On 5/27/07, Hancock, David (DHANCOCK) <[EMAIL PROTECTED]> wrote: > > I'd love it to be as simple as a dump-and-restore, but so far, no silver > bullet has emerged. Things I've tried: ... > manage.py dumpdata # chokes on Decimal(0.00) datatype, not sure how to > load output anyway If this

Re: installing django on vista?

2007-05-26 Thread blabla
hnmm i checked both names are all undercase, made sure everything is is correct case still no change On May 26, 7:15 pm, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote: > On 5/26/07, blabla <[EMAIL PROTECTED]> wrote: > > > > > i went and changed the django.pth file to the folder containing mysite > >

Re: installing django on vista?

2007-05-26 Thread Jeremy Dunck
On 5/26/07, blabla <[EMAIL PROTECTED]> wrote: > > > i went and changed the django.pth file to the folder containing mysite > and also tried mysite itself, > basically, tried both of these in django.pth > c:\bla, and then tried c:\bla\mysite I think it's case-sensitive. (Sorry, my Windows VM is

Re: installing django on vista?

2007-05-26 Thread blabla
i went and changed the django.pth file to the folder containing mysite and also tried mysite itself, basically, tried both of these in django.pth c:\bla, and then tried c:\bla\mysite both return the same error still On May 26, 7:03 pm, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote: > On 5/26/07,

Re: installing django on vista?

2007-05-26 Thread Jeremy Dunck
On 5/26/07, blabla <[EMAIL PROTECTED]> wrote: > ImportError: No module named MYSITE > You need to make sure that the directory containing MYSITE is on the python path. There are various ways to do this, but editing django.pth is probably easiest.

Re: Problem with string slicing in templates on non-ascii characters

2007-05-26 Thread Jeremy Dunck
On 5/26/07, Almad <[EMAIL PROTECTED]> wrote: > However, for non-ascii characters, this char is crippled - see > http://rpgpedia.cz/nastroje/wiki/seznam-clanku/ (bottom of the page). You should probably use the unicode branch; Malcolm has called for testing, and your use case is an example of

Re: installing django on vista?

2007-05-26 Thread blabla
ok i had django installed and was following the first tutorial, i ran the django-admin.py successfully, and created the mysite directory with the 4 files, when i open up the command prompt in mysite folder and enter manage.py runserver i get the following error: i searched the forums with the

Problem with string slicing in templates on non-ascii characters

2007-05-26 Thread Almad
Hello, when displaying list of my arcitles, I'm displaying first char of my article as heading with {{ page.name.0 }} However, for non-ascii characters, this char is crippled - see http://rpgpedia.cz/nastroje/wiki/seznam-clanku/ (bottom of the page). Where should the problem be? Should this be

Re: OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread Jason McVetta
Check out Kettle (aka Pentaho Data Integration) from http://kettle.pentaho.org. It's a heavy-weight tool, but it has a fairly intuitive GUI and decent documentation. It's Open, of course, and very multi-platform (I personally use it on Windoze, Solaris, and occasionally Linux). The function you

OT: Resources for converting MySQL data to PostgreSQL for Django

2007-05-26 Thread Hancock, David (DHANCOCK)
We are strongly considering migrating from MySQL to PostgreSQL, but there seem to be enough differences between the two that I'm pulling my hair out. I know this is somewhat off-topic, but has anybody got some resources for the conversion process? I'd love it to be as simple as a

Re: installing django on vista?

2007-05-26 Thread Jeremy Dunck
On 5/26/07, Justin Bronn <[EMAIL PROTECTED]> wrote: ... > With respect to sqlite, I've had problems as well with the built-in > version on Python 2.5. I use the package from initd: > http://initd.org/pub/software/pysqlite/releases/2.3/2.3.3/pysqlite-2.3.3.win32-py2.5.exe Ouch. Wrong on all

Re: installing django on vista?

2007-05-26 Thread Justin Bronn
>1) put c:\python25\bin on your path. Python on Windows actually installs the executables in "C:\Python25" -- that should be in your path instead. > 3) Add a django.pth file to c:\python25\site-packages. In that file, > include the following line: > c:\django\ Likewise, the site-packages

Re: installing django on vista?

2007-05-26 Thread Jeremy Dunck
On 5/26/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > I had the same problem with vista. Basically, you need to update the > environment variables to where you have python installed. I can only speak > to the python being unrecognized. For some reason, it took me a while to get > it

Re: installing django on vista?

2007-05-26 Thread blabla
hey i just found the other post http://groups.google.com/group/django-users/browse_thread/thread/79e8716f934a3b49/c09db74b000a9052?lnk=gst=installing+django+windows=2#c09db74b000a9052 which showed the flaw in your guys setup.py file with the '//' i opened up the setup.py and made the changes he

Re: installing django on vista?

2007-05-26 Thread jeffhg58
I had the same problem with vista. Basically, you need to update the environment variables to where you have python installed. I can only speak to the python being unrecognized. For some reason, it took me a while to get it working correctly. But, in the interim you should be able to use the

Re: Frustration on TEMPLATE_DIRS

2007-05-26 Thread Jeremy Dunck
On 5/26/07, itsnotvalid <[EMAIL PROTECTED]> wrote: > I can't imagine if there is a need to fix > that path on every machine if a given project (like a blog engine) be > distributed to different server located in different path. I'd change the settings file in that case. :)

Re: Frustration on TEMPLATE_DIRS

2007-05-26 Thread itsnotvalid
Actually in the meantime i figured out that using os.path.abspath('templates') would do the job, elegant as it should be. And it is platform independent. For the P.S. bit, I got the idea from djangoproject.com's SVN where they have templates and the rest put together in the same branch. I

Re: Cross-refering models across files

2007-05-26 Thread Tomas Kopecek
Tomas Kopecek napsal(a): > Tim Chase napsal(a): > I> does anybody knows, how to implement cross-refering models across files? >> # in example_app/models_a.py >> class A(models.Model): >> # no ref_to_b here >> ... >> >> # in example_app/models_b.py >> import a >> class

Re: Frustration on TEMPLATE_DIRS

2007-05-26 Thread Jeremy Dunck
On 5/26/07, itsnotvalid <[EMAIL PROTECTED]> wrote: ... > As usual, it doesn't work, and in the comments section somebody > suggested using os.path.dirname(__file__) instead. Hmm. If you have other complaints about docs, please point out places that need improvement. > However I am using >

SEO Pakistan!

2007-05-26 Thread koom2019
Get Guaranteed TOP-10 Ranking in GOOGLE now 1st-Time in PAKISTAN! For Order Now Pls Call/SMS at 0333-2303103 0345-3034510 For Order by E-mail pls Contact us at [EMAIL PROTECTED] TOP-10 Ranking Proved! SEO Pakistan: In Google TOP 10: SEO Specialist Pakistan:

Re: Cross-refering models across files

2007-05-26 Thread Tomas Kopecek
Tim Chase napsal(a): I> does anybody knows, how to implement cross-refering models across files? > # in example_app/models_a.py > class A(models.Model): > # no ref_to_b here > ... > > # in example_app/models_b.py > import a > class B(models.Model): > ref_to_a =

Re: Cross-refering models across files

2007-05-26 Thread Tim Chase
> does anybody knows, how to implement cross-refering models across files? > > Simple example: > file 'models/a.py' > class A(models.Model): > ref_to_b = models.ForeignKey('B') > ... > class Meta: > app_label = 'example_app' > > file 'models.b.py; > class

Frustration on TEMPLATE_DIRS

2007-05-26 Thread itsnotvalid
I am a new user of Django (as well as Python) that finding the tricks on TEMPLATE_DIRS very frustrating. Here is the method of using relative path as written in Django Book: import os.path TEMPLATE_DIRS = ( os.path.join(os.path.basename(__file__), 'templates'), ) As usual, it doesn't

Re: Free blog application

2007-05-26 Thread Jeremy Dunck
On 5/26/07, Jonas Melian <[EMAIL PROTECTED]> wrote: > > Is there any FLOSS blog system using Django? I haven't used any of these, but check 'em out: http://code.google.com/p/jellyroll/ http://code.google.com/p/djog/ http://code.google.com/p/sneeu/ http://code.google.com/p/geeksite/

Cross-refering models across files

2007-05-26 Thread Tomas Kopecek
Hello, does anybody knows, how to implement cross-refering models across files? Simple example: file 'models/a.py' class A(models.Model): ref_to_b = models.ForeignKey('B') ... class Meta: app_label = 'example_app' file 'models.b.py; class B(models.Model): ref_to_a =

DOWNLOAD Natt Chanapa sex video- Thailand Super Model Actress

2007-05-26 Thread sexy
Most people know the story of Natt Chanapa aka Nong Natt aka Nett Kesarin. She is the Thai hottie who was involved in a scandal for her appearance in an adult movie. She is a very sexy lady, pretty and very curvy, and had done some pictures for various Thai men's magazines in the past. But it was

Re: installing django on vista?

2007-05-26 Thread blabla
Hi thanks for the responses, I followed your steps, and am having some problems still, python still is unrecognized command, withy my directory in the command prompt at C:\django>i enter the command setup.py install and recieve error package init file '\django\__init__.py' not found ( or not a

Re: Shared Hosting

2007-05-26 Thread Tim Chase
> I think I know but must ask, do you need django installed on the web > server to run django built web sites? I guess this is a yes Yes. However, "installed" is a multi-faceted term. To make django accessible, all you have to do is unpack (or svn check-out) the contents of the django version

Re: Shared Hosting

2007-05-26 Thread Horst Gutmann
XTCHost wrote: > I think I know but must ask, do you need django installed on the web > server to run django built web sites? I guess this is a yes > > If so > > I have a shared hosting plan and do not have SU rights so can you > please advise the best way to install django > > Many thanks >

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Sam Morris
On Sat, 26 May 2007 19:28:03 +1000, Malcolm Tredinnick wrote: > On Sat, 2007-05-26 at 02:20 -0700, Grant D. Watson wrote: >> Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: >> >> > > In an unusually (for Ubuntu) boneheaded move, it >> > looks >> > > like Ubuntu doesn't leave core files for

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Eugene Morozov
Hello, Here it is: https://bugs.launchpad.net/bugs/108067 I've planned to make a public repository with fixed packages, but I'm too busy for this. Anyway, you can take Feisty package, replace source code with downloaded 2.0.6 source code from psycopg site, bump version number in debian

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 12:42 +, Eugene Morozov wrote: > python-psycopg2 package in Ubuntu Feisty for x86-64 is completely > broken. I've reported it in the Launchpad on the next day after > release, but maintainer is still reluctant to apply patch which should > fix 64 bit issues. Ha ha!

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Eugene Morozov
python-psycopg2 package in Ubuntu Feisty for x86-64 is completely broken. I've reported it in the Launchpad on the next day after release, but maintainer is still reluctant to apply patch which should fix 64 bit issues. I've solved the problem by downloading upstream beta version and compiling a

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Grant D. Watson
Of course I omitted the part that might be marginally more useful: (gdb) bt #0 0x00418f22 in ?? () #1 0x00419a10 in PyObject_CallMethod () #2 0x2b062bf4c7e3 in microprotocol_getquoted () from /usr/lib/python2.5/site-packages/psycopg2/_psycopg.so #3 0x2b062bf4e29b

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Grant D. Watson
--- Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > I think you're a little bit doomed here, if Ubuntu > ships stripped > binaries. On a Fedora system I would install the > *-debuginfo at this > point. Then you could try > > gdb python > ... > (gdb) run manage.py syncdb >

Re: installing django on vista?

2007-05-26 Thread Ben Jones
> Since you're just getting started, set DATABASE_ENGINE to sqlite; > you'll have a bit of trouble getting psycopg or mysqldb installed, so > you should have some fun first. ;-) Be careful with the sqlite that's bundled with Python though . . . On my Win32 python install (Python 2.5.1

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 02:20 -0700, Grant D. Watson wrote: > Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > > > In an unusually (for Ubuntu) boneheaded move, it > > looks > > > like Ubuntu doesn't leave core files for packaged > > > programs, even after a "ulimit -c unlimited". Any > > >

Re: Django, Postgres and Core Dumps

2007-05-26 Thread Grant D. Watson
Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > In an unusually (for Ubuntu) boneheaded move, it > looks > > like Ubuntu doesn't leave core files for packaged > > programs, even after a "ulimit -c unlimited". Any > > other way to pull this off? > > I wouldn't have thought it was possible to

Re: Broken pipes with HttpResponseRedirect and Firefox / Trouble in paradise

2007-05-26 Thread Steve Freitas
On Fri, 2007-05-18 at 14:27 -0700, Jon Lesser wrote: > I tool Malcolm's advice and looked closely at the packets going back > and forth. Upon pressing an input button nested within an anchor, > Firefox was sending two identical requests to the server, thus causing > my code to be executed twice.

Re: Unicode-branch: testers wanted

2007-05-26 Thread Malcolm Tredinnick
On Fri, 2007-05-25 at 17:17 +0200, Michael Radziej wrote: > Hi Malcolm, > > A short disclaimer: I'm currently trying the unicode branch with the > autoescape patch and a > couple of other patches, so my problems might really be my own problems, > but I don't expect it. > > > First, I found

Re: newforms and recaptcha => MultiWidget/MultiField?

2007-05-26 Thread Russell Keith-Magee
On 5/25/07, Bram - Smartelectronix <[EMAIL PROTECTED]> wrote: > > I know I could use the templating and put all of this in a template or > possibly a template tag, but wouldn't it be superb if I could do: Sure. It doesn't need to be in a templatetag, though - just override the format_output