Re: Trying to get fixtures working - problem with Site

2007-03-12 Thread Russell Keith-Magee
On 3/13/07, Chris Moffitt <[EMAIL PROTECTED]> wrote: > > Russell Keith-Magee wrote: > > Can you provide a specific example? Like I said, I'm adding a unit > > test to cover all the edge cases of serialization - if you have a > > specific example that is failing, I'd like to make sure that your >

Re: permissions in template

2007-03-12 Thread bgcooper
Funny that I should run into this post the same day that I'm trying to work out how to do this. I've got the same problem. From the shell: >>> user = User.objects.get(id = 3) >>> user.get_all_permissions() Set(['ivms.can_play']) >>> user.has_perm('ivms.can_play') True Fantastic. When I try and

Re: Intializing newforms Form objects

2007-03-12 Thread Nebojša Đorđević
On Mar 8, 2007, at 16:50 , anders conbere wrote: > I'm hoping to make a generic function that would do both __dict__ and > handle m2m fields (o2m fields as well) that would let you one off > these kinds of things. The problem with this stuff being that if you > have an object with any

object has no attribute get

2007-03-12 Thread GufyMike
This error is similar to ticket #999 http://code.djangoproject.com/ticket/999 I have renamed the field in question to something unique already and adjusted the the database to reflect this. I'm still at a loss what the fix could be. Error: 'UserProfile' object has no attribute 'get' Request

Re: Duplicating model/view structure across several Django apps

2007-03-12 Thread akonsu
yes, i was thinking that may be models.py might import actual models from elsewhere? if it can you will still have separate one-line models.py but i think it is acceptable. no? On Mar 12, 11:59 pm, "Mark Engelberg" <[EMAIL PROTECTED]> wrote: > Well, as far as I can tell, for each entry in my

Is Signal multiple machine safe?

2007-03-12 Thread Alex Dong
Hi all, I'm using post_save signal to send a "Your Account is Created" type of email. Since I have four machines, two django front end server pointing to two MySQL cluster, I'm wondering is the post_save signal multiple machine safe? That is, if my signal is processed, is it possible that the

How to use Django session without browser cookies support

2007-03-12 Thread Sengtha
I am currently working on one project which needs to view page on browser that doesn't support cookies. By what I know, all Django sessions are based on browser cookies. And Django sessions are save in django_session table. I wonder there is any way to implement Django session like PHP

Re: Duplicating model/view structure across several Django apps

2007-03-12 Thread Mark Engelberg
Well, as far as I can tell, for each entry in my INSTALLED_APPS (from settings.py), it looks in that directory, and expects to find a models.py there. So I'm looking for an alternative to duplicating the same models.py file in multiple directories. --Mark On 3/12/07, akonsu <[EMAIL PROTECTED]>

Re: how to use .htc file in django

2007-03-12 Thread OudS
On 3月12日, 下午8时55分, Sam Morris <[EMAIL PROTECTED]> wrote: > The fix is webserver specific. The Django built-in development web server > will check /etc/mime.types on Unix, so editing that file is sufficient. thanks to Sam Morris very much, you remind me, I look over the django file, it seems

Re: how to use .htc file in django

2007-03-12 Thread OudS
On 3月12日, 下午9时09分, "Benjamin Slavin" <[EMAIL PROTECTED]> wrote: > Also, in the future, please do -not- post this type of question to the > Django-Dev mailing list. That list is for use by developers of Django > itself, not problems end-users are experiencing in their own > applications

Re: Trying to get fixtures working - problem with Site

2007-03-12 Thread Chris Moffitt
Russell Keith-Magee wrote: > Can you provide a specific example? Like I said, I'm adding a unit > test to cover all the edge cases of serialization - if you have a > specific example that is failing, I'd like to make sure that your > example is covered in the test. > > You hit it. It was a

Re: Duplicating model/view structure across several Django apps

2007-03-12 Thread akonsu
hello, but model.py is imported it as any module. what prevents you from just having it on the PYTHONPATH and not necessarily in the application directory? may be i misunderstood the question... konstantin On Mar 12, 9:37 pm, "Mark Engelberg" <[EMAIL PROTECTED]> wrote: > So I've got several

Re: Starting other processes in a view gives me some weird results.

