Re: Nesh Thumbnail - Installation problem

2006-11-06 Thread Mark Jarecki
Thanks guys Ended up that the Python Imaging Library was not correctly installed. It all works now! Cheers On 07/11/2006, at 2:15 AM, Nebojsa Djordjevic wrote: * Frankie Robertson wrote, On 06.11.2006 12:59: > On 06/11/06, Gabriel Puliatti <[EMAIL PROTECTED]> wrote: >> On Mon, 2006-11-06

Re: Newbie DB question

2006-11-06 Thread Jay Parlar
On 11/6/06, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > Also, you might want to look at the SQLAlchemy branch - This branch is > reworking the Django ORM to use SQLAlchemy, which might open some > different avenues for accessing views. This branch is still quite new, > but if you're feeling

Creating a table if it doesn't exist

2006-11-06 Thread Oliver Lavery
I've just finished django-izing a big geo-database (I never ever again want to hunt for a list of states or countries), and it was terribly easy. manage.py inspectdb is quite the time-saver.Building the database is non-trivial however, and the SQL for building the schema was some clever

Re: Recording Changes minor problem

2006-11-06 Thread Matt H
On 11/6/06, SmileyChris <[EMAIL PROTECTED]> wrote: > > I'm not certain, but it could be that the status_id of the new object > is returning as a string (because it's most likely come from web > request). Try comparing the str() of each. > > Your __dict__ code is a bit messy - you shouldn't really

Re: Newbie DB question

2006-11-06 Thread Russell Keith-Magee
On 11/7/06, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > On 11/6/06, Martin Bačovský <[EMAIL PROTECTED]> wrote: > > > > I have two questions I was unable to google: > > - Is Django going to support database views? > > We don't have any immediate plans to support views; however, if > someone

Re: Newbie DB question

2006-11-06 Thread Russell Keith-Magee
On 11/6/06, Martin Bačovský <[EMAIL PROTECTED]> wrote: > > I have two questions I was unable to google: > - Is Django going to support database views? We don't have any immediate plans to support views; however, if someone were to provide a patch that implemented the. > - Does Django support

column value sums in Admin Interface

2006-11-06 Thread Picio
Hello, Is there a way to have all the partial sums at the end of a vaues column in the admin interface? Something like the sql sum() function used with group by(...)? I know that the admin interface was not built to be extended but this is the only one thing I miss. I have read many times the

Re: Want to see your favorite branch merged? Here's how you can help!

2006-11-06 Thread Scanner
James Bennett wrote: > Jacob mentioned this a while back, and I've just reiterated it on the > dev list, but I feel like this is important enough to mention here as > well: if there's a particular branch whose features you're clamoring > for, and you're willing to pitch in and help test and

Re: Problems installing

2006-11-06 Thread skipmartin
Anyone have any ideas? Would love to get this install off the ground... -Andy On Nov 5, 1:24 pm, "skipmartin" <[EMAIL PROTECTED]> wrote: > Tearing my hair out here... > > Getting a "400 - Bad Request" > > I've done everything I can find in any tutorial... please help! Trying > to run on Apache

cgi handlers

2006-11-06 Thread Salvatore
Hello, Can someone explain me how to use the cgi's handler found in http://code.djangoproject.com/ticket/2407 Regards Salvatore --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to

Re: is not JSON serializable - again

2006-11-06 Thread timc3
Well I got it to work by what you said. Here is my example for those that might come across this thread: if errors or request.POST.has_key('preview'): response_dict = {} datetime_now = datetime.datetime.now() comment = errors and '' or

Re: Screencast Moved

2006-11-06 Thread Picio
Hey, I see a "1" at the end of the URL, when you think you will release the "2" and so forth? I was really impressed about how usefull was your screencast for me. I saw It 3 times and I'm going to see It again because It's a good tool to make my memory fresh! Thanks. Picio 2006/11/6, sago

Re: Want to see your favorite branch merged? Here's how you can help!

2006-11-06 Thread Jay Parlar
On 11/6/06, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > > On 11/6/06, James Bennett <[EMAIL PROTECTED]> wrote: > > > > There's been quite a bit of discussion on the developers list on the > > various open branches in the Django repository right now, and what > > > Info on the active branches: >

Re: Recording Changes minor problem

2006-11-06 Thread SmileyChris
I'm not certain, but it could be that the status_id of the new object is returning as a string (because it's most likely come from web request). Try comparing the str() of each. Your __dict__ code is a bit messy - you shouldn't really need to use internal methods like this. How about just using

Re: How i change Django Admin Title?

2006-11-06 Thread SmileyChris
It's explained in tutorial 2: http://www.djangoproject.com/documentation/tutorial2/#customize-the-admin-form --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email

Re: (Admin) user logged in in model field

