[IronPython] can't inherit??

Ivan Porto Carrero ivan at flanders.co.nz
Mon Apr 27 20:24:37 CEST 2009

it's a bad subject but I didn't know how else to call it.

For the DynamicScriptControl somebody submitted an ironpython implementation
in February but I only just now got round to adding it.
And I have problems :)

The link below has the line that fails for IronPython but works for IronRuby


So the idea is that you read a script file containing a wpf/silverlight
control. Because you cannot have DLR controls in WPF atm there is this
dynamic script control to allow you to have DLR controls participate in

So what happens in IronRuby is the following.
The script converter generates a script that will set the properties and
create an instance of the control. This control is then put into the XAML
object graph.
The script that is generated actually monkey patches the initialize method
of the the control class to populate the control properties.

The implementation that has been provided to me actually inherits of the
first control to override the constructor and to do the proper
initializations, only it doesn't work.
it tells me that it cannot find the parent class I get an
UnboundNameException and AFAICT I shouldn't get that.

I'm using the latest nightly builds.

The ruby implementation of the control

the python implementation

The ruby code formatter (for monkey patching the control):

The python code formatter:

I'm pretty sure this is a 5 second fix for somebody that knows what they're
doing with IronPython, so help help ... ;)


Met vriendelijke groeten - Best regards - Salutations
Ivan Porto Carrero
GSM: +32.486.787.582
Blog: http://flanders.co.nz
Twitter: http://twitter.com/casualjim
Author of IronRuby in Action (http://manning.com/carrero)

Steven Wright<http://www.brainyquote.com/quotes/authors/s/steven_wright.html>
- "A lot of people are afraid of heights. Not me, I'm afraid of
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20090427/4873db30/attachment.html>

More information about the Ironpython-users mailing list