2007-03-12 Thread akonsu
hello, i do not know what causes this. i am curious what happens if you replace return HttpResponse(stdout or stderr) with return HttpResponse('hello world') this is how i would debug konstantin On Mar 12, 10:03 pm, "Ino Pua" <[EMAIL PROTECTED]> wrote: > Quick way of reproducing: > >1.

Re: Where art thou ImageField

2007-03-12 Thread akonsu
the view i think. on a form submission. new forms have save method too. konstantin On Mar 12, 8:46 pm, "gorans" <[EMAIL PROTECTED]> wrote: > Hmm.. I see the point there. > > But where would be the right place to generate the set of thumbs from > the original image? > > On Mar 13, 1:04 am,

Re: How much work has been done with newforms?

2007-03-12 Thread Rubic
Grupo Django: > I'm programming a website in django and I'd > like to know more about newfors, since I left > the forms to the end, but now I have to start > with them. I think newforms is almost production-ready and would advise anyone starting a new project to consider using it in favor of

Duplicating model/view structure across several Django apps

2007-03-12 Thread Mark Engelberg
So I've got several applications which share the same model/view structure. I have kept the applications separate because conceptually I want them separate in the admin interface, I want them to store their respective info in separate tables in the database, and most importantly, I want to

Re: Apache2 displays django app as a file list

2007-03-12 Thread Mikey
That worked! Thanks for your input - you've put me on the road to dumping 7 years worth of Microsoft training to learn and use OpenSource!! On Mar 12, 1:45 am, Daniel Hepper <[EMAIL PROTECTED]> wrote: > Try to set PythonPath to the path where your project lives, not to your > django

Re: Playing with fixtures and django serializers -> Errors...

2007-03-12 Thread Russell Keith-Magee
On 3/13/07, Jens Diemer <[EMAIL PROTECTED]> wrote: > > > I'm playing with django.core.serializers... so far with few success :( Hi Jens, I've just finished writing a new set of tests for the serializers, which included fixing a number of bugs. These fixes have been checked in as of [4719]. Can

Re: QueryDict instance is immutable

2007-03-12 Thread limodou
On 3/13/07, Grupo Django <[EMAIL PROTECTED]> wrote: > > Hi! > I have created a form using newforms, and one field is author which I > want to fill using the current username, I did this: > request.POST['author']="Username I want" > and I got this error: > "QueryDict instance is immutable" > Ok,

Re: Where art thou ImageField

2007-03-12 Thread Jay Parlar
You may want to check out the 'stockphoto' app. Even if you don't use it directly, it might give you ideas. It seems to handle thumbnails quite well. http://www.carcosa.net/jason/software/django/stockphoto/ Jay P. --~--~-~--~~~---~--~~ You received this message

Re: Where art thou ImageField

2007-03-12 Thread gorans
Hmm.. I see the point there. But where would be the right place to generate the set of thumbs from the original image? On Mar 13, 1:04 am, "akonsu" <[EMAIL PROTECTED]> wrote: > hello, > > regarding the last part of your post: i have an unconfirmed suspicion > that data validation should not be

Re: Trying to get fixtures working - problem with Site

2007-03-12 Thread Russell Keith-Magee
On 3/12/07, Chris Moffitt <[EMAIL PROTECTED]> wrote: > > Installing xml fixture 'initial_data' from '/full/path/shop/fixtures'. > Problem installing fixture '/full/path/shop/fixtures/initial_data.xml': > Invalid value: 'site' should be a 'django.contrib.sites.models.Site'> instance, not a > >

Re: User id foreign key

2007-03-12 Thread Russell Keith-Magee
On 3/12/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > You have to do something like this in your model: > user_created = models.ForeignKey(User, related_name="user_created") > > Then instead of saying User.entry_set .. I think its just > user_created_set ... but not positive on that.

Re: Designing for Speed - conditionals inside the view versus the template

2007-03-12 Thread Ned Batchelder
And unless your application is extremely unusual, by far the biggest expense is database queries. More than anything else, this is what governs the speed of your application. So don't worry about where the conditionals are being evaluated: worry about how much data you are pulling from the

Re: Designing for Speed - conditionals inside the view versus the template