2006-11-06 Thread mrstone
Hi I think you will find your answers here: http://code.djangoproject.com/wiki/CookBookThreadlocalsAndUser regards Sten --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this

Re: Want to see your favorite branch merged? Here's how you can help!

2006-11-06 Thread Jeremy Dunck
On 11/6/06, James Bennett <[EMAIL PROTECTED]> wrote: > > There's been quite a bit of discussion on the developers list on the > various open branches in the Django repository right now, and what Info on the active branches: http://code.djangoproject.com/wiki/ActiveBranches

Want to see your favorite branch merged? Here's how you can help!

2006-11-06 Thread James Bennett
There's been quite a bit of discussion on the developers list on the various open branches in the Django repository right now, and what needs to be done to get them merged into trunk for all to use and enjoy. Right now the biggest stumbling block is a need for people who will test and submit code

Re: is not JSON serializable - again

2006-11-06 Thread Oliver Lavery
Funny, I literally just finished debugging the same error.If you inspect the traceback you should see which dict element wouldn't serialize. Just walk up the traceback stack and inspect the locals. The bottom couple of stack frames will be within the JSON default handler (which generates the ever

Re: is not JSON serializable - again

2006-11-06 Thread timc3
I get a pop-up error saying "internal server error" - which my javascript is handling and displaying. The full error in the page returned is: Exception Type: TypeError Exception Value: t: t... is not JSON serializable Exception Location:

Re: Re: Generic Views

2006-11-06 Thread Guillermo Fernandez Castellanos
Got it!! I tried the code at home, and it did not work for me neither. I then tried object_list instead of archive_index and it worked well. So i tried archive_index again with the allow_future=True option and it worked. My guess: You are not on the America/Seattle time zone, and for the

question on whether to cache my query or not?

2006-11-06 Thread Rob Hudson
I'm trying to reduce a SQL call to a MySQL database and I'm curious if Django tries to do some of what I'm doing or if my method makes sense. I'm making a ratings app to rate ideas (a 1 to 5 star type of thing). In my template I want to list both the number of ratings and also the average

How i change Django Admin Title?

2006-11-06 Thread comechao
How can i change admin Title on header? Couse i want to put my client name... Sorry for my bad bad english... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

Custom SQL/Paginator problems

2006-11-06 Thread soundseeker
Hello, here's a django/python newbie problem, which I could not resolve after spending some time with reading and testing. Assuming a method in my models.py class VMergeDocsInfo(models.Model): .. def by_categories(self): from django.db import connection

Screencast Moved

2006-11-06 Thread sago
I've moved my introductory screencast to another server. Its now at: http://www2.lamptraining.com/screencast/1/ In case you were looking. Ian. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users"

Recording Changes minor problem

2006-11-06 Thread Matt H
Currently, I am overriding the save() method to keep records of all changes made to objects. I've created a simplified example below. I have two questions: 1) Is there an obvious better way? 2) When comparing the 'status_id' fields, they always are unequal even when the status wasn't changed

Re: Re: Generic Views

2006-11-06 Thread Jay Parlar
On 11/6/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > Everything works perfectly except the Generic views. > > It throws a 404 error stating that there are no entrys. But there are > and I can physically see that using select * from the database tables. > If I alter the code and write a

Re: ANN: Django's Trac installation has been upgraded

2006-11-06 Thread Jacob Kaplan-Moss
Hey again -- Duh, I forgot the most important part: if you've entered a valid name and email on the "settings" page (http://code.djangoproject.com/settings), the new spam filter will treat you much nicer. So if you get something legitimate rejected, try entering a name and email. Thanks!

white space middleware bug

2006-11-06 Thread Patrick Lauber
Hi, i fixed a whitespace middleware bug that had some problems with images served: import re class StripWhitespaceMiddleware: """ Strips leading and trailing whitespace from response content. """ def __init__(self): self.whitespace = re.compile('\s*\n') def

ANN: Django's Trac installation has been upgraded

2006-11-06 Thread Jacob Kaplan-Moss
Hi folks -- In an attempt to better deal with the spam problems we've been having, I've upgraded Django's Trac installation to a newer version. More importantly, I've upgraded the spam filter plugin so, with luck, we'll be able to reject more spam and have fewer false-positives. Many, many

Re: Generic Views

2006-11-06 Thread [EMAIL PROTECTED]
Thanks! The models and urls are exactly the same as in the example in this link. http://fallingbullets.com/blog/2006/aug/06/wordpress-clone-27-seconds-part-1-40/ Actually my original models and project is different. But even the example in the above popular tutorial fails on my desktop. I

Re: Creating one call for most recent entry, and another call for the restI have just set up a blog using the helpful tutorial over at

2006-11-06 Thread orestis
Just do {% if forloop.first %} ... {% else %} ... {% endif %} --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To

Re: Django Admin - "Site administration"

