The recent evolution of Sage seems to break the print(eval(read)) equivalence : sage: var("a0, a1") (a0, a1) sage: "%s"%a0^a1 'a0^a1'
So far so good. But : sage: eval("%s"%a0^a1) --------------------------------------------------------------------------- RuntimeError Traceback (most recent call last) Cell In[54], line 1 ----> 1 eval("%s"%a0**a1) File <string>:1 File /usr/local/sage-10/local/var/lib/sage/venv-python3.12.5/lib/python3.12/site-packages/sage/structure/element.pyx:952, in sage.structure.element.Element.__xor__ (build/cythonized/sage/structure/element.c:16917)() 950 951 def __xor__(self, right): --> 952 raise RuntimeError("Use ** for exponentiation, not '^', which means xor\n" 953 "in Python, and has the wrong precedence.") 954 RuntimeError: Use ** for exponentiation, not '^', which means xor in Python, and has the wrong precedence. But, inconsistently : sage: "%s"%a0**a1 'a0^a1' In other words, Sage insists for reading x**y and for printing x^y. Unless I’m missing something, *these choices are inconsistent*. Should I file an issue ? -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/sage-support/5bbd0d4d-66a6-4096-b3d0-94319a01ed7cn%40googlegroups.com.