Ask Your Question
0

SageTex, sage, version conflict?

asked 2019-08-30 01:54:19 +0200

JC gravatar image

Hello to everyone,

I am trying to use sagetex in my ubuntu18.094 machine. I use the file from this manual. I call my file Test.tex

PdfLatex does its job. I have a Test.sagetex.sagefile in my folder. When I run, at the same folder, from a terminal sage Test.sagetex.sage I get the following error

Traceback (most recent call last):

File "Test.sagetex.sage.py", line 9, in <module>

_st_ = sagetex.SageTeXProcessor('Test', version='2015/08/26 v3.0-92d9f7a', version_check=True)

File "... Programs/sage-8.1/local/lib/python2.7/site-packages/sagetex.py", line 76, in __init__

raise VersionError(errstr)

sagetex.VersionError: versions of .sty and .py files do not match.

Test.sagetex.sage was generated by sagetex.sty version "2015/08/26 v3.0-92d9f7a", but

is being processed by sagetex.py version "2019/01/09 v3.2".

Please make sure that TeX is using the sagetex.sty

from your current version of Sage; see...

I built sage from the source code, at some point, then I upgraded with sage update. I now have sage 8.8 but still a folder sage-8.1

I installed sagetex from the repos.

Anyone a suggestion?

Thanks!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-08-30 16:35:08 +0200

Emmanuel Charpentier gravatar image

It depends how you installed the correct SageTeX version in your TeX tree.

I tend to follow this unorthodox procedure

  • (Optionnaly): recompile sagetex.dtx and its indexes in $SAGE_ROOT/local/share/tex/latex/sagetex/. This gives you an updated documentation.
  • (as root) create a symlink to this directory somewhere in your TeX tree (I use a subtree of what is pointed by TEXMFLOCAL, see below...)
  • (still as root) texhash $(kpsewhich -var-value=TEXMFLOCAL)
  • (Optionally) symlink the generated documentation in your texdoc tree (highly distribution dependant...).

Of course, this has to be refreshed every time you update Sage...

edit flag offensive delete link more

Comments

Hello @EmmanuelCharpentier Thanks for taking the time. I am sorry your answer is a little bit obscure to me : I do not know how to perform the steps you suggest.

Would it be possible to add some feature so that upgrading sage does not break sagetex?

JC gravatar imageJC ( 2020-03-19 02:47:51 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2019-08-30 01:54:19 +0200

Seen: 223 times

Last updated: Aug 30 '19