![]() ![]() Posixpath.join(main_index_url.url, version)] + locationsįile_locations, url_locations = self._sort_locations(locations) If url_name is not None and main_index_url is not None: # implementations might break if they relied on easy_install's behavior.įor url in all_index_urls] + self.find_links # (and PyPI can handle it without the slash) some other index ![]() # For maximum compatibility with easy_install, ensure the path ![]() # adding more index URLs from requirements filesĪll_index_urls = self.index_urls + self.mirror_urls # Combine index URLs with mirror URLs here to allow Url_name = self._find_url_name(Link(self.index_urls), url_name, req) or req.url_name Page = self._get_page(main_index_url, req) # This will also cache the page, so it's okay that we get it again later: Main_index_url = Link(posixpath.join(self.index_urls, url_name)) # Check that we have the url_name correctly spelled: # Only check main index if index URL is given: But hopefully this helps.įrom pip.exceptions import DistributionNotFoundįrom pip.index import PackageFinder, Linkĭef find_requirement(self, req, upgrade): I can't guarantee for the correctness, as I'm not familiar with pip's code. The script expects one package name as first and only argument and returns all versions. The code below is almost a 1:1 copy of the original function, with the return in line 114 changed to return all versions. Its method find_requirement looks up the versions of a InstallRequirement, but unfortunately only returns the most recent version. Pip 1.0 from /usr/lib/python2.7/dist-packages (python 2.7)Īfter looking at pip's code for a while, it looks like the code responsible for locating packages can be found in the PackageFinder class in pip.index. To not install any package, use one of following solution: pip install -no-deps -no-install flask -v ![]() Running setup.py egg_info for package web.py Use pip install -v, you can see all versions that available pip install web.py -v Use the yolk3k issue tracker instead and consider submitting a fix, if possible.Īs of Sep 2017 this method no longer works: -no-install was removed in pip 7 If something doesn't seem to work as it should, leaving a comment here should not make much difference. Note: I am not involved in the development of yolk3k. Though yolk is no longer maintained (as indicated in comments below), yolk3k appears to be and supports Python 3. Yolk3k is a fork of the original yolk which ceased development in 2012. to see what versions of Django are available: $ pip install yolk3k However it's not very convenient if you're working with multiple environments/hosts because you will have to copy/create it every time.Ī better all-around solution would be to use yolk3k, which is available to install with pip. Chris's answer seems to have the most upvotes and worked for me) (update: As of March 2020, many people have reported that yolk, installed via pip install yolk3k, only returns latest version. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |