Re: [Tutor] inheritance and super() function in python

2014-04-23 Thread Mark Lawrence
On 23/04/2014 14:56, Jorge Leon wrote: class Cylinder(Obstacle): def __init__(self,position, height, radius): super(Obstacle,self).__init__(position) But it looks to me like the last line should be super(Cylinder, self).__init__(position) Hey, thanks again for the help

Re: [Tutor] inheritance and super() function in python

2014-04-23 Thread Jorge Leon
> class Cylinder(Obstacle): >def __init__(self,position, height, radius): >super(Obstacle,self).__init__(position) > > But it looks to me like the last line should be > super(Cylinder, self).__init__(position) > Hey, thanks again for the help and sorry about all the format err

Re: [Tutor] inheritance and super() function in python

2014-04-22 Thread Dave Angel
Jorge Leon Wrote in message: > Thank you Steve and Dave for the prompt response and advise, and sorry > about the format. > > The version of Python I'm working under is 2.7.5. About the .super(): > I'm going to try out the format you gave me for the files, and yes: > that's exactly how I had it.

Re: [Tutor] inheritance and super() function in python

2014-04-22 Thread Steven D'Aprano
On Tue, Apr 22, 2014 at 08:59:59PM -0400, Jorge Leon wrote: > Thank you Steve and Dave for the prompt response and advise, and sorry > about the format. > > The version of Python I'm working under is 2.7.5. About the .super(): > I'm going to try out the format you gave me for the files, and yes: >

Re: [Tutor] inheritance and super() function in python

2014-04-22 Thread Jorge Leon
Thank you Steve and Dave for the prompt response and advise, and sorry about the format. The version of Python I'm working under is 2.7.5. About the .super(): I'm going to try out the format you gave me for the files, and yes: that's exactly how I had it. Something that has stuck from all the C++

Re: [Tutor] inheritance and super() function in python

2014-04-22 Thread Dave Angel
Jorge Leon Wrote in message: > I think Steven has nailed your main problem, but I have two other suggestions: Use text mail, not html. This is a text list, and it can make a difference in half a dozen ways. Any decent email program has a way to select that. When showing an error, include

Re: [Tutor] inheritance and super() function in python

2014-04-22 Thread Steven D'Aprano
On Tue, Apr 22, 2014 at 09:48:51AM -0400, Jorge Leon wrote: > Good day, > > > I have programmed a base class for an environment I have with no problem, > but when it comes to referencing the base class's constructor in the > derived class's constructor I have been getting errors: What version of

[Tutor] inheritance and super() function in python

2014-04-22 Thread Jorge Leon
Good day, I have programmed a base class for an environment I have with no problem, but when it comes to referencing the base class's constructor in the derived class's constructor I have been getting errors: *TypeError: Error when calling the metaclass bases* *module.__init__() takes at mos