fw wrote:
> Hi,
> 
> I am having a weird problem. I am dealing with some "legacy" database,
> so I subclass TypeDecorator to help clean things up a bit.
> 
> This worked fine in 0.3 but I am now trying to use 0.4 and things
> break in the strangest of way.
> 
> When I run the file below, Python complains about
> 
>         AttributeError: 'String' object has no attribute 'padding'
> 
> Now, "padding" is a parameter of the constructor of PaddedIntString.
> So it is not an attribute.
> 
> If I make "padding" an attribute of  PaddedIntString, the error
> dissappears.
> 
> Am I doing something wrong or is this a feature of 0.4???

That sounds like the __repr__ method of AbstractType trying to be 
clever, probably called in a logging operation.  Try providing a 
__repr__ in your type class.

The __repr__ behavior hasn't changed with 0.4, but there might be more 
logging than 0.3.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to