Conversion failure for older format

José Abílio Matos jamatos at lyx.org
Tue Jun 21 16:27:12 UTC 2022


On Tuesday, 21 June 2022 13.44.01 WEST Rudi Gaelzer wrote:
> Hits a snag right at the beginning:
> 
> rudi at stix|Plasma Modes>python2 /usr/share/lyx/lyx2lyx/lyx2lyx Langmuir-
> lyxformat-508.lyx > /dev/null
>   File "/usr/lib64/python3.10/site.py", line 93
>     print(message, file=sys.stderr)
>                        ^
> SyntaxError: invalid syntax

This is problematic on so many levels. :-)
Notice that your python2 is using python3's standard library and so the 
disaster is unavoidable.

Something is wrong with your python2 installation because that should not 
happen in a regular Fedora installation. I am not even sure if that could have 
been caused by setting PYTHONPATH...

I have just tested a similar call like the one above and it works for me.

One way to solve the problem in lyx is to install the 
python-unversioned-command package.
That will make /usr/bin/python point to python3 because currently lyx is 
getting python2 as the python version and thus the error that you get. But 
again in this case this is just a workaround the problem that you have.

I hope that this helps.
-- 
José Abílio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lyx.org/pipermail/lyx-users/attachments/20220621/2dc68cfa/attachment.html>


More information about the lyx-users mailing list