Re: Searching IntegerField

2009-07-01 Thread Harish
Sorry By mistake I typed as "search_field" , it was "search_fields" actually in the code On Jul 1, 11:24 am, Marcelo Ramos wrote: > On Wed, Jul 1, 2009 at 2:29 AM, Harish wrote: > > > hi friends, > >    I designed a model in django, which has a Integer field. When I > > include the integer f

Re: serving a static file via nginx requiring authentication from django

2009-07-01 Thread Skylar Saveland
You could document this experience once you get it running; sounds useful. On Jun 30, 1:00 am, John Hensley wrote: > On 6/28/09 10:20 PM, Annie wrote: > > > I'm trying to this to work: users can download their files from their > > account page from a url like > > this:http://example.com/account

Re: marrying django to twitter

2009-07-01 Thread Kenneth Gonsalves
On Wednesday 01 July 2009 09:01:58 David Zhou wrote: > On Tue, Jun 30, 2009 at 11:21 PM, Kenneth Gonsalves > > wrote: > > has anyone succeeded in marrying django to twitter - that is broadcasting > > updates in the django db to twitter? I did see one post on the subject in > > the archives, but t

Re: PyDev users: how do you manage tabs?

2009-07-01 Thread kRON
One thing you can do is turn on the option 'Link with editor' on your package\project explorer view. You have the *down arrow* ['View Menu' tooltip] and an option at the bottom--'Link with Editor'. That way, any active file in the editor will highlight the file in your view, and you can keep trac

Re: Using a dynamically created ImageField filename prior to save?

2009-07-01 Thread Andrew Turner
2009/6/30 Andrew Turner : > Hi, > > This is an issue which, I believe, is related to Ticket #10788 > (http://code.djangoproject.com/ticket/10788). > > The following code snippet used to work with Django 1.0.2, but with > the latest svn version the slug is not being set to the filename > produced b

Re: serving a static file via nginx requiring authentication from django

2009-07-01 Thread Alvin
I'll be writing a blog post about this soon when John wrote is right on though it took me a while to wrap my mind around it the nginx location + nginx alias + url passed = file to be served so to get file /home/me/web/example.com/download/file.pdf location ^~ /download {

change field value before valid of admin

2009-07-01 Thread Shuge Lee
# cat models.py class Seed(models.Model): name = models.CharField(max_length=128, unique=True) category = models.ForeignKey(Category) source = models.CharField(max_length=256) now, I want source = category + '/' + name if user doesn't fill source field in admin view How to do that ?

Re: change field value before valid of admin

2009-07-01 Thread Kenneth Gonsalves
On Wednesday 01 July 2009 14:58:00 Shuge Lee wrote: > # cat models.py > > class Seed(models.Model): > name = models.CharField(max_length=128, unique=True) > category = models.ForeignKey(Category) > source = models.CharField(max_length=256) > > now, I want > source = category + '/' + na

Can I use databrowse to display a QuerySet ???½

2009-07-01 Thread Jesper
Hello there, I've just started using django. I've set up my models, got the admin pages up and is using databrowse to present the raw data of each model. I need to generate some well defined queries and present those too. Is this somehow possible with databrowse? Cheers, Jesper --~--~

Making a ManyToManyField to its own model?

2009-07-01 Thread littlejim84
I'm new to Django, and I'm developing an project where I have an app called 'people' and a model inside called 'person'. The project itself is based around the idea of people connecting with each other... So, I as a person can connect to 3 other persons in the project, or any of those persons can

django cache framework not work well on mod_python of apache

2009-07-01 Thread Hongyu Li
#!/usr/bin/env python # -*- coding: utf-8 -*- import xmlrpclib import os import sys import time import math import optparse import tm.filecheck import service from django.http import HttpResponse from django.core.cache import cache def getCategoryAndDetail(request): keyword = request.G

How to model a OneToMany relation to an abstract class ?

