On Tue, Jul 8, 2008 at 6:47 PM, Gerdus van Zyl <[EMAIL PROTECTED]> wrote: > Hi, > > I would like to propose the following small change to the Variable class: > def __init__(self, value=Undef, value_factory=Undef, from_db=False, > allow_none=True, column=None, event=None,**otherkwargs): > > ..... > self._extrakwargs = otherkwargs > > This allows arbitrary keyword arguments like: > creditlimit = Decimal(precision=(12,2)) > that can be accessed using: > p = (one of self._storm_columns) > p._variable_kwargs['precision'] > > This is ultra handy for associating meta data specific to a database column. > Currently Variable is throwing a hissy fit (exception) when you try to do > this.
Note that Storm creates a lot of variable objects (one per column per instance, and a number get created as part of the expression parsing), so I don't know if you'd want to be storing things like this. In the current trunk version we've been using __slots__ to try and slim down the class. What exactly do you want to do? James. -- storm mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/storm