2007-03-12 Thread James Bennett
On 3/12/07, Bill de hOra <[EMAIL PROTECTED]> wrote: > Merric Mercer wrote: > > > 1. Design a template with lots of {% if %} conditional statements > > > > 2. Do the bulk of the work in the view, by doing something like:- > > > > 3. Do a combination of the two above > > 4: Caching? 5.

I18n not working

2007-03-12 Thread Christian Hoeppner
Hi there, Actually, it's plainly that. It's just not working, and I don't really know where to look for a flaw. It's just a blind guess, but maybe django is not correctly locating my .mo files? I've triple-checked their location and tried in every place stated in the documentation or the django

QueryDict instance is immutable

2007-03-12 Thread Grupo Django
Hi! I have created a form using newforms, and one field is author which I want to fill using the current username, I did this: request.POST['author']="Username I want" and I got this error: "QueryDict instance is immutable" Ok, what should I do? I thought about create a hidden widget for this

Re: Administration features in user pages - SOLVED

2007-03-12 Thread Gilhad
Thank you, so I will do it the same way. If there is no easier way, this one should be sufficient for me. At least I will have no bad feeling, that I am doing it by the difficult way, when there (maybe) exist another, better one. On Monday 12 March 2007 16:20, Karen Tracey wrote: > I don't

Re: Designing for Speed - conditionals inside the view versus the template

2007-03-12 Thread Bill de hOra
Merric Mercer wrote: > 1. Design a template with lots of {% if %} conditional statements > > 2. Do the bulk of the work in the view, by doing something like:- > > 3. Do a combination of the two above 4: Caching? cheers Bill --~--~-~--~~~---~--~~ You

Re: Filter "Dates"

2007-03-12 Thread Stephen Mizell
> Try doing the filtering first (since filter() returns a QuerySet) and > then calling dates() on the result. So > > Model.objects.filter().dates() Worked perfectly. I would have bet money I had tried that earlier, but it looks like I would have lost that bet. Thanks for your

Re: Permalink decorator and generic views, revisited

