[sqlalchemy] Re: Add arbitrary information to some classes

2007-11-05 Thread jason kirtland
Paul Johnston wrote: > I have just put a proposed patch on ticket #573. It uses "info" as the > name and puts it on SchemaItem. Due to the way constructors are arranged > for SchemaItem subclasses, I've explicitly put this in the constructor > for Table and Column. > > Happy to take further co

[sqlalchemy] Re: Add arbitrary information to some classes

2007-11-05 Thread Paul Johnston
Hi, > sorry, i havent been following. two++ dicts ?! this is getting out > of hand. if we have to have any dicts at all, it would be just one > dict. and also, it should be proxied through a property so that if > you dont access it, its never even created. I have just put a proposed p

[sqlalchemy] Re: Add arbitrary information to some classes

2007-11-02 Thread Rick Morrison
I don't think that two dicts would be that "out of hand", for an average schema, say 50 tables x 10 cols, with 8-16 bytes each for each dict (how big is an empty dict anyway?), you'd be looking at 50 * ((10*2) + 1) * 16 = about 16.8K of memory. Not that big of a deal. But you're right, you don't

[sqlalchemy] Re: Add arbitrary information to some classes

2007-11-01 Thread Michael Bayer
sorry, i havent been following. two++ dicts ?! this is getting out of hand. if we have to have any dicts at all, it would be just one dict. and also, it should be proxied through a property so that if you dont access it, its never even created. we have this on ConnectionFairy right n

[sqlalchemy] Re: Add arbitrary information to some classes

2007-11-01 Thread Rick Morrison
That sounds reasonable to me; my knee-jerk thought was that we might need to worry about memory usage, but these references are only on low-count instances like tables, columns, sessions and mappers, not ORM object instances. On 10/31/07, Paul Johnston <[EMAIL PROTECTED]> wrote: > > Hi, > > Ah s

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-31 Thread Paul Johnston
Hi, Ah sure, so it's to be a namespace for namespaces, a shared dict() parking > lot. Got it. > How about having two dicts? One is purely for user data, libraries and such never touch it. I suggest "userdata". The other is for use in extensions and stuff, say "extdata". Paul --~--~-~--

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread Rick Morrison
Ah sure, so it's to be a namespace for namespaces, a shared dict() parking lot. Got it. So then, how about "aux" "etc" "other" or maybe "miscdata" "extra" "more" "additional" "supplemental" "auxiliary" "adjunct" "appendix" "surplus" "spare" "augment" --~--~-~--~~~--

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread jason kirtland
Rick Morrison wrote: > > The core can (and does) use these buckets too, so I'm not sure > about the > > user-y moniker. > > Hold it. I thought the whole point of this was to separate core usage > from user usage? To create a "safe-zone" for library user's private data. Yes to the

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread Rick Morrison
> > > The core can (and does) use these buckets too, so I'm not sure about the > > user-y moniker. Hold it. I thought the whole point of this was to separate core usage from user usage? To create a "safe-zone" for library user's private data. > But if that were it, I'd only be +1 on a spelled

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread jason kirtland
Rick Morrison wrote: > personal opinion: I'm not wild about either 'attributes' or 'properties', > (a) they seem too long, and > (b) yes, they are too similar to generic ORM terms > > many many moons ago (pre Windows-1.0 ) I used an Ascii-GUI thing called > C-scape (I think it's called "verm

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread Rick Morrison
personal opinion: I'm not wild about either 'attributes' or 'properties', (a) they seem too long, and (b) yes, they are too similar to generic ORM terms many many moons ago (pre Windows-1.0) I used an Ascii-GUI thing called C-scape (I think it's called "vermont views" now). anyway, most of it

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread jason kirtland
Rick Morrison wrote: > On 10/26/07, *Paul Johnston* <[EMAIL PROTECTED] > > wrote: >> >> Ticket #573 mentions adding a field for arbitrary >> application-specific information to tables. I now have a need for >> this, so I'm prepared to do the work to make it

[sqlalchemy] Re: Add arbitrary information to some classes

2007-10-30 Thread Rick Morrison
I often use Session as a context placeholder, and have felt a bit uneasy about this as you never know when some new release is going to stake a claim on the name you've used. I know I'd feel better if there was a name that would be kept aside. On 10/26/07, Paul Johnston <[EMAIL PROTECTED]> wrote