2006-11-06 Thread Don Arbow
On Nov 6, 2006, at 12:03 AM, Carl Holm wrote: > Thanks. I should clarify that I am looking for the string "Site > administration" which I did not find in the base_site.html > template. Is should also mention that I am running the dev version. The actual physical location of the string "Site

Re: Accessing request and session objects from templates

2006-11-06 Thread Jorge Gajon
Hi, On 11/3/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > I am wondering if there is a way to access request data and session object > directly from Django templates, in the same way as {{ user }} for instance. > I must admit I'm a bit lost with template context processors and so on... You

Re: Automatically starting the FastCGI server

2006-11-06 Thread orestis
Thanks! I am trying to make lighttpd spawn the fcgi django processes using bin-path but there seems to be a problem. Here is my setup: fastcgi.server = ( "/myproject.fcgi" => ( "main" => ( # Use host / port instead of socket for TCP fastcgi "host" =>

Re: Generic Views

2006-11-06 Thread Guillermo Fernandez Castellanos
Hi, Sorry... I might have written too fast, it does not seem to be your answer... x Please, send the models.py and the urls.py and we'll try to have a look. G On 11/6/06, Guillermo Fernandez Castellanos <[EMAIL PROTECTED]> wrote: > Hi, > > Try adding the option allow_empty=True in your urls: >

Re: Generic Views

2006-11-06 Thread Guillermo Fernandez Castellanos
Hi, Try adding the option allow_empty=True in your urls: http://www.djangoproject.com/documentation/generic_views/#django-views-generic-date-based-archive-index It is false by default, and when there's nothing to show, it throws a 404 error :-) Hope it helps, G On 11/6/06, [EMAIL PROTECTED]

Re: Generic Views

2006-11-06 Thread [EMAIL PROTECTED]
Jay, Thanks for your attention. I tried it around 5 times now. From 2 machines both running Ubuntu 6.06. Each time I populated the database fresh. I tried every combination I could think off. I even changed the database from SQLite to MySQL. Everytime I did things fresh. But I also tried all

Re: Django Admin - "Site administration"

2006-11-06 Thread Karen Tracey
Carl Holm wrote: > Thanks. I should clarify that I am looking for the string "Site > administration" which I did not find in the base_site.html > template. Is should also mention that I am running the dev version. You are right, "Site administration" is not coming (directly) from any of the

Newbie DB question

2006-11-06 Thread Martin Bačovský
I have two questions I was unable to google: - Is Django going to support database views? Solution i have found here: http://code.djangoproject.com/ticket/419 seems to be a bit tricky. I would rather like to create django.db.models.view which ancestors can produce SQL like 'CREATE OR REPLACE

Re: Nesh Thumbnail - Installation problem

2006-11-06 Thread Nebojsa Djordjevic
* Frankie Robertson wrote, On 06.11.2006 12:59: > On 06/11/06, Gabriel Puliatti <[EMAIL PROTECTED]> wrote: >> On Mon, 2006-11-06 at 10:07 +, Frankie Robertson wrote: >>> I think the "class Foo(models.Meta):" in the example is a probably >>> typo or something. I've used ImageWithThumbnailField

Re: Generic Views

2006-11-06 Thread Jay Parlar
On 11/5/06, Keith Mallory <[EMAIL PROTECTED]> wrote: > I wrote a blog using classic views (writing functions for reach > URLpattern). It works perfectly. However when I tried to convert it using > the same database using generic views, it does not work. > > > Then I tried using the updated code

Re: Session problems

2006-11-06 Thread Jakub Labath
Hi All, Just to clarify few things I'm not setting either cookie nor do I have have modified the sessions framework. The sessionid in question is the one that django.auth sets when one logs-in into the admin. I am using caching but not site wide I use the cache_page decorator on few views. Are

Re: Displaying ManyToMany relation in template

2006-11-06 Thread Nicolas Steinmetz
Nicolas Steinmetz wrote: > In my views.py, do I need to set/declare anything about this ? > > If I just add the previous piece of code, I have a template error with > this line highlighted - I do not have it with me :-/ : > {% for category in post.category.all %} ok my fault, I already had

Re: Creating one call for most recent entry, and another call for the restI have just set up a blog using the helpful tutorial over at

2006-11-06 Thread RajeshD
Hi Andy, Try printing out the forloop counter inside the loop to help debug this: Counter: {{ forloop.counter }} -Rajesh --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this

Re: how to do complex query which filters on method not database field

2006-11-06 Thread Ivan Sagalaev
Rachel Willmer wrote: > I have a complicated query which should return the subset of a table > whose objects match one of several conditions. > > What's the easiest way of doing this, given that I can't just do a SQL > statement, because some of the conditions require me to feed the > object's

Re: Automatically starting the FastCGI server

2006-11-06 Thread Grigory Fateyev
Hello Norbert Wojtowicz! On Sun, 05 Nov 2006 23:21:31 -0600 you wrote: > I am also interested in how others have solved this. I hope I'm not > hijacking the thread, but could we see your Debian approach to this > problem? init.d file: #! /bin/sh ### BEGIN INIT INFO # Provides:

Re: How would you do this on Django?

2006-11-06 Thread Carlos Yoder
Thank you Frankie. I guess I'm OK with the i18n part of the idea. Not so sure about the 'best practises' to implement, though (that was the general idea of this post). But many thanks for the links anyway. Regards, -- Carlos Yoder http://blog.argentinaslovenia.com/ >> Hello people, I have a

how to do complex query which filters on method not database field

2006-11-06 Thread Rachel Willmer
I have a complicated query which should return the subset of a table whose objects match one of several conditions. What's the easiest way of doing this, given that I can't just do a SQL statement, because some of the conditions require me to feed the object's values into a function to evaluate

Re: is not JSON serializable - again

2006-11-06 Thread Rachel Willmer
What specifically does the error message say is not JSON serializable? Try setting it to be a string in the response dict... For example: if errors or request.POST.has_key('preview'): response_dict = {} # datetime_now = datetime.datetime.now()

Re: How would you do this on Django?

2006-11-06 Thread Frankie Robertson
On 06/11/06, Carlos Yoder <[EMAIL PROTECTED]> wrote: > > Hello people, I have a question for you. > > I've been developing (in my head) a multilang, multisite, multiuser > blog application, that -at least for me- sounds like a very cool idea. > On to the details: > > The project is actually a

Re: Nesh Thumbnail - Installation problem

2006-11-06 Thread Frankie Robertson
On 06/11/06, Gabriel Puliatti <[EMAIL PROTECTED]> wrote: > On Mon, 2006-11-06 at 10:07 +, Frankie Robertson wrote: > > I think the "class Foo(models.Meta):" in the example is a probably > > typo or something. I've used ImageWithThumbnailField in in a normal > > model and I suggest that you do

Re: Nesh Thumbnail - Installation problem

2006-11-06 Thread Gabriel Puliatti
On Mon, 2006-11-06 at 10:07 +, Frankie Robertson wrote: > I think the "class Foo(models.Meta):" in the example is a probably > typo or something. I've used ImageWithThumbnailField in in a normal > model and I suggest that you do too. Correct me if I'm wrong, but isn't class models.Meta back

How would you do this on Django?

2006-11-06 Thread Carlos Yoder
Hello people, I have a question for you. I've been developing (in my head) a multilang, multisite, multiuser blog application, that -at least for me- sounds like a very cool idea. On to the details: The project is actually a group of sister websites dealing with a common subject, localised for

Get paid to do Django on Times Square.

2006-11-06 Thread [EMAIL PROTECTED]
It looks like my efforts to make python our base service oriented architecture technology and Django as the core web framework is coming through. I now need to hire a New York based developer to be the tech lead for much of this effort. I can't reveal the company name yet but you've heard of

Re: Re: Bugtracker sucks?

2006-11-06 Thread James Bennett
On 11/6/06, orestis <[EMAIL PROTECTED]> wrote: > If there is an option of signing up, why don't we close the > non-logged-in user ticket submission ? Largely because A) I'm still working on getting the user sign-up stuff the way we want it, and B) I don't know if we want to go the completely

Re: Displaying ManyToMany relation in template

2006-11-06 Thread Nicolas Steinmetz
Nikolaus Schlemm a écrit : > hi, > > try something like the following: > >> {% if latest_posts %} >> {% for post in latest_posts %} >> >> {{ post.title }} >> >>

Re: Bugtracker sucks?

2006-11-06 Thread orestis
If there is an option of signing up, why don't we close the non-logged-in user ticket submission ? Anyway, Akismet still leaves a lot of spam in. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users"

Re: Problems with template IFs and generic views

2006-11-06 Thread Ivan Sagalaev
[EMAIL PROTECTED] wrote: > I'm using django.views.generic.list_detail.object_detail to show a > page. Beside text it has optional "leftmenu" field. What I want to do > is to show it in a html block if it exists (there is somethign in > "leftmenu"). The problem is that it shows always or never. >

Nesh Thumbnail - Installation problem

2006-11-06 Thread Mark Jarecki
Hi all, I'm new to Django and Python - been at it for 4 days now - and have found it quite straightforward. However, I've come into difficulty trying to install Nesh Thumbnail according to the instructions at: http://trac.studioquattro.biz/djangoutils/wiki/AppInst And for the life of me I

Re: Django Admin - "Site administration"

2006-11-06 Thread Carl Holm
Thanks. I should clarify that I am looking for the string "Site administration" which I did not find in the base_site.html template. Is should also mention that I am running the dev version. James Bennett wrote: >> Carl Holm wrote: >> It's probably obvious, but after searching the docs and