New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shadowing Fricas function names leads to results un-backtranslatable to Sage. #31849
Comments
comment:1
There are similar problems with other interfaces as well, such as Giac #30133. |
comment:2
I think the problem is here:
In line -4, we check whether |
Commit: |
comment:4
It might make sense to move the imports and the New commits:
|
Author: Martin Rubey |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:11
Emmanuel, could you have a look, please? |
comment:13
Frederic, do you have a minute for this one? |
comment:14
Travis, could you have a quick look, please? I think it would be good to have this in the next release. |
comment:15
Do we always want to continually recreate the Also, could you revert this change as the line ends after diff --git a/src/sage/interfaces/fricas.py b/src/sage/interfaces/fricas.py
index a73330e..faac5e2 100644
--- a/src/sage/interfaces/fricas.py
+++ b/src/sage/interfaces/fricas.py
@@ -1281,8 +1281,7 @@ class FriCASElement(ExpectElement):
@staticmethod
def _parse_other(s, start=0, make_fun=False):
- """
- Parse the initial part of a string, assuming that it is an
+ """Parse the initial part of a string, assuming that it is an
atom, but not a string.
Symbols and numbers must not contain ``FriCASElement._WHITESPACE`` and |
comment:16
Would the following at module level be OK? (It works, but I am not sure about coding style.) There is also a warning: "resolving lazy import infinity during startup"
|
comment:17
Yes, that would be good. Although you don't need to lazily import |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:19
Done! (I would have liked to do the same with the long sequence of |
comment:20
Thank you. I don't immediately know what would cause that circular import. Of course, the ideal thing would be to remove the circular import, but if that is not feasible, your solution of doing something in the Are you going to do that on this ticket or a separate one? |
Reviewer: Travis Scrimshaw |
comment:21
I think it is better to do this in a separate ticket, because doing so I discovered a bug in the I opened #32133 for the translation, and I'll do the move there as a first step. |
comment:22
Okay, positive review. |
Changed branch from u/mantepse/shadowing_fricas_function_names_leads_to_results_un_backtranslatable_to_sage_ to |
Motivation : this ask.sagemath question.
Contemplate :
Bandwidth savings : Snip...
But :
The cherry on the pie :
The use of the variable
D
shadows the Fricas functionD
, which is not a problem for Fricas, but is not known to thefricas._sage_()
method, which uses hardcoded equivalences for categorizing syntactic trees' atoms.CC: @mwhansen @mantepse @slel @fchapoton @tscrim
Component: interfaces
Keywords: symbolic fricas interface
Author: Martin Rubey
Branch/Commit:
52099de
Reviewer: Travis Scrimshaw
Issue created by migration from https://trac.sagemath.org/ticket/31849
The text was updated successfully, but these errors were encountered: