Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread Russell Keith-Magee
On 7/17/07, Manoj Govindan <[EMAIL PROTECTED]> wrote: > > > If there are times that you don't want to load the data, then it isn't > > initial data. Put it in a different fixture, and load it when you need > > it. > > I am bit confused now. Are you implying that the developer should not > prepare

model managers of base classes

2007-07-17 Thread omat
Hi all, I have a base class common for all my orthogonal models, that is, models that hold content for other models, such as tags. This base class also has a manager. Here are the classes: class OrthoManager(models.Manager): def get_for_object(self, object): ctype = ContentType.obje

Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread Manoj Govindan
> You think. For the moment. Until one day, something subtle changes in > the implementation of get_foobar() which _does_ change data, and the > change is made by someone that didn't get the memo from 2 years ago > that said that the app must not change data, etc ... 1) I am the sole developer 2)

Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread Manoj Govindan
> This is because Django's test case flushes the database between each > test. This is the right thing to do for testing purposes, because it > removes the possibility of crossover effects in the testing process, > but it does impose a slowdown (because flushing is an expensive > operation). > I

Django serving static PDF file

2007-07-17 Thread Arnold Chen
Can any one please tell me how to serve a static PDF in django ? The file is located in the server, and do not need to be created on the fly (by using report lab). I have done it in PHP by using header, but i just don't know how to do it with django. Thanks --~--~-~--~~~-

Re: Django serving static PDF file

2007-07-17 Thread Ben van Staveren
You're better off not doing it with Django, just make a directory that won't be handled by Django and stick all your static content in there. After all, the webserver is usually better at serving static files than Django is :) On 17/07/2007, at 2:26 PM, Arnold Chen wrote: > > Can any one

Django ORM is very cool.

2007-07-17 Thread james_027
hi, i just starting to read http://www.djangoproject.com/documentation/model-api/ http://www.djangoproject.com/documentation/db-api/ I have some experience with other ORM, I think django's orm is really cool. Here are the things that I like that really makes Django's ORM a clean design. manage

anybody help me! raise EnvironmentError

2007-07-17 Thread [EMAIL PROTECTED]
from django import forms #import newforms as forms File "D:\Python25\Lib\site-packages\django\forms\__init__.py", line 1, in from django.oldforms import * File "D:\Python25\Lib\site-packages\django\oldforms\__init__.py", line 1, in from django.core import validators File "D:\Pyt

Re: Django serving static PDF file

2007-07-17 Thread Arnold Chen
Thanks Ben, Besides, i've found that www.lawrence.com and www.ljworld.com (which are famous sites that use django) use a http://media.their-domain-name.com to store the media files. All static files, images, css are from the http://media.their-domain-name.com server. Obviously the media subdomain

Re: Django serving static PDF file

2007-07-17 Thread Arnold Chen
Besides, i want to revise my first question as: How to serve static file by "pushing" a PDF to client? In php, there is a way to serve PDF by pushing the file to the client, and client to choose "Save As" or "Open" the file directly. Adobe reader is very slow if they run in browsers, and most of

Re: Django serving static PDF file

2007-07-17 Thread Ben van Staveren
Generally that's done by spitting out some custom headers; Content-Type: text/pdf Content-Disposition: attachment; filename=yourfilename.pdf That way most browsers will give you the option to open or to save- as. To do that does require that they're sent dynamically, but as said before it'd b

Re: Django serving static PDF file

2007-07-17 Thread Sam
import urllib from django.http import HttpResponse def output_file(request, file, mimetype): f = urllib.urlopen(file) data = f.read() f.close() return HttpResponse(data, mimetype=mimetype) It is better to serve from static environments but sometimes, you want to check user righ

default behavior of django.middleware.transaction.TransactionMiddleware

2007-07-17 Thread james_027
hi, If I use django.middleware.transaction.TransactionMiddleware, is @transaction.commit_on_success the default behavior? or I should always call on the python decorators? Thanks james --~--~-~--~~~---~--~~ You received this message because you are subscribed to

Fetching sub-objects with extra(select={})?

2007-07-17 Thread jj
It's easy to fetch extra object attributes with extra(select={...}). But how can I obtain extra sub-objects (easily, without resorting to custom SQL)? I'd like to be able to do something like the following, but obviously this doesn't work: extra(select={'country': 'SELECT book_country.name,

