Patch for cookie-based mod_python/apache authentication

2007-05-29 Thread SmileyChris
In http://code.djangoproject.com/ticket/3583 I've added a patch which refactors the existing mod_python authentication function and adds a new cookie based one. If anyone can, a review would be good. Specifically: 1. Does it work correctly for you? (it does for me) 2. Is the change in patch 2 a s

Re: Custom field _post_create_sql()

2007-05-29 Thread Justin Bronn
> In PostGIS, the AddGeometryColumn() function needs to be run separately > after the create table. It adds the geometry field to the table, adds > its definition (projection, geometry type, dimensions) to the > 'geometry_columns' table, creates a number of constraints, etc. Thanks, Rob, for the

Re: Can we use a django application class?

2007-05-29 Thread Malcolm Tredinnick
On Tue, 2007-05-29 at 11:50 -0700, Vinay Sajip wrote: > > On May 29, 7:12 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > > > As far as I know, you can install two applications which live in > > folders which happen to have the same na

Re: GSoC 2007 - Object-Level Caching

2007-05-29 Thread Malcolm Tredinnick
On Tue, 2007-05-29 at 16:26 +, Paul Collier wrote: > > If I update o1 in some other part of the > > code, what assumptions are made about qs? > Hmm, yeah... I haven't focused enough attention on .cache_set() yet, > heheh. I was definitely just going to implement (1) first, and then > worry abo

Re: Custom field _post_create_sql()

2007-05-29 Thread Malcolm Tredinnick
On Tue, 2007-05-29 at 11:47 -0500, Joseph Kocherhans wrote: > On 5/29/07, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > > > Malcolm's _get_field_sql() question is a good one -- I'm +1 on adding > > that method to the fields. Only thing is, does _get_field_sql() get > > passed the database backend

Re: django-values -> django-policy?

2007-05-29 Thread Nick
On May 30, 12:56 am, "Jacob Kaplan-Moss" <[EMAIL PROTECTED]> wrote: > OK, this has gone on long enough. > > I propose the boring-but-functional "dbsettings" -- settings stored in > the db -- and unless someone can come up with a REALLY good reason not > to use that, I'm going to make a dictatorial

Re: Proposal: Generic newforms media

2007-05-29 Thread Russell Keith-Magee
On 5/30/07, Luke Plant <[EMAIL PROTECTED]> wrote: > > On Tuesday 29 May 2007 21:13:44 Luke Plant wrote: > > > I've had to add hacks in before to get around the inflexibility of > > inner classes. > > It looks like my hack for this will no longer be needed in > newforms-admin. That's because: > >

Re: Custom field _post_create_sql()

2007-05-29 Thread Robert Coup
Malcolm Tredinnick wrote: > GIS guys, any particular reasons for the approach you took? -- laziness? > economy? "it works, dammit!"? technical reason against the above? > In PostGIS, the AddGeometryColumn() function needs to be run separately after the create table. It adds the geometry field

Backwards incompatibility between 0.91 and 0.95 (mutli-auth sessions)

2007-05-29 Thread Jeremy Dunck
In [3226], the multi-auth branch landed. It introduced a backwards incompatibility in existing sessions, which are used for session-based auth. The code responsible for supplying request.user prior to that rev was e.g. handlers.modpython.ModPythonRequest._get_user. After that rev, it's contrib.au

Re: Can we use a django application class?

2007-05-29 Thread James Bennett
Also, you might want to have a look at the WSGI ecosystem and specifically Paste Deploy, which can kind-of be made to work with Django and does a lot of what you seem to want, but in a framework-neutral way. Anyway, I think we're just talking past each other at this point, so I'll bow out. -- "

Re: Can we use a django application class?

2007-05-29 Thread James Bennett
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > Is this considered part of the stable API? Is it part of the backward > compatibility guarantee? I can't make a hard and fast promise, but since there are quite a few bits of Django itself which rely on this API and would have to be rewritt

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 9:12 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > > I can't extend Django applications with extra features that require > > auto-discovery. I'm working on a CMS using Python, and I want to know > > which applications support

