pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: www/py-bottle should not use suffix .py for binaries



> Some time ago I created a package for conan in wip/py-conan.
> Until now I myself only used the conan client, but when I tested conan_server it failed.
> 
> Conan_server, turned out, uses python bottle web framework (www/py-bottle) which happens to install a binary bottle.py into $PREFIX/bin. So when conan_server tries to import bottle it looks for it (as it should) in $PROFIX/lib/python3.7/site-packages but first in the directory from which the binary was started, i.e. $PREFIX/bin. 
> So it tries to import $PREFIX/bin/bottle.py as module instead of the one from lib/python-3.7/site-packages.
> 
> It fails because www/py-bottle uses ALTERNATIVES and $PREFIX/bin/bottle.py is not a python script but a shell wrapper.
> 
> Actually, even if it was a python script (if no ALTERNATIVES were used) it would still be wrong.
> 
> So I suggest to install binaries without .py suffix (as it is done in many other python packages).

I agree, .py suffix for binaries is problematic.
I've changed the package as you requested.

Thanks,
Adam


Home | Main Index | Thread Index | Old Index