Re: Fetching sub-objects with extra(select={})?

2007-07-17 Thread Malcolm Tredinnick
On Tue, 2007-07-17 at 01:59 -0700, jj wrote: > It's easy to fetch extra object attributes with extra(select={...}). > > But how can I obtain extra sub-objects (easily, without resorting to > custom SQL)? > > I'd like to be able to do something like the following, but obviously > this doesn't wor

regroup changing the list it is grouping on?

2007-07-17 Thread jj
Could {% regroup %} have an unwanted side effect on the list is to grouping on, when the list is a queryset? I use the template below. When: book_list = list(query) the template works fine. When: book_list = query the template chokes on {% some_custom_tag project_list %}. The debugger sh

regroup changing the list it is grouping on?

2007-07-17 Thread jj
Could {% regroup %} have an unwanted side effect on the list is to grouping on, when the list is a queryset? I use the template below. When: book_list = list(query) the template works fine. When: book_list = query the template chokes on {% some_custom_tag project_list %}. The debugger sh

Re: Fetching sub-objects with extra(select={})?

2007-07-17 Thread jj
Thanks Malcom. Will your rewrite make it possible to easily fetch ForeignKey(null=True) and M2M sub-objects? That would solve my (performance) problem. JJ. On Jul 17, 11:07 am, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Tue, 2007-07-17 at 01:59 -0700, jj wrote: > > It's easy to fetch ext

Blog engine

2007-07-17 Thread Eratothene
Please, recommend me some full featured blog engines developed in django. Though, I have found some posts in this user group about available blog engines, I still want to ask this question, as all posts are dated summer 2006. --~--~-~--~~~---~--~~ You received th

Re: Fetching sub-objects with extra(select={})?

2007-07-17 Thread Malcolm Tredinnick
On Tue, 2007-07-17 at 02:11 -0700, jj wrote: > Thanks Malcom. Will your rewrite make it possible to easily fetch > ForeignKey(null=True) and M2M sub-objects? That would solve my > (performance) problem. If by ForeignKey(null=True), you mean all objects that don't have any related objects attached

Re: Getting debug with apache and mod_python

2007-07-17 Thread Alessandro Ronchi
On 13 Lug, 15:24, "Alessandro Ronchi" <[EMAIL PROTECTED]> wrote: > With apache and mod_python, and this configuration: I've changed my configuration as follows. I get an 500 error but nothing goes to apache error.log, and I don't know what's the problem. How can I solve that? ServerN

Re: saving many2many relations

2007-07-17 Thread zenx
Thank you Rajesh, I didn't knew that. I will try your solution. Thanks! On 11 jul, 23:16, RajeshD <[EMAIL PROTECTED]> wrote: > Hi, > > > Anyone knows where the problem is? > > If you are using the Admin app to populate tags then the automatic > manipulators first call Receta.save() followed by

Re: Fetching sub-objects with extra(select={})?

2007-07-17 Thread jj
What I mean is: 1. fetching sub-objects which are declared as ForeignKey(null=True). ForeignKey(null=False) sub-objects are already fetched by select_related(). 2. fetching sub-objects declared as ManyToManyField() in a principal object. These objects are not fetched by select_related(). One ofte

Re: Blog engine

2007-07-17 Thread David Reynolds
Hi, On 17 Jul 2007, at 10:15 am, Eratothene wrote: Please, recommend me some full featured blog engines developed in django. Though, I have found some posts in this user group about available blog engines, I still want to ask this question, as all posts are dated summer 2006. I don't see wh

AD / LDAP authentification backend

2007-07-17 Thread Tilo Kussatz
Hi all, I'd like to get Django to authenticate against an active directory LDAP server. Does the AD part of it introduce any specialties, or would Django be able to access it just like it accesses a normal LDAP server through the python-ldap module? Has this been done already? If any of you ha

Re: AD / LDAP authentification backend

2007-07-17 Thread Alberto Paro
Il giorno mar, 17/07/2007 alle 10.02 +, Tilo Kussatz ha scritto: > Hi all, > > I'd like to get Django to authenticate against an active directory > LDAP server. > > Has this been done already? > > If any of you had some details on this or code samples to share that > would be great. > I u