Re: Proposal: Generic newforms media

2007-05-29 Thread Luke Plant
On Tuesday 29 May 2007 21:13:44 Luke Plant wrote: > I've had to add hacks in before to get around the inflexibility of > inner classes. It looks like my hack for this will no longer be needed in newforms-admin. That's because: class MyModel: ... class Admin: fields = has turne

Re: Proposal: Generic newforms media

2007-05-29 Thread Luke Plant
On Tuesday 29 May 2007 11:26:45 Russell Keith-Magee wrote: > On 5/29/07, Luke Plant <[EMAIL PROTECTED]> wrote: > > On Saturday 26 May 2007 21:55:04 Jared Kuolt wrote: > > > The javascript > > > portion seems fine, however I would see media as a class, not as > > > a method, ala a model's Meta clas

Re: Can we use a django application class?

2007-05-29 Thread Vinay Sajip
On May 29, 7:12 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > As far as I know, you can install two applications which live in > folders which happen to have the same name though they're nested > inside different parts of an overall di

Re: Can we use a django application class?

2007-05-29 Thread James Bennett
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > I can't extend Django applications with extra features that require > auto-discovery. I'm working on a CMS using Python, and I want to know > which applications support special features that my CMS can build upon > (something similar to admi

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 7:53 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > > Well, it is called INSTALLED_APPS, not MODELS_OF_INSTALLED_APPS, > > right? :) > > > The only reason that the "models module of the application is what's > > already used in

Re: Can we use a django application class?

2007-05-29 Thread Vinay Sajip
On May 29, 6:06 pm, Vinay Sajip <[EMAIL PROTECTED]> wrote: > My changes don't address all of the things Ahmed was after, but the > question about the need for an app class (albeit lightweight) is a > valid one, and I've scratched my itch with the patch: > > http://code.djangoproject.com/attachme

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 7:24 pm, "Jacob Kaplan-Moss" <[EMAIL PROTECTED]> wrote: > Hey Ahmed -- > > Let's back up a step here: what's the problem you're having with the > way Django currently does INSTALLED_APPS? What can't you do that you'd > like to do? > > Jacob I can't change my application structure witho

Re: Can we use a django application class?

2007-05-29 Thread Vinay Sajip
On May 29, 5:24 pm, "Jacob Kaplan-Moss" <[EMAIL PROTECTED]> wrote: > Hey Ahmed -- > > Let's back up a step here: what's the problem you're having with the > way Django currently does INSTALLED_APPS? What can't you do that you'd > like to do? One example is provided by the admin interface: Model

Re: Can we use a django application class?

2007-05-29 Thread Marty Alchin
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > Well, it is called INSTALLED_APPS, not MODELS_OF_INSTALLED_APPS, > right? :) > > The only reason that the "models module of the application is what's > already used internally (in some places anyway) to refer to an > application" is because

Re: GSoC 2007 - Object-Level Caching

2007-05-29 Thread Brian Rosner
On 2007-05-29 01:37:50 -0600, Paul Collier <[EMAIL PROTECTED]> said: > > Hello all! > > Continuing with the string of posts regarding this year's GSoC, I'm > pleased to be working on new caching functionality for Django's ORM > under the mentorship of Gary Wilson[1]! Big thanks to him and all

Re: Custom field _post_create_sql()

2007-05-29 Thread Joseph Kocherhans
On 5/29/07, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > Malcolm's _get_field_sql() question is a good one -- I'm +1 on adding > that method to the fields. Only thing is, does _get_field_sql() get > passed the database backend? If the method is going in, I think passing in the db backend would

Re: Can we use a django application class?

2007-05-29 Thread Marty Alchin
On 5/29/07, Brian Rosner <[EMAIL PROTECTED]> wrote: > One thing this makes me think of is allowing custom display names for > applications. Currently there is no way to mark application names for > translation (that I know of). This is a solution that can work in a > more modular way than making

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 7:16 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > > I'm definitely not suggesting a major infrastructure change. I'm just > > suggesting something similar to the passing views as callable objects > > instead of passing them a