2007-03-12 Thread James Bennett
On 3/12/07, dchandek <[EMAIL PROTECTED]> wrote: > Am I missing something? It's not that 'permalink' doesn't work with generic views -- it can. As I understand it, the problem is a URLConf like this: urlpatterns = patterns('django.views.generic.list_detail', (r'^foo/(?P\d+)/$',

Re: Administration features in user pages - newbie

2007-03-12 Thread Gilhad
I will, but there is a lot of documentation about django ... which file/page is related to the integration of this features into my code ? (I can write my filtres and everything, but this is long and duplacate work, so I try to reuse the existing features from adminsite, but in my own views,

Permalink decorator and generic views, revisited

2007-03-12 Thread dchandek
I posted previously about how it seemed to me that, while the permalink decorator is useful in decoupling the get_absolute_url() methods of an application's models from the site/project, it more or less forces you to create dummy custom views where you would normally simply use generic views.

Re: Reversed edit_inline?

2007-03-12 Thread jfagnani
On Mar 11, 8:43 pm, "chasfs" <[EMAIL PROTECTED]> wrote: > ORM has been contentious for many years - for more background on the > problems of > ORM, check out Ted Neward's blog entry > -http://blogs.tedneward.com/2006/06/26/The+Vietnam+Of+Computer+Science... > > Peace, > -chasfs That for the

Re: Filter "Dates"

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 19:37 +, Stephen Mizell wrote: > I'm trying my hardest to make an archive list on our website. I can > pull them up fine with Model.objects.dates('pub_date','month') but I > can't use .filter() on them for some reason. We add things to the > database sometimes with a

Re: Accesing a property and methd in the admin site

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 17:37 +, hass wrote: > I just got my first django app up: http://brackets.bracketboy.net/ Not > very impressive, but I'm still excited about it. anyway . . . > > > I'm having trouble accesing a method through the admin interface as > part of a choices list. It seems to

Re: Image and File Field hard coded sizes

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 09:29 -0700, Brendon wrote: > Hello folks, > > I'm curious if there is a better way of changing File and Image Fields > from "varchar(100)" to "varchar(%(maxlength)s)" than editing "django/ > db/backends/mysql/creation.py". Is there any particular reason why > these are

Study & Work in USA - These people are arranging everything for us.

2007-03-12 Thread Charles
Hi Friends, Greetings!! I was searching for information on Study & WORK IN USA & reached to this very much informative site, www.sonal.coolgoose.in, I would like to tell you more about STUDY & WORK IN USA. There are so many universities waiting for us to join them for our further studies and

Re: Django effects Python time/datetime and gives wrong time after DST update

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 11:53 -0300, Ramiro Morales wrote: > On 3/12/07, DavidA <[EMAIL PROTECTED]> wrote: > > > > I found a workaround but I'm not sure what the ramifications are. I > > commented out this line in django.conf.__init__.py: > > > > os.environ['TZ'] = self.TIME_ZONE > > > > What

Re: Any known issues with ChangeManipulators and large objects?

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 10:27 -0700, Joseph Heck wrote: > Kudo's to Ivan - It's a pretty good answer. I think the metaphor > breaks down when you get to >1000 items that could pop up in a select > field, but at least you don't get his when just using a plain-jane > manipulator with this fix. > >

Filter "Dates"

2007-03-12 Thread Stephen Mizell
I'm trying my hardest to make an archive list on our website. I can pull them up fine with Model.objects.dates('pub_date','month') but I can't use .filter() on them for some reason. We add things to the database sometimes with a pub_date > today's date so things are automatically published in

Re: How much work has been done with newforms?

2007-03-12 Thread Brendon
On Mar 12, 3:59 am, "Grupo Django" <[EMAIL PROTECTED]> wrote: > Hello, I'd like to know how is the work going with newforms. I don't > want a release date or something like this, just to know how is it > going, and the documentation as well. > I'm programming a website in django and I'd like to

Re: Django keeps growing, performance keeps dropping

2007-03-12 Thread Joseph Heck
Take a shot at enabling the profiling (Jeremy provided a link a few msgs back) - it'll give you a huge amount of detail. -joe On 3/12/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > Well crud. My host won't turn on slow query logging. So, if you know > you've got a bunch of not-so-good

Playing with fixtures and django serializers -> Errors...

2007-03-12 Thread Jens Diemer
I'm playing with django.core.serializers... so far with few success :( With JSON i get the Error: "ContentType matching query does not exist." If i use the "python" format, i get from serializers.serialize() a list. How should I to store these list in a file? With pickle, repr() or

Re: Chaining ManyToMany Filters Update

2007-03-12 Thread Gerard Whittey
Boris Smus wrote: > On Mar 12, 6:56 am, Tim Chase <[EMAIL PROTECTED]> > wrote:> >> cs.filter( >> Q(default_recipe__ingredients__ingredient__id=3) | >> Q(default_recipe__ingredients__ingredient__id=1) >> ) > > Just to clarify, I was trying to get AND functionality, as

Re: Chaining ManyToMany Filters Update

2007-03-12 Thread Boris Smus
On Mar 12, 6:56 am, Tim Chase <[EMAIL PROTECTED]> wrote:> > cs.filter( > Q(default_recipe__ingredients__ingredient__id=3) | > Q(default_recipe__ingredients__ingredient__id=1) > ) Just to clarify, I was trying to get AND functionality, as Konstantin suggested. I also tried

Accesing a property and methd in the admin site

2007-03-12 Thread hass
I just got my first django app up: http://brackets.bracketboy.net/ Not very impressive, but I'm still excited about it. anyway . . . I'm having trouble accesing a method through the admin interface as part of a choices list. It seems to work fine throughout the site and the admin interface, but

Re: low performance of FastCGI deployment

2007-03-12 Thread Joseph Heck
Have you done any profiling to see where your bottlenecks are? There's a decent set of notes on profiling Django at http://code.djangoproject.com/wiki/ProfilingDjango and an even greater writeup at http://www.rkblog.rk.edu.pl/w/p/django-profiling-hotshot-and-kcachegrind/. Apache+Mod_Python and

Re: Any known issues with ChangeManipulators and large objects?

2007-03-12 Thread Joseph Heck
Kudo's to Ivan - It's a pretty good answer. I think the metaphor breaks down when you get to >1000 items that could pop up in a select field, but at least you don't get his when just using a plain-jane manipulator with this fix. I think I'll stick with the tendency towards using raw_id_admin=True

Jobs Vs Opportunity - The Movie

2007-03-12 Thread mike
Jobs Vs Opportunity - The Movie www.thewealththeory.com/beyond-freedom This is excellent! If you haven't already watched, it check it out now. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group.

Re: django install on mac osx 10.4.8

2007-03-12 Thread Jay Parlar
On 3/12/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > nope i do it from home, never had any problem before, not like i would > really have known anyway got problem all the time :), > problem isntalling this and that, problem installing rails and so on. > shame i really want to give a try

Re: search criteria

2007-03-12 Thread theju
There is something called as Full text Search (i believe it is called TSearch2...not sure of the name though) in postgresql. Google for further info. If you use some other database you might have to use: 1) Xapian http://www.xapian.org 2) pyLucene http://pylucene.osafoundation.org/ 3) Swish-E (I

Re: High Fidelity Slugify : support for international characters

2007-03-12 Thread Aidas Bendoraitis
There were similar tryings to create international slugification before: http://groups.google.com/group/django-users/browse_thread/thread/6942f87bed76a536/8d38392e25dd1974 But your approach seems to be more generic. You should certainly post it on djangosnippets.org as a separate snippet or

error in django admin module

2007-03-12 Thread Paul Rauch
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello, I found an error in django. I use python 2.5 the error occurs both in the actual official released version and in the svn version. as soon as I enter the adminpage I get following error, if I have a sessioncookie. without sessioncookie no

Image and File Field hard coded sizes

2007-03-12 Thread Brendon
Hello folks, I'm curious if there is a better way of changing File and Image Fields from "varchar(100)" to "varchar(%(maxlength)s)" than editing "django/ db/backends/mysql/creation.py". Is there any particular reason why these are hard set? My relative paths seem to have exceeded the 100 char

Re: search criteria

2007-03-12 Thread akonsu
hello, yes, there is search functionality called database API: http://www.djangoproject.com/documentation/db_api/ do you have anything specific in mind? konstantin On Mar 12, 7:09 am, "Mary" <[EMAIL PROTECTED]> wrote: > is there any search functionality that has been implemented with >

mysql problems - guess not, but still :)