Re: Getting debug with apache and mod_python

2007-07-17 Thread Chris Hoeppner
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Alessandro Ronchi escribió: > > > On 13 Lug, 15:24, "Alessandro Ronchi" <[EMAIL PROTECTED]> > wrote: >> With apache and mod_python, and this configuration: > > I've changed my configuration as follows. I get an 500 error but > nothing goes to apach

Re: Blog engine

2007-07-17 Thread Eratothene
There a lot of other features missing in such solution: comments, spam protection, rss feeds and a lot more. I am searching for full featured blog engine. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django user

Re: Blog engine

2007-07-17 Thread David Reynolds
On 17 Jul 2007, at 11:37 am, Eratothene wrote: There a lot of other features missing in such solution: comments, spam protection, rss feeds and a lot more. I am searching for full featured blog engine. Django has it's own comment feature in contrib which with James Bennett's comment-utils

Re: Django ORM is very cool.

2007-07-17 Thread Russell Keith-Magee
On 7/17/07, james_027 <[EMAIL PROTECTED]> wrote: > > Is there any plan to make Django ORM available as a stand alone ORM > which can be use in other application development. This could increase > django's user can they can use the model with several application > interface besides the web interfac

Greenpeace Source Code

2007-07-17 Thread FrostedDark
Does anyone have the Greenpeace source code... their svn server has been down for over a week now and I would love to take a look at it. Thanks! Eric --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" g

Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread simonbun
I'm a bit plagued by slow running tests as well, but i'm using an acceptable workaround (for my uses). This workaround assumes that you run your tests per app and that you only need to test a newly created test case. The idea is to use your keyboard interrupt to stop the test suite after your new

Re: regex in url

2007-07-17 Thread Ned Batchelder
For a quick answer: (?Pxxx) means: "match xxx, and store it as a value named blah in the result". This lets the regex machinery build a set of name/value pairs suitable for use as arguments to a view function. --Ned. james_027 wrote: > hi kenneth, > > thanks a lot, i think should be looking

HOLİDAY http://aliozturk.blogcu.com/3617613/

2007-07-17 Thread ali öztürk
20/6/2007: Maldives Holidays http://aliozturk.blogcu.com/3617613/ 20/6/2007: Boston Holidays The Cradle Of Modern America 20/6/2007: Atlanta Holidays 20/6/2007: New York, New York -

Re: model managers of base classes

2007-07-17 Thread Nis Jørgensen
omat skrev: > Hi all, > > I have a base class common for all my orthogonal models, that is, > models that hold content for other models, such as tags. This base > class also has a manager. Here are the classes: > > > class OrthoManager(models.Manager): > def get_for_object(self, object): >

Re: model managers of base classes

2007-07-17 Thread omat
Thanks for the pointer, Nis. Model inheritance made my models so much DRYer that it will be hard to give up, at least psychologically... And, except for the managers, it worked just as I would expect, and for the managers, it was easy to patch. Maybe I should further test them, or just give up

Re: Greenpeace Source Code

2007-07-17 Thread Nis Jørgensen
FrostedDark skrev: > Does anyone have the Greenpeace source code... their svn server has > been down for over a week now and I would love to take a look at it. > It has moved here: https://svn4.cvsdude.com/greenpeace/custard Yours Nis Jørgensen Currently doing other Django work for Greenpeace

Re: is there any host servers that supports Django based sites?

2007-07-17 Thread scadink
Yes, you can run a Django based site on a host provider that supports Python, but doesn't have Django installed (as long as they support FCGI or mod_python). Frankly, you'd be hard pressed to find any unix (including Linux) based web host that doesn't have Python installed. Python is a default co

Re: model managers of base classes

2007-07-17 Thread Nis Jørgensen
omat skrev: > Thanks for the pointer, Nis. > > Model inheritance made my models so much DRYer that it will be hard to > give up, at least psychologically... > > And, except for the managers, it worked just as I would expect, and > for the managers, it was easy to patch. > Just to make sure I u

Re: Unique=true