Re: Can we use a django application class?

2007-05-29 Thread Brian Rosner
On 2007-05-29 05:43:08 -0600, Ahmad Alhashemi <[EMAIL PROTECTED]> said: > > Hello, > > Right now, django applications are strange creatures. They are python > packages with some magic. They have to have a "models" module. > Everything else is free form. We have strong conventions like urls.py,

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 7:12 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > > > Why are we reinventing import everywhere in django? Is this really > > common in python, passing strings containing package names around > > instead of simply passing objec

Re: GSoC 2007 - Object-Level Caching

2007-05-29 Thread Paul Collier
> If I update o1 in some other part of the > code, what assumptions are made about qs? Hmm, yeah... I haven't focused enough attention on .cache_set() yet, heheh. I was definitely just going to implement (1) first, and then worry about something more advanced once I got to the "smart" functionalit

Re: Can we use a django application class?

2007-05-29 Thread Jacob Kaplan-Moss
Hey Ahmed -- Let's back up a step here: what's the problem you're having with the way Django currently does INSTALLED_APPS? What can't you do that you'd like to do? Jacob --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Gro

Re: Custom field _post_create_sql()

2007-05-29 Thread Adrian Holovaty
On 5/29/07, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote: > I hadn't heard back from Adrian yet; I want to make sure to have his OK. > > I'll let the GIS folks answer your question about _get_field_sql(); my > impression is that PostGIS at least makes you declare GIS fields > *after* you declare yo

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 3:36 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > On the topic of "magic", that's a very polarizing phrase. There's no > one definition of magic in the Python sense, so each person is free to > define it differently. For instance, your proposal seems (in a way) > more magical to me,

Re: Can we use a django application class?

2007-05-29 Thread Marty Alchin
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > I'm definitely not suggesting a major infrastructure change. I'm just > suggesting something similar to the passing views as callable objects > instead of passing them as strings containing the names of those > objects. It is just more pytho

Re: Can we use a django application class?

2007-05-29 Thread James Bennett
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > Why are we reinventing import everywhere in django? Is this really > common in python, passing strings containing package names around > instead of simply passing objects? I don't see this anywhere in the > library. I don't see this anywher

Re: django-values -> django-policy?

2007-05-29 Thread Marty Alchin
On 5/29/07, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote: > I propose the boring-but-functional "dbsettings" -- settings stored in > the db -- and unless someone can come up with a REALLY good reason not > to use that, I'm going to make a dictatorial call to paint the > bikeshed MY color. Personal

Re: Proposal: Generic newforms media

2007-05-29 Thread Jacob Kaplan-Moss
On 5/29/07, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > http://code.djangoproject.com/ticket/4418 +1 from me. Jacob --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this gr

Re: Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
On May 29, 2:55 pm, "James Bennett" <[EMAIL PROTECTED]> wrote: > Could you elaborate on what's "magical" about an application? It's > just a Python module, with one convention imposed on where you put > model classes so that Django can auto-discover them; adding a whole > new level of infrastructu

Re: Custom field _post_create_sql()

2007-05-29 Thread Jacob Kaplan-Moss
On 5/29/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > On Sat, 2007-05-26 at 01:53 -0500, Jacob Kaplan-Moss wrote: > > On 5/26/07, Justin Bronn <[EMAIL PROTECTED]> wrote: > > > We encountered a similar problem on the GIS branch. Specifically, the > > > OpenGIS specification requires that c

Re: django-values -> django-policy?

2007-05-29 Thread Jacob Kaplan-Moss
OK, this has gone on long enough. I propose the boring-but-functional "dbsettings" -- settings stored in the db -- and unless someone can come up with a REALLY good reason not to use that, I'm going to make a dictatorial call to paint the bikeshed MY color. Objections? Jacob --~--~-~--