2007-03-12 Thread Michal Jedryszka
Hi. We have some intresting situations in one of our environments. 1. When we generate request that causes object not found errors after 5 such requests we get info that we cannot connect DB. Looks like some connection limitation but we cant reproduce it in other environments. 2. Occures when

Re: Designing for Speed - conditionals inside the view versus the template

2007-03-12 Thread John DeRosa
Merric Mercer wrote: > I have view that returns a whole bunch of different variables and > boolean flags.The state of these flags determine what the user > actually sees on their screen. > > From a design perspective I seem to have two options:- > > > 1. Design a template with lots

Re: BooleanField won't update

2007-03-12 Thread [EMAIL PROTECTED]
Looks like some weird behavior. I fixed it like this: def update_snip(request): u = User.objects.get(id=request.session['userid']) snip = Snippet.objects.filter(id=snippet_id,user=u) the_snip = snip[0] the_snip.active = 0 the_snip.save() print "Active = %s" %

Re: django install on mac osx 10.4.8

2007-03-12 Thread [EMAIL PROTECTED]
nope i do it from home, never had any problem before, not like i would really have known anyway got problem all the time :), problem isntalling this and that, problem installing rails and so on. shame i really want to give a try at django reviews looks good, better than rail for a designer like

Re: django install on mac osx 10.4.8

2007-03-12 Thread Jay Parlar
On 3/12/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > well i tried with the forewall and offan it return the same error all > the time. Sorry, I misspoke. I didn't mean firewall, the firewall should have no effect. I actually meant proxy. Many corporate environments are behind proxies

Jobs Vs Opportunity - The Movie

2007-03-12 Thread mike
Jobs Vs Opportunity - The Movie www.thewealththeory.com/beyond-freedom.com This is excellent! If you haven't already watched, it check it out now. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users"

Re: Django effects Python time/datetime and gives wrong time after DST update

2007-03-12 Thread DavidA
Thanks. I am on trunk, 4227 so I don't have this fix. On Mar 12, 10:53 am, "Ramiro Morales" <[EMAIL PROTECTED]> wrote: > On 3/12/07, DavidA <[EMAIL PROTECTED]> wrote: > > > > > I found a workaround but I'm not sure what the ramifications are. I > > commented out this line in