2007-07-17 Thread Nis Jørgensen
[EMAIL PROTECTED] skrev: > OK, fixed the above problem -- figured out that it was related to my > setting unique=True on a field. But that raises the larger question... > > I have a bit of data that may or may not exist... a identifier on the > user that not all users will have, but if they DO hav

Re: regex in url

2007-07-17 Thread Jacob Kaplan-Moss
On 7/16/07, james_027 <[EMAIL PROTECTED]> wrote: > Yes I am looking for the explanation of ?P syntax, is this > something related to python's regex or django's own regex. Ned's quick answer below is quite clear, I think, but if you'd like more details from the horse's mouth (as it were), the offi

Re: model managers of base classes

2007-07-17 Thread Carl Karsten
Nis Jørgensen wrote: > omat skrev: >> Thanks for the pointer, Nis. >> >> Model inheritance made my models so much DRYer that it will be hard to >> give up, at least psychologically... >> >> And, except for the managers, it worked just as I would expect, and >> for the managers, it was easy to patc

Re: is there any host servers that supports Django based sites?

2007-07-17 Thread Tim Chase
> Frankly, you'd be hard pressed to find any unix (including > Linux) based web host that doesn't have Python installed. > Python is a default component of every Linux distribution I've > ever used. Though to add to this, I have used hosting services that still used Python 2.2 (or earlier) and II

Re: Blog engine

2007-07-17 Thread Chris Moffitt
It's definitely a good idea to roll your own but it is helpful to see other code to help you out. I'm in the process of adding a blog to satchmo and have uploaded the code to svn but have not put it into production. As it stands now, the code works but does not have comments enabled yet. If noth

Re: model managers of base classes

2007-07-17 Thread omat
Sorry for the terminological confusion. The "model" is the django.db.models.Model() class, the "manager" is the django.db.models.Manager() class. Yes Nis, the behaviors you listed are the most important ones. It would be nice to have Meta, Admin, etc. inherited as well but, it is not a priority.

Re: is there any host servers that supports Django based sites?

2007-07-17 Thread Chris Hoeppner
Tim Chase escribió: >> Frankly, you'd be hard pressed to find any unix (including >> Linux) based web host that doesn't have Python installed. >> Python is a default component of every Linux distribution I've >> ever used. > > Though to add to this, I have used hosting services that still > used P

Get paid to click and read email

2007-07-17 Thread newbar
Get paid to click and read email o. Get Paid To Click o. Get Paid To Read E-Mail o. Get Paid To Sign-Up o. $5.- Sign-Up Bonus o. 10 Referral Levels o. Low Pay-Out Minimum o. Leads and Sales http://www.cash-dreams.biz --~--~-~--~~~---~--~~ You received this messa

Re: SQL VIEWs as Django Models for aggregation --- delete() issues with django.db.models.query: delete_objects

2007-07-17 Thread JeffH
> > 3. That said, my delete_objects() hack was an attempt to solve the > > more general problem of using an overridden delete() without any > > special flags while allowing for the possibility of model subclassing > > in the future, because it seemed that respecting an overridden > > delete() was

Data truncated error

2007-07-17 Thread Seth Buntin
I am getting a Data truncated error and I don't know if it is because of the data I am inserting into the DB or what. I am putting this in a TextField and here is the message I am getting: Warning at /admin/cabedge_silo/page/2/ Data truncated for column 'bodytext' at row 1 Request Method:

Re: model managers of base classes

2007-07-17 Thread omat
As I further test the pythonic inheritance for models, I figure out that some django model magic does not work. For example, instead of "get_object_or_404" you should do: try: object = ObjectClass.objects.get(pk=1) except: raise Http404 On 17 Temmuz, 18:01, omat <[EMAIL PROTECTED]> wrot

Hi friends see my webpage and open the weblinks in that page it consists of 1.latest antivirussoftware 2.library softwares 3.software projects 4.software cracks 5.download accelerator plus 6.

2007-07-17 Thread [EMAIL PROTECTED]
Hi friends see my webpage and open the weblinks in that page it consists of 1.latest antivirussoftware 2.library softwares 3.software projects 4.software cracks 5.download accelerator plus 6.mobile themes 7.mobile softwares(for nokia,samsung,sonyericsson) 8.mobile videos(.3gp) 9...ALL SOFT