2009-07-01 Thread Mathieu Leplatre
Hi all, I am trying to design the following model : - a checklist is a collection of checkpoints - a checkpoint can be an action, or a group of actions. - the same action can be in several groups I read the Generic relations documentation : http://www.djangoproject.com/documentation/models

EveryBlock source code public

2009-07-01 Thread James Matthews
And we have another Django blog application! :) http://blog.everyblock.com/2009/jun/30/source/ -- http://www.goldwatches.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this gro

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Graham Dumpleton
On Jul 1, 7:22 pm, Hongyu Li wrote: > #!/usr/bin/env python > # -*- coding: utf-8     -*- > import xmlrpclib > import os > import sys > import time > import math > import optparse > import tm.filecheck > import service > from django.http import HttpResponse > from django.core.cache import cache

Re: Making a ManyToManyField to its own model?

2009-07-01 Thread Mathieu Leplatre
On 1 juil, 10:45, littlejim84 wrote: > I'm new to Django, and I'm developing an project where I have an app > called 'people' and a model inside called 'person'. The project itself > is based around the idea of people connecting with each other... So, I > as a person can connect to 3 other person

file extensions for templates

2009-07-01 Thread David De La Harpe Golden
Hi, As far as I can see, django shouldn't care in the slightest about template file name extensions, but being a django newbie, I could have missed something (e.g. autosetting of a mime type somewhere based on extension), so just to verify - it doesn't? (considering moving to an extra file exten

How to filter out posts from friends?

2009-07-01 Thread coan
I have a friendship model for users and want to retrieve all the posts my friends made. class Friendship(models.Model): from_friend = models.ForeignKey( User, related_name='friend_set' ) to_friend = models.ForeignKey( User, related_name='to_friend_set' ) class Post(models.Model): text = mode

how to select resultset by foreignkey `s attribute

2009-07-01 Thread newlife
class company(models.Model): on=models.BooleanField() class work(models.Model): company=models.ForeignKey (company,related_name='vote_company',) how can I get the works those company.on is true?? bow --~--~-~--~~~---~--~~ You r

Re: Django 1.0.2 Thread safety

2009-07-01 Thread Miles
On Jun 30, 8:10 am, Thomas Guettler wrote: > Hi, > > I hit this bug some time ago, too. If you run SVN 1.0.X you get the > bug fixes for free. > >   Thomas Yeah, but then you have to test your releases really carefully on each svn up - not every commit has gone through a complete test run, as 10

Catch an IntegrityError in views to get back pk value of prexisting model

2009-07-01 Thread Frédéric Hébert
Hello, I 'm working on a prexisting application which goal is to manage courses and to link them to categories, teachers and so on... I have to rewrite a view. In this view, the third of the overall process, users link their course to at least one teacher. The point here is that there is no c

Re: how to select resultset by foreignkey `s attribute

2009-07-01 Thread Gabriel .
2009/7/1 newlife : > > class company(models.Model): >on=models.BooleanField() > class work(models.Model): >company=models.ForeignKey > (company,related_name='vote_company',) > > > > > how can I get the works those company.on is true?? work.objects.filter(company__o

Re: How to filter out posts from friends?

2009-07-01 Thread Mathieu Leplatre
On 1 juil, 14:44, coan wrote: > I have a friendship model for users and want to retrieve all the posts > my friends made. > > class Friendship(models.Model): >  from_friend = models.ForeignKey( User, related_name='friend_set' ) >  to_friend = models.ForeignKey( User, related_name='to_friend_set'

Re: Django 1.0.2 Thread safety

2009-07-01 Thread Karen Tracey
On Wed, Jul 1, 2009 at 9:38 AM, Miles wrote: > > On Jun 30, 8:10 am, Thomas Guettler wrote: > > Hi, > > > > I hit this bug some time ago, too. If you run SVN 1.0.X you get the > > bug fixes for free. > > > > Thomas > > Yeah, but then you have to test your releases really carefully on each > sv

Re: serving a static file via nginx requiring authentication from django

2009-07-01 Thread Annie
See, I knew it was probably something simple that I'd missed because I'd been looking at this for too long. *g* I changed the PROTECTED_DIR to '/media/books/' to match what I had in my nginx.conf and changed the response['X-Accel-Redirect'] to filename in views.py and it works perfectly now. (I th

Django Search Form in Admin

2009-07-01 Thread Alessandro Ronchi
Given a simple model, I need to write a search form in admin (not the text search inside admin model list). It's the same as a form.as_table() but inside admin. Is it possible? Any working example? I also need to insert a button with a link to export the result queryset to Excel or PDF. (a sim

Re: Will future Django releases support multiple databases?

2009-07-01 Thread Emily Rodgers
On Jun 25, 6:45 pm, Alex Gaynor wrote: > On Thu, Jun 25, 2009 at 10:24 AM, Tim Chase > wrote: > > > Right now, Django doesn't seem to support the multiple > > > databases on the same server or different servers.  Will that > > > feature be available out of the box for future releases? > > > You

Re: Will future Django releases support multiple databases?

2009-07-01 Thread Alex Gaynor
On Wed, Jul 1, 2009 at 9:16 AM, Emily Rodgers < emily.kate.rodg...@googlemail.com> wrote: > > > > On Jun 25, 6:45 pm, Alex Gaynor wrote: > > On Thu, Jun 25, 2009 at 10:24 AM, Tim Chase > > wrote: > > > > Right now, Django doesn't seem to support the multiple > > > > databases on the same server o

dynamic settings through script

2009-07-01 Thread Michel Thadeu Sabchuk
Hi guys, I need to block access to my site during a time period, when a script is running and do some calculations. I want to avoid user interaction during this calculations, this is why I want to block access to the site when the script starts and liberate when the script ends. First of all, I

Re: Will future Django releases support multiple databases?

2009-07-01 Thread Emily Rodgers
On Jul 1, 3:22 pm, Alex Gaynor wrote: > On Wed, Jul 1, 2009 at 9:16 AM, Emily Rodgers < > > > > emily.kate.rodg...@googlemail.com> wrote: > > > On Jun 25, 6:45 pm, Alex Gaynor wrote: > > > On Thu, Jun 25, 2009 at 10:24 AM, Tim Chase > > > wrote: > > > > > Right now, Django doesn't seem to supp

Re: dynamic settings through script

2009-07-01 Thread TiNo
Wouldn't it be easier to create a 'lock-file'? Have your middelware check for the lock file, if it's present, block access, if not, do nothing. This is at least how some programs do their locks (Adobe Creative suite for example) and quite easy to implement. Tino On Wed, Jul 1, 2009 at 16:34, Mic

Re: Will future Django releases support multiple databases?

2009-07-01 Thread Alex Gaynor
On Wed, Jul 1, 2009 at 9:39 AM, Emily Rodgers < emily.kate.rodg...@googlemail.com> wrote: > > > > On Jul 1, 3:22 pm, Alex Gaynor wrote: > > On Wed, Jul 1, 2009 at 9:16 AM, Emily Rodgers < > > > > > > > > emily.kate.rodg...@googlemail.com> wrote: > > > > > On Jun 25, 6:45 pm, Alex Gaynor wrote: >

Re: issue with django.views.generic.date_based.archive_index's date_list

2009-07-01 Thread Seth Buntin
Karen, That makes total sense. I really missed the verbiage there. Thanks. On Jun 30, 10:34 pm, Karen Tracey wrote: > On Tue, Jun 30, 2009 at 1:55 PM, Seth Buntin wrote: > > > I'm having an issue with the date_based generic views archive_index. > > I am expecting the context to return a date

Re: Is IP address caching built into the Django Framework?

2009-07-01 Thread links_awakening
Thanks for sharing this knowledge. It sounds like my best option would be to cache IP addresses and use some sort of heuristics to detect odd voting patterns. On Jun 29, 7:26 am, James wrote: > On Jun 29, 8:13 am, Vladimir Shulyak wrote: > > > > You can't rely on just theIP. If you do then you

Re: Will future Django releases support multiple databases?

2009-07-01 Thread Emily Rodgers
On Jul 1, 3:44 pm, Alex Gaynor wrote: > On Wed, Jul 1, 2009 at 9:39 AM, Emily Rodgers < > > > > emily.kate.rodg...@googlemail.com> wrote: > > > On Jul 1, 3:22 pm, Alex Gaynor wrote: > > > On Wed, Jul 1, 2009 at 9:16 AM, Emily Rodgers < > > > > emily.kate.rodg...@googlemail.com> wrote: > > > >

Display Data From Multiple Tables

2009-07-01 Thread The Danny Bos
Hi there, Seems easy, but I'm having an ass of a time. I think once I wrap my head around how to do this, I'll be rolling through Django like it's building sprites on a Commodore 64. So, I have four tables. Book, Publisher, Author and Review. A classic scenario. I want to display a loop on the h

Re: Internationalization in django and search engine indexing

2009-07-01 Thread Miguel Rodriguez
cool. Glad to hear it solved your problem. On Jun 30, 12:07 pm, Olivier wrote: > I've integrated it and it seems to work fine. > If people are interested in an example of localeurl, you can > checkwww.spiderchallenge.com(just switch language at the bottom of the > sidebar) > We will see if goog

Re: postgres schemas and django admin

2009-07-01 Thread Miguel Rodriguez
and you have 'django.contrib.admin' under INSTALLED_APPS, right? On Jul 1, 6:58 am, Unnamed_Hero wrote: > > this only fails for admin? are the models being written to the database? > > Yes, it is. > I have a database already filled with data. For fetching data I > specify a class Meta with a db

Re: PyDev users: how do you manage tabs?

2009-07-01 Thread Steve Howell
On Jun 30, 10:42 pm, Rex wrote: > Kind of a petty question: > > I've been using PyDev to do my Django work and find it to be great. > However, my only gripe is that it's hard to keep track of tabs, since > they display only the (non-qualified) file name, which is a problem > given Django's very

Re: dynamic settings through script

2009-07-01 Thread Michel Thadeu Sabchuk
Hi Tino, > Wouldn't it be easier to create a 'lock-file'? Have your middelware check > for the lock file, if it's present, block access, if not, do nothing. You are right, a lock file is easier, thanks for pointing me at that. Anyway, I want to use the settings file instead of a lock file, supp

Re: PyDev users: how do you manage tabs?

2009-07-01 Thread Chris Lawlor
I have the same problem in Komodo Edit - although I the whole filename does show up in the window title I never think to look there. Anyway, I partially solved it by adding a comment at the top of the file for what app the file is for, so I'll see what I'm working on right there in the editor wind

How to write to the history

2009-07-01 Thread mettwoch
Hi group, What would be a good way to log changes made to models from outside the admin interface? Thanks for any hint Marc --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this grou

Re: PyDev users: how do you manage tabs?

2009-07-01 Thread AmanKow
> I have the same problem in Komodo Edit - although I the whole filename > does show up in the window title I never think to look there. Anyway, > I partially solved it by adding a comment at the top of the file for > what app the file is for, so I'll see what I'm working on right there > in the e

PostgreSQL 8.4 released

2009-07-01 Thread Joshua D. Drake
Hey folks, Thought I would let you know this little wonderful tidbit for the day. PostgreSQL 8.4 has been released. You can check out the release here: http://www.postgresql.org/about/news.1108 Joshua D. Drake -- PostgreSQL - XMPP: jdr...@jabber.postgresql.org Consulting, Development, Suppo

How to set up site admin page for my application

2009-07-01 Thread Damudar
Hi All, I am trying to setup admin page for one of my application. I have followed the following instruction from the Django admin site document. *) Set up page for gnats-admins to manage SitePrefs values. http://docs.djangoproject.com/en/dev/ref/contrib/admin/#ref-contrib-admin 1. settings.

Re: postgres schemas and django admin

2009-07-01 Thread Unnamed_Hero
> and you have 'django.contrib.admin' under INSTALLED_APPS, right? Yes, I have. I've also tried http://code.djangoproject.com/ticket/1051 and patch django/db/backends/postgresql_psycopg2/base.py with code in http://code.djangoproject.com/attachment/ticket/1051/ticket_1051_rev6669.diff but I'm g

Re: Display Data From Multiple Tables

2009-07-01 Thread TiNo
On Wed, Jul 1, 2009 at 16:59, The Danny Bos wrote: > > Hi there, > > Seems easy, but I'm having an ass of a time. I think once I wrap my > head around how to do this, I'll be rolling through Django like it's > building sprites on a Commodore 64. > > So, I have four tables. Book, Publisher, Author

How to code for multiple sub-types of a model

2009-07-01 Thread Daniele Procida
I need to create a set of models to capture people's roles in an institution. Every person is a Person, with a name, contact details, a member of one or more departments, and so on. Some people are also Researchers, and/or Lecturers, Students and so on (there could be other categories that haven

Disabling admin pagination.

2009-07-01 Thread kurak
Hello, I'd like to add another button "show all" after pagination numbers, so I could optionally show all records on one page. Is there any way to do this without patching django? Thanks, K --~--~-~--~~~---~--~~ You received this message because you are subscribed

Re: How to code for multiple sub-types of a model

2009-07-01 Thread Randy Barlow
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Daniele Procida declared: > Which of these is a more satisfactory solution? Is there another way? Hey Daniele, I have a third suggestion for you that I think is best suited for your problem, and this is the way we do it in our product. Create a Group

Re: How to write to the history

2009-07-01 Thread Rajesh D
On Jul 1, 12:10 pm, mettwoch wrote: > Hi group, > > What would be a good way to log changes made to models from outside > the admin interface? Look at the log_* methods in the Admin implementation: http://code.djangoproject.com/browser/django/trunk/django/contrib/admin/options.py#L377 You cou

Re: file extensions for templates

2009-07-01 Thread Rajesh D
On Jul 1, 8:30 am, David De La Harpe Golden wrote: > Hi, > > As far as I can see, django shouldn't care in the slightest about > template file name extensions, but being a django newbie, I could have > missed something (e.g. autosetting of a mime type somewhere based on > extension), so just to

Re: How to filter out posts from friends?

2009-07-01 Thread Rajesh D
On Jul 1, 9:50 am, Mathieu Leplatre wrote: > On 1 juil, 14:44, coan wrote: > > > > > > > I have a friendship model for users and want to retrieve all the posts > > my friends made. > > > class Friendship(models.Model): > >  from_friend = models.ForeignKey( User, related_name='friend_set' ) > >

No css in Admin

2009-07-01 Thread Some Guy
Hi Group, I've look all over to find the answer but am now posting out of desperation :) I have a dev and prod server (apache2, mod_python) on the production server the css and js for the admin site does not work. (except for the login page) The images show up but no css styles are applied. Als

Re: Using a dynamically created ImageField filename prior to save?

2009-07-01 Thread Rajesh D
> > > This is an issue which, I believe, is related to Ticket #10788 > > (http://code.djangoproject.com/ticket/10788). > > > The following code snippet used to work with Django 1.0.2, but with > > the latest svn version the slug is not being set to the filename > > produced by get_path because, as

Re: How to filter out posts from friends?

2009-07-01 Thread Daniel Roseman
On Jul 1, 8:59 pm, Rajesh D wrote: > On Jul 1, 9:50 am, Mathieu Leplatre wrote: > > On 1 juil, 14:44, coan wrote: > > > > I have a friendship model for users and want to retrieve all the posts > > > my friends made. > > > > class Friendship(models.Model): > > >  from_friend = models.ForeignKey(

Re: No css in Admin

2009-07-01 Thread Xavier Ordoquy
On Wed, 2009-07-01 at 13:01 -0700, Some Guy wrote: > Hi Group, > I've look all over to find the answer but am now posting out of > desperation :) > > I have a dev and prod server (apache2, mod_python) > > on the production server the css and js for the admin site does not > work. (except for the

ForeignKey within GenericForeignKey

2009-07-01 Thread PiGGeH
I'm pretty sure its not necessarily meant to work like this, however one way it does, the other it doesnt. I have the following (cut down slightly, but the important stuff is here) # image/models.py class Image(models.Model): type = models.ForeignKey('image.Type') object_id = models.Posi

Re: How to filter out posts from friends?

2009-07-01 Thread Rajesh D
On Jul 1, 4:35 pm, Daniel Roseman wrote: > On Jul 1, 8:59 pm, Rajesh D wrote: > > > > > > > On Jul 1, 9:50 am, Mathieu Leplatre wrote: > > > On 1 juil, 14:44, coan wrote: > > > > > I have a friendship model for users and want to retrieve all the posts > > > > my friends made. > > > > > class

Re: sorting different in postgres than in sqlite

2009-07-01 Thread J
Coalesce() worked in postgres as well. Thank you. On Jun 30, 10:34 pm, J wrote: > Thank you Tim, that worked perfectly in sqlite, and I imagine it will > work well inpostgresas well. My server is down right now, so I can't > say for sure, but I will definitely try this out. > > Thanks again, >

Re: No css in Admin

2009-07-01 Thread Some Guy
Found the problem. I was overriding change_list.html and somehow base.css is not being included. I manually linked it into my base.html and it works now. I was seeing change_list.css, or whatever, and thought that was all that was needed. On Jul 1, 1:46 pm, Xavier Ordoquy wrote: > On Wed,

django memcached errors

2009-07-01 Thread Aaron Lee
Lately I have been seeing the following errors from memcached [fa...@1246486554.949771] mcm_get_line():1542: memcache(4) protocol error: no \r before \n [fa...@1246486554.949771] mcm_get_line():1542: memcache(4) protocol error: no \r before \n [fa...@1246486554.949771] mcm_fetch_cmd():1154: memcach

Django Sessions / Multidimensional List

2009-07-01 Thread bjoern_mainz
Hi, what i try do do is (in plain python): products = [] products.append({"product" : "foo","quantity": 5}) products.append({"product": "foz","quantity": 1}) ---Django--- def add_to_basket(request): if not 'products' in request.session: request.session['product

Re: changing apache mod python

2009-07-01 Thread Aaron Maxwell
Hm. It involves this module Deportista. I haven't heard of it, so I'm assuming it's either a third-party library you are using, or one a module made in house. You might try this: (assuming unixy environment) 1) At a shell prompt, set PYTHONPATH to the value you included in the attached erro

Django + user profile admin inlines = breakage

2009-07-01 Thread hagan
I'm using python 2.6.2, django 1.1-beta-1 with mod_wsgi 2.5 So this very well could be a beta bug... I'm having a strange problem, which I've tracked down to my UserProfile model... well, the admin interface. Basically I'm trying to do something like this (Simplified from working model)

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Hongyu Li
Thanks for your comment. What was you do when want add a global memory cache in your app with django? On Wed, Jul 1, 2009 at 8:08 PM, Graham Dumpleton wrote: > > > > On Jul 1, 7:22 pm, Hongyu Li wrote: > > #!/usr/bin/env python > > # -*- coding: utf-8 -*- > > import xmlrpclib > > import os

Getting the name of a matched URL pattern

2009-07-01 Thread Nick Fishman
Hey everyone, I'm working with Django's named URL patterns, and was wondering how to fetch the name of the URL pattern that triggered the view. For example, with the following urlpatterns urlpatterns = patterns('', url(r'^archive/(\d{4})/$', archive, name="full-archive"), url(r'^archive-

Tracking a bad import

2009-07-01 Thread goodwinb
I am setting up a server and when I run manage.py syncdb I get the error 'cannot import name pre_delete'. How can I get more trace information about where the bad pre_delete is? Python 2.6; Django 1.1-beta; using comments, markdown, statlib --~--~-~--~~~---~--~~

Re: Tracking a bad import

2009-07-01 Thread Chhouk Voeun
Page not found (404) Request Method: GET Request URL: http://localhost:8080/main/ Using the URLconf defined in pollango.urls, Django tried these URL patterns, in this order: 1. ^$ 2. ^create/$ 3. ^poll/(?P[^\.^/]+)/$ 4. ^poll/(?P[^\.^/]+)/results/$ The current URL, /main/, didn't

Re: postgres schemas and django admin

2009-07-01 Thread Unnamed_Hero
So, I think I found a solution. But, in http://code.djangoproject.com/attachment/ticket/1051/ticket_1051_rev6669.diff I've changed a string "cursor.execute("SET search_path TO %s" % ','.join (settings.DATABASE_SCHEMAS)) " to "cursor.execute("SET search_path TO %s" ,[settings.DATABASE_SCHEMAS]) "

Re: postgres schemas and django admin

2009-07-01 Thread Chhouk Voeun
Page not found (404) Request Method: GET Request URL: http://localhost:8080/main Using the URLconf defined in urls, Django tried these URL patterns, in this order: 1. ^$ 2. ^new$ 3. ^edit/(\d+)$ The current URL, /main, didn't match any of these. You're seeing this error because you h

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Graham Dumpleton
Presumably use memcache. On Jul 2, 12:09 pm, Hongyu Li wrote: > Thanks for your comment. > What was you do when want add a global memory cache in your app with django? > > On Wed, Jul 1, 2009 at 8:08 PM, Graham Dumpleton > > > > > > wrote: > > > On Jul 1, 7:22 pm, Hongyu Li wrote: > > > #!/usr

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Chhouk Voeun
no i use window --~--~-~--~~~---~--~~ 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 unsubscribe from this group, send email to django-users+unsu

Re: Tracking a bad import

2009-07-01 Thread goodwinb
Fixed it by reinstalling all of my packages. On Jul 1, 8:48 pm, goodwinb wrote: > I am setting up a server and when I run manage.py syncdb I get the > error 'cannot import name pre_delete'.  How can I get more trace > information about where the bad pre_delete is? > > Python 2.6; Django 1.1-beta

Re: Tracking a bad import

2009-07-01 Thread Chhouk Voeun
i use window and i can start page .the sample code follow:# Copyright 2008 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licen

Re: Tracking a bad import

2009-07-01 Thread Chhouk Voeun
i want to use map url (http:\\localhost:8080\main).oh i use window --~--~-~--~~~---~--~~ 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 unsubscrib

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Graham Dumpleton
On Jul 2, 2:00 pm, Chhouk Voeun wrote: > no i use window If this reply was truly about original caching issues with multiprocess Apache, take note that it was said that it was a UNIX platform issue. On Windows there is only one process, so it is not a problem and you can use normal in process ca

Re: Getting the name of a matched URL pattern

2009-07-01 Thread greatlemer
On Jul 1, 9:56 pm, Nick Fishman wrote: > Hey everyone, > > I'm working with Django's named URL patterns, and was wondering how to > fetch the name of the URL pattern that triggered the view. For > example, with the following urlpatterns > > urlpatterns = patterns('', >     url(r'^archive/(\d{4})/

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Hongyu Li
what about run django on lighttpd, ls it a multi process server too, or ? On Thu, Jul 2, 2009 at 11:55 AM, Graham Dumpleton < graham.dumple...@gmail.com> wrote: > > Presumably use memcache. > > On Jul 2, 12:09 pm, Hongyu Li wrote: > > Thanks for your comment. > > What was you do when want add a

Re: django cache framework not work well on mod_python of apache

2009-07-01 Thread Graham Dumpleton
If you mean fastcgi, it really depends on how you configure it. If you want a way that guarantees a single process, then use mod_wsgi and its daemon mode, ensuring you configure it to delegate Django to one daemon process. Graham On Jul 2, 4:04 pm, Hongyu Li wrote: > what about run django on l