Re: Multi-tenant database

2007-03-12 Thread James Bennett
On 3/12/07, zin <[EMAIL PROTECTED]> wrote: > Is Django suitable for multi-tenant database application? i.e. > combining username and company_id as primary key Django does not currently have support for composite keys. You can fake this to a certain extent with unique_together, but from Django's

Re: Administration features in user pages - newbie

2007-03-12 Thread anders conbere
Gilhad, just read the documentation. ~ Anders On 3/12/07, Gilhad <[EMAIL PROTECTED]> wrote: > > > Is anywhere some simple tutorial, how to implement such features (filters, > sorting, pagination) into my views? Or is the fastest way try to read and > understand source of django/contrib/admin

Re: Administration features in user pages - newbie

2007-03-12 Thread Karen Tracey
I don't know of any tutorial/doc that covers how the admin implements filters, etc. When I wanted similar functionality on my user-visible pages I just read the admin souce to see how it did it...all in all it wasn't too tough to figure out. Karen On 3/12/07, Gilhad <[EMAIL PROTECTED]> wrote: >

Re: Unique_together question

2007-03-12 Thread Rob J Goedman
Thanks Ramiro, Thanks for the pointer and hint. Next time I will search there first. That indeed gets it through the validator. The error seems to be caught by some lower level (db?), but for now that works. Thanks again, Rob On Mar 11, 2007, at 4:45 PM, Ramiro Morales wrote: > > On

BooleanField won't update

2007-03-12 Thread [EMAIL PROTECTED]
I have a class call snippet: class Snippet(models.Model): user = models.ForeignKey(User) entry = models.ForeignKey(Entry) commentary = models.ForeignKey(Commentary) date_created = models.DateTimeField(auto_now_add=True) active = models.BooleanField(default=True) snippet

Re: dict object is not callable (newforms/forms.py full_clean)

2007-03-12 Thread akonsu
hello, i think render_to_response takes a Context object not a dict as the second parameter. konstantin On Mar 12, 10:56 am, "DvD" <[EMAIL PROTECTED]> wrote: > I got the same problem in a different context: > > > Exception Type: TypeError > Exception Value:'dict' object is not

Trying to get fixtures working - problem with Site

2007-03-12 Thread Chris Moffitt
I've been trying to get the fixtures working in order to beef up the unit tests with my app. I'm running into an issue and wonder if anyone else has seen this. I can serialize the data just fin. When I try to load the data, I get the error below. I've tried this with the XML and brand new

Re: dict object is not callable (newforms/forms.py full_clean)

2007-03-12 Thread DvD
I got the same problem in a different context: Exception Type: TypeError Exception Value:'dict' object is not callable Exception Location: /usr/lib/python2.4/site-packages/Django-0.95.1- py2.4.egg/django/newforms/forms.py in full_clean, line 180 Can someone help? On 5

Re: Django effects Python time/datetime and gives wrong time after DST update

2007-03-12 Thread Ramiro Morales
On 3/12/07, DavidA <[EMAIL PROTECTED]> wrote: > > I found a workaround but I'm not sure what the ramifications are. I > commented out this line in django.conf.__init__.py: > > os.environ['TZ'] = self.TIME_ZONE > What version/revision of Django are you using?. See ticket #2315 and changeset

Re: Django admin site

2007-03-12 Thread [EMAIL PROTECTED]
Thanks. It means I have to have Django source and copy admin media files to Apache document root. best regards, On Mar 11, 1:15 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 3/10/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > When deploying site using apache + mod_python, how to

Re: Request for test confirmation

2007-03-12 Thread Ramiro Morales
On 3/12/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > Thanks, Ramiro. Although, interesting that you only had one failure and > not two. *Shrug*. > > What database backend were you using here? SQLite? > Sorry for the incomplete report, I was in a hurry leaving for work. Yes I'm using the

Re: Document type/Charset issues?

2007-03-12 Thread [EMAIL PROTECTED]
Did not know that setting. Thanks James! On Mar 9, 11:04 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 3/9/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > also, google webmaster tools reports that the majority (about 80%, but > > not all) of the site is US-ASCII, not UTF-8 > > The