Re: objects.filter

2007-07-17 Thread [EMAIL PROTECTED]
thinks man it worked. --~--~-~--~~~---~--~~ 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 [EMAIL PRO

get_admin_app_list giving differents results from shell or web

2007-07-17 Thread didier Belot
Hello, Hope to be clear enough... Using the django-comment-utils, I have an issue where models using moderator disappears in django admin index. Trying to track this down from shell, I can't reproduce it for now, only the web view miss the module. Here is the simple script I've used so far, w

Re: model managers of base classes

2007-07-17 Thread Carl Karsten
Thanks - I think I bumped into that yesterday and got distracted trying to setup a test on a win box (yay) I was getting a 500, you too right? Carl K omat wrote: > As I further test the pythonic inheritance for models, I figure out > that some django model magic does not work. For example, in

How to select objects referenced by another table ?

2007-07-17 Thread Jonathan Ballet
Hello, I want to create a QuerySet object which select objects from a table which a referenced by another table, but I can't find how to do that. Here is an example : class Article(models.Model): [...] class Photo(models.Model): article = models.ForeignKey(Article)

Re: Django on a shared host. The docs are scaring me ;)

2007-07-17 Thread gordyt
Andy here are my notes for setting up Django with Dreamhost using FastCGI: http://www.gordontillman.info/Development/DjangoDreamhost --gordy --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To

Re: How to select objects referenced by another table ?

2007-07-17 Thread Tim Chase
> What I want is "every articles which have at least one photo" > (and the possibility to add more filter after that, > eventually). > > > Currently, I'm using something like : > > Article.objects.filter(photos__in=Photo.objects.all()) > > but this is horribly inefficient, since there is m

Re: How to select objects referenced by another table ?

2007-07-17 Thread Tim Chase
> Fortunately, Django's ORM lets you get at the underlying SQL via > a call to .extra() where you can provide your own WHERE clause. > This would look something like > >Article.objects.extra(where=""" > app_article.id in (select article_id from app_photo) > """) Whoops...forgot

Re: Django on a shared host. The docs are scaring me ;)

2007-07-17 Thread KpoH
great! gordyt пишет: > Andy here are my notes for setting up Django with Dreamhost using > FastCGI: > > http://www.gordontillman.info/Development/DjangoDreamhost > > --gordy > -- Artiom Diomin, Development Dep, "Comunicatii Libere" S.R.L. http://www.asterisksupport.ru http://www.asterisk-sup

The model doesn't check for valid data

2007-07-17 Thread Mohammad Tayseer
I was reading this article http://discuss.joelonsoftware.com/default.asp?joel.3.309321.4 and I really liked that django doesn't have any of the reasons the author has mentioned, except no. 4 > 4. RAILS ATE MY DATA, OR AT LEAST STOOD IDLY BY WHILE MY \ > DATA WAS EATEN I tried to check how django

Re: Data truncated error