Re: django-values -> django-policy?

2007-05-29 Thread Jay Parlar
On 5/29/07, James Bennett <[EMAIL PROTECTED]> wrote: > > In all seriousness: django.contrib.bikeshed. > That actually made me laugh, but I think you have a valid point. This is definitely a bikeshed topic, but maybe that name can actually work. django-values provides storage and easy access to v

Re: Volunteering for "Week in Review" postings

2007-05-29 Thread Clint Ecker
Thanks everyone for all your feedback, it's going to be a big help when I get started. On 5/25/07, Simon Willison <[EMAIL PROTECTED]> wrote: > ...I suggest aiming for weekly > updates even if there are only two or three things to report, but > skipping weeks entirely if nothing has haeppened. Wit

Re: Proposal: Generic newforms media

2007-05-29 Thread Russell Keith-Magee
Hi all, I've just opened a ticket for Media descriptors, and uploaded a patch implementing the API that has emerged from this thread. http://code.djangoproject.com/ticket/4418 Hopefully, between this thread and the regression test, usage is obvious. Feedback is welcome. Yours, Russ Magee %-)

Re: django-values -> django-policy?

2007-05-29 Thread Nicola Larosa
James Bennett wrote: > In all seriousness: django.contrib.bikeshed. Magenta! Shall we paint it magenta? Pretty please? -- Nicola Larosa - http://www.tekNico.net/ Microsoft went berserk; tried unsuccessfully to get me fired as co-editor, and then launched a vicious, deeply personal extended at

Re: django-values -> django-policy?

2007-05-29 Thread James Bennett
In all seriousness: django.contrib.bikeshed. -- "Bureaucrat Conrad, you are technically correct -- the best kind of correct." --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to th

Re: django-values -> django-policy?

2007-05-29 Thread Flavio Curella
Symbols? On 29 Mag, 09:47, simonbun <[EMAIL PROTECTED]> wrote: > Hmm, policy reminds me of a few pages of text with legal mumbo jumbo, > like an acceptable use policy. > > We can go for something technical, like values, properties, entries, > constraints, presets, ... or maybe it's time for somet

Re: Can we use a django application class?

2007-05-29 Thread Marty Alchin
I don't know a lot about the history of Django or its developers, but the impression I get is that every suggestion must answer the basic question: "what real-world problem does this solve?" In this case, I don't see a good answer to that. It's a different solution, yes, that may have some (minor

Re: Can we use a django application class?

2007-05-29 Thread James Bennett
On 5/29/07, Ahmad Alhashemi <[EMAIL PROTECTED]> wrote: > Right now, django applications are strange creatures. They are python > packages with some magic. They have to have a "models" module. > Everything else is free form. We have strong conventions like urls.py, > maybe admin.py, but they all ha

Can we use a django application class?

2007-05-29 Thread Ahmad Alhashemi
Hello, Right now, django applications are strange creatures. They are python packages with some magic. They have to have a "models" module. Everything else is free form. We have strong conventions like urls.py, maybe admin.py, but they all have to be explicitly called and used in the project. Ho

Re: MEDIA_URL template tag/context processor/etc again

2007-05-29 Thread Russell Keith-Magee
On 5/29/07, Marc Fargas <[EMAIL PROTECTED]> wrote: > > Anyway, now it's clear that we should go for {{ MEDIA_URL }} which means > that in a near future we'll have MEDIA_URL in templates, hurray! :) Committed in [5379]. Yours, Russ Magee %-) --~--~-~--~~~---~--~~

Re: Proposal: Generic newforms media

2007-05-29 Thread Russell Keith-Magee
On 5/29/07, Luke Plant <[EMAIL PROTECTED]> wrote: > > On Saturday 26 May 2007 21:55:04 Jared Kuolt wrote: > > The javascript > > portion seems fine, however I would see media as a class, not as a > > method, ala a model's Meta class: > > > > class MyWidget(Widget): > > ... > > class Media:

Re: MEDIA_URL template tag/context processor/etc again

