Closed Etn40ff closed 4 months ago
I thought I had dealt with it before. I think we had a discussion about the default path. Let me check a few things. In any case thanks for signalling.
It should work via this line https://github.com/sagemath/sage/blob/7dfff8b1be091468140cba0e7042ef8670e4603f/src/sage/features/threejs.py#L33
given that on sage-on-gentoo SAGE_SHARE
is /usr/share
. Can you attach the kind of error you get? Whatever it is, we should get to the bottom of it.
I do not get any error at all in sage: I just get an empty browser whenever I plot something.
Figuring out this it took a while: in the browser console I got an error about THREE
not being defined and I noticed that threejs.min.js
is not imported; then worked my way back from there to
sage: from sage.features.threejs import Threejs
sage: Threejs().absolute_filename()
''
I think that I understand why the line you point out is not working: it points to /usr/share/sage/sage/threejs
rather than /usr/share/sage/threejs
.
That would be the case in "vanilla" sage. It should not be in sage-on-gentoo and if it does it is a regression.
OK, I am going senile and you are right. I must have thought of things in reverse or I made a mistake at some point.
I must have had brain fog when it has gone in or I was thinking of a far future. https://github.com/cschwan/sage-on-gentoo/commit/3db5268745a6cfa9e9c4c7eacd4c4fc64d0cd1e0 I will restore the setting this morning.
tnks
I have bumped sage-conf since I updated what is installed by it. It should be pulled automatically. There is a delay of up to 15mn before the gentoo mirror of the overlay is updated.
LGTM
Thanks again
It looks like the new mechanism to import threejs introduced with https://github.com/sagemath/sage/commit/7dfff8b1be091468140cba0e7042ef8670e4603f breaks threejs plotting because it is not installed in one of the supported paths.
An easy fix is to move the installation path from
/usr/share/sage/threejs/
to/usr/share/sage/threejs-sage