Message249924
pip doesn't really support being called as an API, there's been requests for it before but nobody has yet come forward to specify what parts in particular they need. The practical effect of this is that there's no backwards compatibility promises for anything you import from pip currently. I would suggest using a subprocess to communicate with pip unless you can define what operations you need so the pip developers can settle on a real public API for them.
As for your actual questions:
1. I'm pretty sure it requires restarting the process because pkg_resources has a cache and pip currently isn't designed in a way that it assumes you're going to freeze in anything but it's own process.
2. I think this depends on what version of of Python it's being used with and where the user installed it to. I think Steve Dower has switched Python 3.5's default install location to Program Files which does require it to be run as an administrator if you want to install into the site-packages instead of the user packages directory. |
|
Date |
User |
Action |
Args |
2015-09-05 20:46:51 | dstufft | set | recipients:
+ dstufft, rhettinger, terry.reedy, paul.moore, ncoghlan, peter.otten, BreamoreBoy, Marcus.Smith, Saimadhav.Heblikar |
2015-09-05 20:46:51 | dstufft | set | messageid: <1441486011.63.0.996081240509.issue23551@psf.upfronthosting.co.za> |
2015-09-05 20:46:51 | dstufft | link | issue23551 messages |
2015-09-05 20:46:51 | dstufft | create | |
|