2007-05-29 Thread Steven Armstrong
Simon G. wrote on 04/25/07 13:33: > Evening all, > > There's been a long history of people asking for some way of easily > using the MEDIA_URL setting in templates. At a quick glance, I get > #1278, #3818, #2532, and #4105. > > These have all been marked wontfix, and I closed this last one to >

Custom field _post_create_sql()

2007-05-29 Thread Malcolm Tredinnick
On Sat, 2007-05-26 at 01:53 -0500, Jacob Kaplan-Moss wrote: > On 5/26/07, Justin Bronn <[EMAIL PROTECTED]> wrote: > > We encountered a similar problem on the GIS branch. Specifically, the > > OpenGIS specification requires that compliant spatial databases add > > geometry columns by calling the s

Re: GSoC 2007 - Object-Level Caching

2007-05-29 Thread Malcolm Tredinnick
On Tue, 2007-05-29 at 07:37 +, Paul Collier wrote: > Hello all! > > Continuing with the string of posts regarding this year's GSoC, I'm > pleased to be working on new caching functionality for Django's ORM > under the mentorship of Gary Wilson[1]! Big thanks to him and all the > people from t

Re: newforms captcha field

2007-05-29 Thread Martin Winkler
Thanks "itsnotvalid" and SmileyChris for your replys. Unfortunately "reCAPTCHA" does not fulfil my needs, because it has an english-only interface, and just english words - at least for the time being. I think, I'll have to do my own approach: * A directory containing small images for backgroun

Re: django-values -> django-policy?

2007-05-29 Thread Amit Upadhyay
On 5/29/07, Derek Hoy <[EMAIL PROTECTED]> wrote: > > > Registry? +1 django-registry. -- Amit Upadhyay Vakao! +91-9820-295-512 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to t

Optgroups from nested choices in newforms (discussion of patch on #4412)

2007-05-29 Thread James Bennett
I noticed a patch sitting on #4412 tonight which seems interesting but definitely needs a decision; the idea is that, rather than implementing a separate widget or set of widgets to handle grouping of options (via the HTML "optgroup" element), the Select and SelectMultiple widgets should look at t

Re: django-values -> django-policy?

2007-05-29 Thread Derek Hoy
Registry? Derek --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL

Re: [Triagers/Core] About Stale Tickets

2007-05-29 Thread Marc Fargas
El mar, 29-05-2007 a las 10:53 +1000, Malcolm Tredinnick escribió: > I didn't respond to your first email about this over the weekend, > because the reply I originally wrote wasn't particularly polite. Thanks for not sending that one then ;) > At some point, you have to accept that this ticket

Re: django-values -> django-policy?

2007-05-29 Thread simonbun
Hmm, policy reminds me of a few pages of text with legal mumbo jumbo, like an acceptable use policy. We can go for something technical, like values, properties, entries, constraints, presets, ... or maybe it's time for something completely different. Let's call them "tefkav"s, as in, "The Entitie

Re: MEDIA_URL template tag/context processor/etc again

2007-05-29 Thread Marc Fargas
El mar, 29-05-2007 a las 08:15 +0800, Russell Keith-Magee escribió: > I make that 5:3 - and not wanting to put a jackboot down on the throat > of democracy, but #1278 has the support of 4 core developers, > including the BDFL. I never was good at maths :) And I didn't perform a really well measur

Re: django-values -> django-policy?

2007-05-29 Thread Jason Davies
On May 28, 8:44 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote:> > In short, I vote that it be changed to django-policy. I can't change > the URL in Google Code without starting a whole new project (and since > I already have issues in place, I'd rather not do that), but I can > change all the docum

GSoC 2007 - Object-Level Caching

2007-05-29 Thread Paul Collier
Hello all! Continuing with the string of posts regarding this year's GSoC, I'm pleased to be working on new caching functionality for Django's ORM under the mentorship of Gary Wilson[1]! Big thanks to him and all the people from the community who made this possible. Now I've just got to hold up m