Re: Django, Components, and Interfaces

2007-09-08 Thread Marty Alchin
On 9/8/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > So at my work we developed an app to provide object-level permissions. > Ideally, we could ask a User object if it has permission on a certain object > via a method in that User object, but absent hacking the User object, that's > not g

Re: Django, Components, and Interfaces

2007-09-08 Thread Vsevolod Solovyov
On 9/8/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > So at my work we developed an app to provide object-level permissions. > Ideally, we could ask a User object if it has permission on a certain object > via a method in that User object, but absent hacking the User object, that's > not

Re: Django, Components, and Interfaces

2007-09-08 Thread Joshua 'jag' Ginsberg
Thank you all for taking the time to write your thoughts -- they've been very helpful! I hope you'll forgive me for trying to write a response to them collectively touching on the excellent points they raised. For the record, I'm not a Java developer. I spend most of my time writing in Python by c

Re: Django, Components, and Interfaces

2007-09-07 Thread buriy
> The application creators weren't thinking about interoperability of their > applications because there are no such guidelines for making interoperable > applications. Interfaces and componentization would give Django the > opportunity to define some standard interfaces like IUser and give Django

Re: Django, Components, and Interfaces

2007-09-07 Thread Christopher Lenz
Am 07.09.2007 um 21:07 schrieb Christopher Lenz: > Am 07.09.2007 um 20:40 schrieb Yuri Baburov: >>> Or if I'm using Satchmo and I've written an excellent CRM system >>> in Django, >>> I want Satchmo to use the shipping and contact information that >>> I've defined >>> in my CRM system, and if they

Re: Django, Components, and Interfaces

2007-09-07 Thread Vsevolod Solovyov
On 9/7/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > > I can see abstract idea. But don't see right implementation idea. > > 1) You can do this all without all javaish interfaces. > > Admitted, this is bringing some higher OO language stuff to Python. Trac and > (gasp!) Zope both went do

Re: Django, Components, and Interfaces

2007-09-07 Thread Jacob Kaplan-Moss
Hi Joshua -- > [...] if they both implemented IPerson, IPostalAddress, and > IPhoneNumber, [...] ... and that's the point where my eyes glaze over and smoke starts coming out of my ears. I don't know you, but I'll hazard a guess at your background: Java, right? The thing you have to understand

Re: Django, Components, and Interfaces

2007-09-07 Thread Marty Alchin
On 9/7/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > Sure. Walks, quacks, yep. It's a duck. But if I want my own user model, I > don't just have to make something that looks and acts like a User from > django.contrib.auth -- I have to convince everybody else to use my version > instead of

Re: Django, Components, and Interfaces

2007-09-07 Thread James Bennett
On 9/7/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > Problems: > 1) While there is a good degree of drop-in replacability of parts in the > Django stack as I outlined (db backend, authentication backend, etc.) there > is not a clean way for programmers to grok what specific contract vario

Re: Django, Components, and Interfaces

2007-09-07 Thread Marty Alchin
On 9/7/07, Marty Alchin <[EMAIL PROTECTED]> wrote: > Now, this point I might not be understanding correctly. Are you asking > for Django's core to define an interface for each and every potential > use someone might find for it? While I can understand the marginal > benefit such interfaces might p

Re: Django, Components, and Interfaces

2007-09-07 Thread Joshua 'jag' Ginsberg
Hi Yuri -- Thank you also for taking the time to write. This was design error of applications creators. > Let's think what Django could do to prevent such errors. The application creators weren't thinking about interoperability of their applications because there are no such guidelines for ma

Re: Django, Components, and Interfaces

2007-09-07 Thread Christopher Lenz
Am 07.09.2007 um 20:40 schrieb Yuri Baburov: >> Or if I'm using Satchmo and I've written an excellent CRM system >> in Django, >> I want Satchmo to use the shipping and contact information that >> I've defined >> in my CRM system, and if they both implemented IPerson, >> IPostalAddress, and

Re: Django, Components, and Interfaces

2007-09-07 Thread Marty Alchin
I probably shouldn't be putting my hat in this ring, but I've never been a big fan of components and interfaces, so I'll provide some of my own thoughts on the subject. On 9/7/07, Joshua 'jag' Ginsberg <[EMAIL PROTECTED]> wrote: > Problems: > 1) While there is a good degree of drop-in replacabili

Re: Django, Components, and Interfaces

2007-09-07 Thread Yuri Baburov
> An example: I like Suzy Creamcheese's Blog application but she used > django.contrib.comments in it, and I want Joe Schmoe's slashdot style > commenting system. I also want people who have blogs to be able to post > their own photos, but Suzy Creamcheese's Blog application uses a BlogAuthor > mo

Re: Django, Components, and Interfaces

2007-09-07 Thread Joshua 'jag' Ginsberg
Malcolm -- Thanks for taking the time to read it and write back. I apologize if what I said at first didn't come across clearly -- I often need two or more stabs at explaining something before I get it across with its semantic integrity still in place. It's not clear what problem(s) you are actu

Re: Django, Components, and Interfaces

2007-09-07 Thread Malcolm Tredinnick
On Fri, 2007-09-07 at 12:48 -0400, Joshua 'jag' Ginsberg wrote: [...] > First, every section of Django becomes customizeable without chopping > up the source tree. We already permit drop-in authentication backends, > database backends, and caching backends; there's been talk of drop-in > session b

Django, Components, and Interfaces

2007-09-07 Thread Joshua 'jag' Ginsberg
Howdy all -- I've been working with the internals of both Django and Trac lately, and there's a feature of Trac that I have found to be simply outstanding and remarkably consistent with the engineering standards of Django: Trac's component framework. The code for Components, Interfaces, and the l