2007-07-17 Thread Tim Chase
> Data truncated for column 'bodytext' at row 1 It would help to have the definition of your bodytext field...especially data limits on it (such as if it's a CharField with a max-length) -tkc --~--~-~--~~~---~--~~ You received this message because you are s

Re: The model doesn't check for valid data

2007-07-17 Thread James Bennett
On 7/17/07, Mohammad Tayseer <[EMAIL PROTECTED]> wrote: > Shouldn't these be done at the "save" method? Django shouldn't depend on the > DBMS do these checks, because some fields cannot be represented by the > underlying DB You'll want to search the archives of this and the developers' list for "

Problem installing django on dreadhost

2007-07-17 Thread walterbyrd
I am trying to follow Jeff Croft's tutorial: http://www2.jeffcroft.com/blog/2006/may/11/django-dreamhost/ One difference, I'm trying to install with sqlite3, instead of mysql. I was doing okay, I think, until this step: 3. Syncronize your Django database with the changes you've made in the se

MEDIA_URL MEDIA_ROOT problem.

2007-07-17 Thread Dmitriy Sodrianov
Hello everyone! Let me ask for help with the following problem: I want to attach css file to my template and I'm doing it in this steps. 1) First edited setting.py file, MEDIA_URL and MEDIA_ROOT variables in this way: MEDIA_ROOT = '/home/sodrian/versatility/static/' MEDIA_URL = 'http://127.0.

Re: model managers of base classes

2007-07-17 Thread omat
My previous message did not appear for about an hour, so I am re- posting... Sorry for the terminological confusion. The "model" is the django.db.models.Model() class, the "manager" is the django.db.models.Manager() class. Yes Nis, the behaviors you listed are the most important ones. It would

Re: MEDIA_URL MEDIA_ROOT problem.

2007-07-17 Thread Martin Kaffanke
Am Dienstag, den 17.07.2007, 18:35 + schrieb Dmitriy Sodrianov: > MEDIA_ROOT = '/home/sodrian/versatility/static/' > > MEDIA_URL = 'http://127.0.0.1:8000/static/' In this case /static/ is handled by django, so you need to set it in your urls.py: (r'^static/(?P.*)$', 'django.views.static.ser

Re: Django on a shared host. The docs are scaring me ;)

2007-07-17 Thread [EMAIL PROTECTED]
You could do what I did decide Dreamhost is unacceptable for hosting anything but a very, very small Django site, and go over to Webfaction. It's still shared, but it's far more robust, and they both know and understand what you want. Plus, django comes installed. On Jul 17, 1:00 pm, KpoH <[

Re: HttpResponseRedirect and IE6

2007-07-17 Thread Bob Dively
On Jul 16, 10:23 am, Bob Dively <[EMAIL PROTECTED]> wrote: > I have some suspicion that an Apache misconfiguration is at fault as When I set Apache's MaxRequestsPerChild to 0 (as it should be for production environments), this issue seems to go away. That doesn't make it less of a PITA in my dev

Re: HttpResponseRedirect and IE6

2007-07-17 Thread Bob Dively
On Jul 16, 10:23 am, Bob Dively <[EMAIL PROTECTED]> wrote: > I have some suspicion that an Apache misconfiguration is at fault as This problem appears to have been fixed by setting Apache's MaxRequestsPerChild setting back to 0. Of course, that's no good for development purposes, but at least I'

Re: Data truncated error

2007-07-17 Thread Seth Buntin
I figured it out, sorry. I had an hidden character somewhere. I just retyped it instead of copy/paste and everything is fine. Seth On Jul 17, 11:29 am, Seth Buntin <[EMAIL PROTECTED]> wrote: > I am getting a Data truncated error and I don't know if it is because > of the data I am inserting int

Re: anybody help me! raise EnvironmentError

2007-07-17 Thread Collin Grady
If you don't use "manage.py shell" you must set your environment properly - set the DJANGO_SETTINGS_MODULE and PYTHONPATH properly, similar to how the modpython docs show you to set them for that to work. --~--~-~--~~~---~--~~ You received this message because you

Re: Problem installing django on dreadhost

2007-07-17 Thread Collin Grady
Check your DATABASE_HOST setting in settings.py - if you have it set to a path you can't write to, that would explain the error. Also, you should be using "manage.py syncdb" not "django-admin.py syncdb" --~--~-~--~~~---~--~~ You received this message because you

www.cerocom.com

2007-07-17 Thread Natalia
.. www.cerocom.com .. You will be able to ask yourself: Is Internet a good investment for my company? So that an investment would have to do I of this type? Really is going to serve to me to have a Web site? So that to be i

Re: MEDIA_URL MEDIA_ROOT problem.

2007-07-17 Thread Collin Grady
The key here is that django does not automatically map your media - you have to do it manually. --~--~-~--~~~---~--~~ 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

Re: AD / LDAP authentification backend

2007-07-17 Thread Marc Fargas
Hi, Maybe you want to take a look at ticket #2507 ( http://code.djangoproject.com/ticket/2507 ) it's just about this. Far from complete but usable for normal scenarios. It works fine with AD. Cheers, Marc El mar, 17-07-2007 a las 10:02 +, Tilo Kussatz escribió: > Hi all, > > I'd like to get

mod_python setup instructions

2007-07-17 Thread peyman
The mod_python instructions at http://www.djangoproject.com/documentation/modpython/ seems incomplete. I followed the tutorial, but I had to add 2 paths to my Apache config before the mysite sample would work: the project directory and it's parent. Or am I missing something? SetHandler py

Re: Greenpeace Source Code

2007-07-17 Thread FrostedDark
Thanks! On Jul 17, 5:37 am, Nis Jørgensen <[EMAIL PROTECTED]> wrote: > FrostedDark skrev:> Does anyone have the Greenpeace source code... their svn > server has > > been down for over a week now and I would love to take a look at it. > > It has moved here: > > https://svn4.cvsdude.com/greenpeace

Re: mod_python setup instructions

2007-07-17 Thread Christian Hoeppner
peyman escribió: > The mod_python instructions at > http://www.djangoproject.com/documentation/modpython/ > seems incomplete. I followed the tutorial, but I had to add 2 paths to > my Apache config before the mysite sample would work: the project > directory and it's parent. Or am I missing someth

ANN: DMigrate - A Django Database Migration Tool

2007-07-17 Thread Noam Raphael
Hello, I'm happy to let you know about DMigrate. DMigrate is a simple tool which lets you migrate Django databases easily. With DMigrate: * You don't have to use any SQL. * You don't need to learn any command for changing database structure. * You can do whatever transformations you like. * Y

Re: mod_python setup instructions

2007-07-17 Thread Graham Dumpleton
On Jul 18, 8:19 am, peyman <[EMAIL PROTECTED]> wrote: > The mod_python instructions > athttp://www.djangoproject.com/documentation/modpython/ > seems incomplete. I followed the tutorial, but I had to add 2 paths to > my Apache config before the mysite sample would work: the project > directory an

Missing packages

2007-07-17 Thread [EMAIL PROTECTED]
I've just added Class Admin to the model in Chapter 6 of the Django Book. Also I included "django.contrib.admin" in settings in INSTALLED_APPS and the patterns r'^admin... in the urls.py file. When I validate I get the following error. It looks like I am missing files or have I forgotten a from

Re: Missing packages

2007-07-17 Thread James Bennett
On 7/17/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] mysite]$ ./manage.py validate > admin.logentry: 'user' has relation with model User, which has not > been installed > admin.logentry: 'content_type' has relation with model ContentType, > which has not been installed > 2

