cos: "Integer Required"?!?!?!?
mikael at isy.liu.se
Thu Jun 8 17:51:22 CEST 2006
> print self.ACphi, type(self.ACphi) yields:
> 19412557 <type 'int'>
> value = XPLMGetDataf(self.ACphi); print value type(value ) yields:
> -0.674469709396 <type 'float'>
> print math.radians(XPLMGetDataf(self.ACphi)),
> type(math.radians(XPLMGetDataf(self.ACphi))) yields:
> an integer is required
> Am I totally missing something about 'math'. Does it really expect an
Not my Python:
This all seems very confusing. Have you tried exactly the above?
Do you perhaps have a module of your own called math, that Python might
be importing? Or is your math not a module, but some other object that
happens to have a method called radians, that expects an int? Or have
you accidentally redefined math.radians?
More information about the Python-list