Re: django install on mac osx 10.4.8

2007-03-12 Thread [EMAIL PROTECTED]
well i tried with the forewall and offan it return the same error all the time. i tried agai to get darwin port running ( and the latest mac part as well) http://www.rhonabwy.com/wp/2006/07/20/installing-django-on-macos-x-development-version/ but once i downloaded either the dmg or the source

Re: Django keeps growing, performance keeps dropping

2007-03-12 Thread [EMAIL PROTECTED]
Well crud. My host won't turn on slow query logging. So, if you know you've got a bunch of not-so-good queries (as shown above), how would one try to spot them? On Mar 10, 4:58 pm, "gilhad" <[EMAIL PROTECTED]> wrote: > On Mar 7, 4:26 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > wrote: > > >

Re: Django effects Python time/datetime and gives wrong time after DST update

2007-03-12 Thread DavidA
I found a workaround but I'm not sure what the ramifications are. I commented out this line in django.conf.__init__.py: os.environ['TZ'] = self.TIME_ZONE On Mar 12, 10:19 am, "DavidA" <[EMAIL PROTECTED]> wrote: > I have some scripts that run tasks and use Django DB models. They have > been

newforms: usage of smart_unicode breaks gettext?

2007-03-12 Thread Boris Erdmann
Hello group, The __init__ method of the newforms.Field class normalizes labels and help_text by using smart_unicode. This seems to break gettext/gettext_lazy: When accessing a newly started runserver with two browsers with different accept-languages, both get to see the translation of the

Re: Multi-tenant database

2007-03-12 Thread Kenneth Gonsalves
On 12-Mar-07, at 7:46 PM, Tim Chase wrote: > As previously mentioned by Malcom, Django doesn't currently > support multi-column keys. their *is* unique_together, but will that suit your needs? -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/

Django effects Python time/datetime and gives wrong time after DST update

2007-03-12 Thread DavidA
I have some scripts that run tasks and use Django DB models. They have been running an hour late today after all the DST changes (here in the US). I've traced it down to any call to Django is shifting my time back an hour (like it was before this weekend's shift). So the time as reported by

Re: django install on mac osx 10.4.8

