I've run into a problem with the pywork/redo_xml.sh script at Cologne, for several dictionaries.
Previously, this occurred for dictionaries mw and lan. And today it occurred for dictionary ae.
The problem regards what 'python' means.
When 'python --version' occurs in a terminal session, the result is:
> python --version
Python 3.4.10
But make a script, call it temp.sh:
python --version
And run this script in a terminal
> sh temp.sh
Python 2.6.6
In my .bashrc file at Cologne, there is an alias:
> grep python ~/.bashrc
alias python='/usr/bin/python3'
But apparently this does not carry over into scripts.
Current solution
I change redo_xml.sh to use 'python3' when run at Cologne.
Recall that every time we remake a dictionary, we recreate the scripts by means of a mako template.
In this case, the redo_xml.sh mako template
At lines 10 and following, the template now looks like:
I've run into a problem with the pywork/redo_xml.sh script at Cologne, for several dictionaries.
Previously, this occurred for dictionaries mw and lan. And today it occurred for dictionary ae.
The problem regards what 'python' means.
When 'python --version' occurs in a terminal session, the result is:
But make a script, call it temp.sh:
And run this script in a terminal
In my .bashrc file at Cologne, there is an alias:
But apparently this does not carry over into scripts.
Current solution
I change redo_xml.sh to use 'python3' when run at Cologne.
Recall that every time we remake a dictionary, we recreate the scripts by means of a mako template. In this case, the redo_xml.sh mako template
At lines 10 and following, the template now looks like:
The logic for pw and pwg is slightly different, and those two dictionaries still use
python make_xml.py ...
.