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

Re: [HTCondor-users] virtualenv, pip and htcondor (python)

On Jul 10, 2015, at 5:46 AM, L Kreczko <L.Kreczko@xxxxxxxxxxxxx> wrote:

Dear all,

I am currently trying to use the htcondor python bindings in our code, but I could not find a good way to make this possible.

The setup:
The experiment framework sets up a separate python version (2.7) that is newer than the OS default. On top of that our code uses virtualenv (https://github.com/pypa/virtualenv) that allows you to create an isolated python environment.

While the htcondor python bindings are available for the OS python (2.6) they are not for anything above.

So, is it possible to setup htcondor via pip or similar?

A possible solution is to symlink the OS libraries to the virtualenv installation, but there must be a better way than this:
ln -s /usr/lib64/python2.6/site-packages/htcondor.so external/vpython/lib/python2.7/site-packages/htcondor.so
ln -s /usr/lib64/python2.6/site-packages/classad.so external/vpython/lib/python2.7/site-packages/classad.so

Hi Luke,

You can always recompile HTCondor and point it to an alternate python install.  Thatâs what I do when I need to use a non-OS python.

However, Iâm stumped on how it could be converted to something I can upload into PyPI.  Suggestions?