[tex-live] Missing package in TeX Live

Geoffrey Poore gpoore at gmail.com
Thu Sep 12 03:52:03 CEST 2013


Hi Karl and Akira,

Imports shouldn't be an issue.  Up to now, I and my users have used an
installation script that copies the PythonTeX files into the texmf tree,
creating a standard directory structure and a wrapper/symlink.  Basically,
the installer replicates the configuration of a typical package in TeX
Live.  That system has functioned fine.

Python's sys.path is a list of search paths for imports.  The first
element, sys.path[0], is always the location of the initial script that was
started.  So as long as the main script (pythontex.py) and all the other
scripts are in the same directory, then pythontex.py can always import all
the other code.  The only reason to use kpsewhich would be if the scripts
were in multiple directories.  I actually used kpsewhich at first, until I
realized that sys.path[0] already contained everything I needed.

Let me know if you do encounter any issues with import or self-location,
and I'll find a fix.

Regards,
Geoff Poore



On Wed, Sep 11, 2013 at 8:04 PM, Akira Kakuto <kakuto at fuk.kindai.ac.jp>wrote:

> Hi Karl,
>
>
>  Thanks for writing.  I looked at it when you first released it.  As far
>> as I can tell, it wasn't self-locating, that is, those import statements
>> in pythontex.py would fail when run from TL.  So it seemed pointless to
>> add it.
>>
>
> I think the latest version is self-locating, because I've just confirmed
> that
> pythontex --help
> works with python scripts in $TEXMF/scripts/pythontex
> by using a wrapper pythontex.exe in W32TeX.
>
> Best regards,
> Akira KAKUTO
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/tex-live/attachments/20130911/daa819a5/attachment.html>


More information about the tex-live mailing list