small question on templates

2007-07-17 Thread rogerdpack
I know that django support "method lookup, then hash member lookup then something" or what not, for template functions, but, my question is can you call a function (like a method) and pass it arbitrary parameters. {% function1 'a', 'b' %} type of thing. Sorry if this is very newbie. -roger --~-

Re: Missing packages

2007-07-17 Thread [EMAIL PROTECTED]
The Django Book had directed the commenting out of the packages. Once I uncommented, things worked. On Jul 17, 7:51 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 7/17/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > [EMAIL PROTECTED] mysite]$ ./manage.py validate > > admin.logentry:

Re: Problem installing django on dreadhost

2007-07-17 Thread walterbyrd
On Jul 17, 3:50 pm, Collin Grady <[EMAIL PROTECTED]> wrote: > Check your DATABASE_HOST setting in settings.py - if you have it set > to a path you can't write to, that would explain the error. > > Also, you should be using "manage.py syncdb" not "django-admin.py > syncdb" Thanks. Although, I got

Re: small question on templates

2007-07-17 Thread Russell Keith-Magee
On 7/18/07, rogerdpack <[EMAIL PROTECTED]> wrote: > > I know that django support "method lookup, then hash member lookup > then something" or what not, for template functions, but, my question > is can you call a function (like a method) and pass it arbitrary > parameters. {% function1 'a', 'b' %}

Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread Russell Keith-Magee
On 7/17/07, Manoj Govindan <[EMAIL PROTECTED]> wrote: > > I have a question here. I have found Django to be much faster than, > say, Rails. However, Django seems to take way more time to load > fixtures (I am not counting the time taken to create the database > each time here) compared to Rails.

Re: ANN: DMigrate - A Django Database Migration Tool