2007-03-12 Thread Jay Parlar
On 3/12/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Hi everybody, > > i'm trying to install django, i followe dthe instruction on the django > web site but it doesn't work > been looking around and the only tutorial that i yet understand > ( sorry it's al a bit complicated for me )

Re: Multi-tenant database

2007-03-12 Thread Tim Chase
> Is Django suitable for multi-tenant database application? i.e. > combining username and company_id as primary key You omit some key details: -are the tenants writing data, or just reading data? If they're just reading data, you can jockey your views based on the tenant. We're currently

Re: HTTP Response returning 204

2007-03-12 Thread shevken
So i need to set USE_ETAGS=True in settings.py And then return response.status_code=204 Hmm..i'll try it tomorrow at work. On Mar 12, 6:27 pm, "Horst Gutmann" <[EMAIL PROTECTED]> wrote: > 2007/3/12, shevken <[EMAIL PROTECTED]>: > > > > > Anyway to return response code 204 from a view? > > >

Re: Where art thou ImageField

2007-03-12 Thread akonsu
hello, regarding the last part of your post: i have an unconfirmed suspicion that data validation should not be done in models but in the forms that manipulate data. does anyone know if this is correct? konstantin On Mar 12, 9:56 am, "gorans" <[EMAIL PROTECTED]> wrote: > Hi, > > I'm trying to

Re: how to use .htc file in django

2007-03-12 Thread Sam Morris
On Mon, 12 Mar 2007 05:15:14 -0700, 骛之 张 wrote: > hi everyone here, how to use .htc file in django > > if in j2ee or nomal html file, i can define in table as style="behavior:url(/htc_path/js/TableSort.htc) url(/htc_path/js/ > TableHL.htc) url(/htc_path/js/DragDrop.htc);"> > > but in django,

multi-db branch and too many connections

2007-03-12 Thread [EMAIL PROTECTED]
Has anyone else using the multiple-database branch had problems with 'too many connections' errors? The trunk was being merged into this project until last fall I believe...so I think the mod_python bug that existed early on is fixed...but when I get two or three QA ppl in my system at the same

Where art thou ImageField

2007-03-12 Thread gorans
Hi, I'm trying to access the value of an image field which is uploaded in the django admin interface - prior to calling the save. I have a model called Photo with three attributes: large, medium and small. Each are ImageFields. I have overwritten the save( ) function in Photo so that I can

High Fidelity Slugify : support for international characters

2007-03-12 Thread Sam
I needed slugify to be more precise with accented characters and i couldn't find some code to do it, so here it is : http://amisphere.com/contrib/python-django/slughifi.py http://amisphere.com/contrib/python-django/ for a quick overview example : >>> text = "C'est déjà l'été." >>>

Re: Chaining ManyToMany Filters Update

2007-03-12 Thread Tim Chase
> > >[56]:cs.filter(default_recipe__ingredients__ingredient__id=3).filter(default_recipe__ingredients__ingredient__id=1) >> Out[56]:[] > This would map to a Query that looks like this "... WHERE id=3 AND > id=1". that would most certainly return no results. Unless those ingredients were

Re: Chaining ManyToMany Filters Update

2007-03-12 Thread akonsu
Hello, please allow me to disagree. the first two queries in the original post return result sets which overlap. but they combined return the empty set. this is the problem. konstantin On Mar 12, 9:13 am, Atilla <[EMAIL PROTECTED]> wrote: > On 12/03/07, Boris Smus <[EMAIL PROTECTED]> wrote: >

Re: newforms, choices and models

2007-03-12 Thread Massimiliano Ravelli
On 12 Mar, 11:31, enquest <[EMAIL PROTECTED]> wrote: > However one question is still open! Did you look at my previous post ? Massimiliano --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: Allowing no value for a DateField

2007-03-12 Thread Jay Parlar
On 3/12/07, Roland Hedberg <[EMAIL PROTECTED]> wrote: > > Hi! > > I have designed a model which contains among other things a couple of > DateFields. > > Some, actually one, of these must have a value but the other may not. > > So, I tried to use the construct: > > done_planned =

Re: Multi-tenant database

2007-03-12 Thread Malcolm Tredinnick
On Mon, 2007-03-12 at 06:11 -0700, zin wrote: > Is Django suitable for multi-tenant database application? i.e. > combining username and company_id as primary key We do not support multi-column primary keys at this point in time. Malcolm --~--~-~--~~~---~--~~

Re: Allowing no value for a DateField

2007-03-12 Thread Jonathan Buchanan
On 3/12/07, Roland Hedberg <[EMAIL PROTECTED]> wrote: > > Hi! > > I have designed a model which contains among other things a couple of > DateFields. > > Some, actually one, of these must have a value but the other may not. > > So, I tried to use the construct: > > done_planned =

Re: low performance of FastCGI deployment

2007-03-12 Thread Atilla
I am running a system with basically the same versions of all software packages as you are. It is in production and under stress testing it performed very very well and there've been no issues with performance so far. I am using Apache + FastCGI, server-managed. First thing you might want to

Re: how to use .htc file in django

2007-03-12 Thread Benjamin Slavin
It is not clear to me what you are asking. You will need to provide more information than "I cannot do it correctly". However, your browser interprets the output of Django in the same way as 'normal HTML' and J2EE application HTML output. You should check the HTML generated by your Django

Re: Chaining ManyToMany Filters Update

2007-03-12 Thread Atilla
On 12/03/07, Boris Smus <[EMAIL PROTECTED]> wrote: >[56]:cs.filter(default_recipe__ingredients__ingredient__id=3).filter(default_recipe__ingredients__ingredient__id=1) > Out[56]:[] This would map to a Query that looks like this "... WHERE id=3 AND id=1". that would most certainly return no

Multi-tenant database

2007-03-12 Thread zin
Is Django suitable for multi-tenant database application? i.e. combining username and company_id as primary key --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

permissions in template

2007-03-12 Thread masuran
Hello everyone, I've created a custom permission on one of my models and I've given a user the custom permission. When I go into the shell (manage.py shell), I can confirm that the user has the custom permission. But when I use the perms object in one of my templates, it simple doesn't work.

  1   2   >