• Kirill Smelkov's avatar
    gpython: Detect buildout and don't expect exedir to be on sys.path[0] in that case · 92bb5bcc
    Kirill Smelkov authored
    When buildout generates scripts, it injects the following prologue for
    them:
    
       #!/path/to/underlying/python
    
       import sys
       sys.path[0:0] = [
         'path/to/egg1',
         'path/to/egg2',
         ...
       ]
    
       import SCRIPT
       SCRIPT.main()
    
    This way path to eggs are inserted before what was originally
    sys.path[0] and it breaks gpython check that `sys.path[0] == exedir`.
    
    -> Fix it by detecting buildout and in that case verifying that exedir
    is only present in sys.path, not located in sys.path[0].
    92bb5bcc
Name
Last commit
Last update
3rdparty/include/linux Loading commit data...
golang Loading commit data...
gpython Loading commit data...
.gitignore Loading commit data...
CHANGELOG.rst Loading commit data...
COPYING Loading commit data...
MANIFEST.in Loading commit data...
README.rst Loading commit data...
pyproject.toml Loading commit data...
setup.py Loading commit data...
tox.ini Loading commit data...
trun Loading commit data...