2007-07-17 Thread James Bennett
On 7/17/07, Noam Raphael <[EMAIL PROTECTED]> wrote: > I would really like to hear what you think about it (especially if > it's good things...) Tell me! I haven't looked at the code, but I wonder about the dependency on multiple ORMs; the Django ORM cannot expose its own functionality on multiple

Re: ANN: DMigrate - A Django Database Migration Tool

2007-07-17 Thread Ben Ford
> I haven't looked at the code, but I wonder about the dependency on > multiple ORMs; the Django ORM cannot expose its own functionality on > multiple databases at once... It can using the multiple-db-support branch (see ticket 4747 for a patch bringing the branch up to date)... There's also a si

Re: is there any host servers that supports Django based sites?

2007-07-17 Thread Kenneth Gonsalves
On 17-Jul-07, at 9:26 PM, Chris Hoeppner wrote: > > You'll wanto to try with at least 2.4. Though it's said that 2.3 *is* > supported, it has given me tons of headaches. For safe, go for 2.4 > at least. all my servers run on 2.3.5 and one of them also on the latest svn head without any pro

Re: anybody help me! raise EnvironmentError

2007-07-17 Thread Nathan Ostgard
As Collin said, if your script isn't running from within a "proper" Django environment, you have to ensure that your settings module is correctly specified. You can do it several ways... 1. Using Django's setup_environ: # put before any django imports, at the top of your file from django.core.ma

Re: MEDIA_URL MEDIA_ROOT problem.

2007-07-17 Thread Nathan Ostgard
You can also refer to this page in the documentation for more information: http://www.djangoproject.com/documentation/static_files/ Nathan Ostgard On Jul 17, 11:35 am, Dmitriy Sodrianov <[EMAIL PROTECTED]> wrote: > Hello everyone! > > Let me ask for help with the following problem: > >

Re: Blog engine

2007-07-17 Thread Paulo
No to mention a good blog app that people can standardize on would be a nice alternative to Wordpress[1] and Simplelog[2]. Having one would definitely be helpful in the "spreading the word about Django" department. We made the switch to Django/Python over a year ago for our client work and it was

Date Problem

2007-07-17 Thread Nash
Dear all, I am running django pre-0.97 on a linux box. the date command on linux and in python datetime.now() both give me the correct times. However, in one of my models, there is a datetime attribute 'created_on' with default=datetime.now(). The default value going is is not the same as that of

Using Threadlocals: Error binding parameter 5 - probably unsupported type.

2007-07-17 Thread Michael Lake
Hi all I am using ThreadLocals from http://code.djangoproject.com/wiki/CookBookThreadlocalsAndUser I am getting this error on submitting the form: InterfaceError at /erun/10/1/ Error binding parameter 5 - probably unsupported type. This is my model: class Data(models.Model): date

Re: Blog engine

2007-07-17 Thread James Bennett
On 7/18/07, Paulo <[EMAIL PROTECTED]> wrote: > No to mention a good blog app that people can standardize on would be > a nice alternative to Wordpress[1] and Simplelog[2]. Having one would > definitely be helpful in the "spreading the word about Django" > department. I'm not entirely disintereste

Re: Date Problem

2007-07-17 Thread James Bennett
On 7/18/07, Nash <[EMAIL PROTECTED]> wrote: > I am running django pre-0.97 on a linux box. the date command on linux > and in python datetime.now() both give me the correct times. However, > in one of my models, there is a datetime attribute 'created_on' with > default=datetime.now(). The default

Re: How can I run syncdb task without loading any initial_data fixtures?

2007-07-17 Thread Manoj Govindan
> > Is this comparison something you have done personally? If so, can you Yes. I wrote the same application in Rails before I moved to Django (I have always liked Python ;)) While the tests themselves are not *identical* there were about the same number of them. > provide any benchmarking detail

Re: Blog engine

2007-07-17 Thread [EMAIL PROTECTED]
I wrote a blogging system for myself that can be had through subversion at this url: http://svn.karmazilla.net/hobby_projects/Djogg I'm still looking for a good place to deploy my own instance, though. I've kinda given up getting it to work in dreamhost. On Jul 18, 8:01 am, "James Bennett" <[

Logging in a newly created user

2007-07-17 Thread LaundroMat
Hi, When running this, I get a "NoneType has no attribute is_authenticated()" error, and I cannot understand why: 1 new_user = User.objects.create_user(username, "your.email", password) 2 new_user.is_active = False 3 new_user.save() 4 user = authenticate(username = new_user.username, password =

  1   2   >