I was writing some documentation for physics/units.py and discovered
some infinite recursion RuntimeError:
>>> from sympy.physics.units import joule
>>> joule
....
File "/home/luke/repos/sympy/sympy/core/expr.py", line 140, in __lt__
return C.StrictInequality(self, other)
File "/home/luke/repos/sympy/sympy/core/relational.py", line 128, in __new__
return rop_cls._eval_relation(lhs.evalf(), rhs.evalf())
File "/home/luke/repos/sympy/sympy/core/relational.py", line 185, in
_eval_relation
return lhs < rhs
File "/home/luke/repos/sympy/sympy/core/decorators.py", line 75, in
__sympifyit_wrapper
return func(a, sympify(b, strict=True))
File "/home/luke/repos/sympy/sympy/core/expr.py", line 137, in __lt__
dif = self - other
File "/home/luke/repos/sympy/sympy/core/decorators.py", line 75, in
__sympifyit_wrapper
return func(a, sympify(b, strict=True))
File "/home/luke/repos/sympy/sympy/core/decorators.py", line 115, in
binary_op_wrapper
return func(self, other)
File "/home/luke/repos/sympy/sympy/core/expr.py", line 86, in __sub__
return Add(self, -other)
File "/home/luke/repos/sympy/sympy/core/expr.py", line 70, in __neg__
return Mul(S.NegativeOne, self)
File "/home/luke/repos/sympy/sympy/core/cache.py", line 100, in wrapper
return func_cache_it_cache[k]
File "/home/luke/repos/sympy/sympy/core/numbers.py", line 1100, in __hash__
return super(Integer, self).__hash__()
File "/home/luke/repos/sympy/sympy/core/numbers.py", line 797, in __hash__
return super(Rational, self).__hash__()
File "/home/luke/repos/sympy/sympy/core/numbers.py", line 193, in __hash__
return super(Number, self).__hash__()
RuntimeError: maximum recursion depth exceeded while calling a Python object
Bug report filed here:
http://code.google.com/p/sympy/issues/detail?id=2461
~Luke
--
"Those who would give up essential liberty to purchase a little
temporary safety deserve neither liberty nor safety."
-- Benjamin Franklin, Historical Review of Pennsylvania, 1759
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sympy?hl=en.