Using pip install with Python embedded

I’m using Python embedded in my app and I need to install some dependencies with PIP. Once I don’t have the Python executable available, I need to use PIP main to install my dependencies, but it is alwayes warning up that is going to fail in future version of pip:

WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see ImportError in system pip wrappers after an upgrade · Issue #5599 · pypa/pip · GitHub for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with ‘-m pip’ instead of running pip directly.

My only options is to use PIP directly as a module, instead of using it called by Python’s executable.

It looks like is goes out of scope through embedded apps :confused:

Any suggestions?

Hi, @shadowplayz.

I think I was missunderstood. My point is I have Python embedded, then I don’t have access to the Python executable path to run pip in a new process. Therefore I need to run pip main to install modules, which results in that warning.