1
1
Fork 0
mirror of https://github.com/pypa/pip synced 2023-12-13 21:30:23 +01:00
Commit graph

473 commits

Author SHA1 Message Date
Donald Stufft
81a5bcf7cd Misc updates (#4056)
* Update AUTHORS.txt

* Remove --columns which has been superseded by --format=columns
2016-11-02 14:08:37 -04:00
Xavier Fernandez
8f171cd212 Fix environment markers evaluation - issue #3829 (#4051) 2016-11-02 08:28:17 -04:00
Donald Stufft
2fb6e6bae5 Ignore comments in pip freeze -r requirements.txt (#4046) 2016-10-30 18:09:38 -04:00
Donald Stufft
765d52e6bd Let the search service handle search order (#4044) 2016-10-30 15:17:10 -04:00
Xavier Fernandez
c96f850b17 Merge pull request #3904 from minrk/egg-link-priority
don't assume egg-link corresponds to dist to uninstall
2016-10-29 14:39:50 +02:00
Xavier Fernandez
e53e2247d9 Canonicalize extras before matching them - Fix issue #3810 (#4037)
Canonicalize InstallRequirement.extras

since dist.extras are already canonicalized, pip needs to canonicalize
extras before matching them with dist.extras

Fixes #3810
2016-10-29 14:25:05 +02:00
Xavier Fernandez
b1720f303b Fix test_pip_wheel_builds_when_no_binary_set for Python 3.6
setuptools 0.9.8 was not compatible with Python 3.6
Let's use our simple-3.0.tar.gz file instead.
2016-10-28 17:22:21 +02:00
Xavier Fernandez
05c2d21f26 Add tests for python_requires
and cleanup when install is aborted
2016-10-27 18:43:59 +02:00
Maxim Kurnikov
84e9265970 add canonicalize_name() call to show 2016-10-11 17:09:41 +02:00
Xavier Fernandez
2856e63cf5 Add --not-required to list command. (#3986) 2016-10-05 14:45:59 +02:00
nvdv
88d2bd8165 Rename --no-deps-only to --not-required. 2016-10-05 15:03:03 +03:00
nvdv
bb896cb44c Add functional test for 'list --no-deps-only' option. 2016-09-30 15:07:10 +03:00
c22
f4320aa1f0 Updated "none shell" test 2016-09-23 09:20:38 +10:00
c22
4e2b5c7d00 Update test_completion.py
Fixed the test and got the line length < 80
2016-09-23 09:20:38 +10:00
c22
aef0254953 Added pip completion support for fish shell. 2016-09-23 09:19:47 +10:00
Pradyun
807f879422 Add an upgrade-strategy option (#3972) 2016-09-18 16:48:01 -04:00
Donald Stufft
403e398330 Deprecate --egg (#3956) 2016-09-07 16:43:58 -04:00
Min RK
b8f31ac522 test uninstall after both install and -e
this used to fail with SETUPTOOLS_SYS_PATH_TECHNIQUE=raw
2016-08-26 14:40:01 +02:00
Xavier Fernandez
3417fac05e Merge pull request #3898 from xavfernandez/check_if_exists_editable
Make pip install -e uninstall existing versions
2016-08-18 17:07:46 +02:00
Xavier Fernandez
5bd3367644 Merge pull request #3760 from patricklaw/pl.pip-install-additional-options
Pl.pip install additional options
2016-08-12 10:27:57 +02:00
Paul Moore
84c969669c Merge pull request #3724 from yamt/norm-path
Normalize file URLs
2016-08-09 18:23:56 +01:00
Xavier Fernandez
65a82a2eb0 Always check_if_exists for editable
But only when pip has collected the editable package's metadata.

closes #1548
2016-08-05 22:42:22 +02:00
Xavier Fernandez
73fc56e613 Merge branch 'pr/1552' into check_if_exists_editable 2016-08-05 22:11:13 +02:00
Xavier Fernandez
2badb05d19 Fix test_download_wheel
Use local path instead of bitbucket
2016-07-31 22:33:03 +02:00
Bruno Oliveira
c73abf81db Avoid importing TestFailure at the top level
This will make pytest-3.0 emit a warning:

cannot collect test class 'TestFailure' because it has a __init__ constructor
2016-07-28 21:36:45 -03:00
Paul Moore
c7e5f52c96 Merge pull request #3858 from cdosborn/master
Make pip show less verbose
2016-07-27 09:47:47 +01:00
Connor Osborn
ce868f9742 Increase pip show test coverage 2016-07-26 18:59:22 -07:00
Connor Osborn
357123fcf4 Fix existing tests for pip show with --verbose 2016-07-26 18:59:22 -07:00
Patrick Lawson
bbe99ce62d Add --implementation and --abi parameters to `pip download`.
Add thorough tests, usage documentation, and handle some merge issues.
2016-07-21 13:01:52 -05:00
Mathew Jennings
9a4be9b281 Add --platform and --python-version to pip download.
With the --platform option, a user can download wheels with
a different platform than that of the local machine running the command.

With the --python-version option, a user can
download wheels that are explicitly compatible with a specific
Python interpreter version.

This functionality is meant for utilities that gather dependencies
and prepare distributions for other platforms.
2016-07-21 13:01:52 -05:00
Pradyun S. Gedam
8b4ebc1ee5 Improve UX and tests of check command
This should really be 3 atomic commits but I'm short on time.

- Prints a message on clean environment
- Marked tests as network based
- Added helper that matches lines irrespective of order.
2016-06-26 19:53:38 +05:30
Paul Moore
d7444b784a Merge pull request #3750 from msabramo/check_command_rebase_develop
Add a `pip check` command.
2016-06-25 16:54:52 +01:00
Pradyun
e04941bba2 Update http urls to use https instead (#3808) 2016-06-22 14:06:28 -04:00
Jakub Wilk
6dc28c1b31 Fix typos 2016-06-10 21:29:43 +02:00
Donald Stufft
c4b30a460a Merge branch 'develop' 2016-05-26 07:02:32 -04:00
Calvin Smith
46b682221b Support multiple --requirement files in pip freeze (#3703) 2016-05-26 06:45:46 -04:00
Jivan Amara
36de76f0a5 Strip authentication from SVN url prior to passing it into svn (#3697) 2016-05-26 06:43:26 -04:00
Stéphane Bidoul (ACSONE)
4d1b798465 Allow creating wheels for editable packages (#3695) 2016-05-26 06:41:01 -04:00
Andy Kluger
e445dba634 Fix crash when calling pip freeze with invalid requirement installed (#3704) 2016-05-26 06:36:16 -04:00
Stéphane Bidoul (ACSONE)
ce76f2d3e6 Give priority to git remote named origin in pip freeze (#3708) 2016-05-21 08:12:37 -04:00
Xavier Fernandez
91afd80a39 Fix a bunch of other tests
Add a --no-index to avoid network calls
2016-05-19 15:31:46 +02:00
Xavier Fernandez
1e8b6c2fe7 Improve tests
Demote "Ignoring indexes" log to DEBUG to enable stdout JSON parsing
2016-05-19 15:31:46 +02:00
Xavier Fernandez
5bbc73d145 Add --format option to pip list
with legacy, columns, freeze and json formats
2016-05-19 15:31:46 +02:00
Douglas Thor
6dcd9dac2e Added --columns, --no-columns option to pip list. Fixes #3651 (#3654) 2016-05-12 13:13:48 -04:00
Ian Wienand
ec08a590d8 Root logger should use debug level for "--log" (#3586)
We want the root logger to output debug level logs when we have
specified "--log".  The log-file handler then sends this to our file,
and the other handlers (console) filter out at their appropriate
level.

This restores the intended behaviour of "--log" argument, which is
supposed to output verbose logs to a file always.

A test-case is added

Closes: #3351
2016-05-10 19:05:42 -04:00
burrows
3c11bb4de9 Give markers chance to remove incompat wheel links
`pip install -r reqs.txt` was failing when the requirements file includes
an unsupported wheel, regardless of whether it is conditionally removed
by a marker. This patch fixes that issue.

Additionally, this patch makes pip check local file wheels for
compatibility. Previously, a requirements file could include a path
to a valid wheel for any platform and pip would happily install it.
2016-04-07 13:00:03 -04:00
YAMAMOTO Takashi
742b9258d2 Normalize file URLs
It seems pip distinguishes paths with .. or extra / for constraints.
For example, the following directories are considered different.

    /path/to/dir
    /path/to//dir
    /path/to/dir/subdir/..

It can lead "Could not satisfy constraints for 'xxxx':
installation from path or url cannot be constrained to a version"
error, whose cause is not obvious to users. [1]

This commit tries to normalize the given directory name to avoid
the error.

[1] https://bugs.launchpad.net/devstack/+bug/1542545
2016-03-22 21:17:55 +09:00
Xavier Fernandez
09233da9d7 Hide the line if installer is unknown 2016-03-04 16:10:59 +01:00
Xavier Fernandez
dc533f8469 show: add PEP376 INSTALLER information
closes #3517
2016-03-04 13:55:39 +01:00
Xavier Fernandez
a0d6210905 pip.show: always show classifiers 2016-03-04 11:12:34 +01:00
Xavier Fernandez
dc1e89d854 Add --classifiers option to pip show 2016-03-04 11:12:11 +01:00
Donald Stufft
a1e308d847 Merge pull request #3458 from xavfernandez/freeze_all
Add --all option to pip freeze
2016-03-03 07:23:32 -05:00
Xavier Fernandez
5055d05a9a Fix always true assertion 2016-03-03 10:32:06 +01:00
Xavier Fernandez
01cd191402 Merge pull request #3505 from njsmith/fix-verbose-subprocess-output
Fix display of subprocess output when --verbose is given
2016-02-24 22:42:23 +01:00
Nathaniel J. Smith
113394250e Fix display of subprocess output when --verbose is given
Closes #3486
2016-02-23 15:13:55 -08:00
Xavier Fernandez
2956a3ef41 Add --all option to pip freeze
In order to include pip/setuptools/wheel in the freeze output
Closes #1610
2016-02-17 13:29:32 +01:00
Xavier Fernandez
8233a83299 Merge pull request #3455 from bukzor/enable-warning-filters
enable python -W with respect to PipDeprecationWarning
2016-02-11 10:24:30 +01:00
Buck Golemon
584d96bfe9 add tests 2016-02-08 15:29:25 -08:00
Buck Golemon
9dabcffc80 we should expect that --no-use-wheel is deprecated 2016-02-08 11:27:17 -08:00
Stéphane Bidoul
1d759b3afa Allow installing modules from a vcs subdirectory in non-editable mode 2016-02-08 16:42:54 +01:00
Francesco Montesano
ab9c66e77d no need for expect_stderr 2016-02-02 13:50:46 +01:00
Francesco Montesano
a5a9c2191d test uninstall of entry points with colons in name 2016-02-02 13:50:46 +01:00
Nathaniel J. Smith
af675e7797 Make install --quiet really quiet
Commit 5bb989993 added some code for hiding/showing the cursor when
running on the terminal, but accidentally made it so that it always
printed the invisible control codes, even when not on a tty or when
--quiet was specified. This turns out to be surprisingly bad (e.g. it
breaks the official docker python builds). So, let's not do that.

Fixes gh-3418
2016-02-01 14:59:06 -08:00
Xavier Fernandez
48627ff97a Merge pull request #3412 from rygwdn/fix-freeze
pip freeze: handle new requirements options.
2016-01-31 23:15:07 +01:00
Xavier Fernandez
24dc9b6361 Merge pull request #3372 from kaustavha/kaustavha/fix/double-reqs
fix(pip/req/req_set): Dont err on double reqs of the same spec
2016-01-25 23:48:22 +01:00
Donald Stufft
a2fdaefc97 Merge pull request #3389 from ianw/overwrite-distutils
Restore ability to uninstall distutils packages
2016-01-21 14:25:12 -05:00
Donald Stufft
3f77110899 Fix tests 2016-01-21 12:34:59 -05:00
Ryan Wooden
17fdbc8f8f pip freeze: handle new requirements options.
pip 8.0.0 added support for --pre, --trusted-host, and
--process-dependency-links to requirements files, but they were
not handled by freeze.
2016-01-21 10:55:43 -04:00
Donald Stufft
3172b4e7d6 This test doesn't actually work in practice :( 2016-01-21 09:08:36 -05:00
Robert Collins
7b2fbb069a Stop erroring on installs of argparse and wsgiref. 2016-01-21 13:49:49 +13:00
Xavier Fernandez
171a107c34 pip list: reenable prereleases filter
according to --pre option

broken in 7fcf75bb61

closes #3385
2016-01-20 15:12:00 +01:00
kaustav haldar
fbfa7fbcfe fix(pip/req/req_set): If double requirements exist which have the same specs, dont raise a double requirement given error 2016-01-19 22:25:25 -08:00
Ian Wienand
35a3e8b7f5 Restore ability to uninstall distutils packages
This is a partial revert of 6afc718307
to restore the ability to overwrite distutils installed packages.

It is not elegant, but some projects (such as OpenStack's devstack)
rely on overwriting packages installed via the system package manager.
These packages can't be removed because they are dependencies for
parts of the base system, but many of the things devstack needs to run
requires later dependencies.  For historical reasons it's not easy to
fix this into a virtualenv, etc, all at once.

If distributions move to setuptools based packages, this problem might
fix itself.
2016-01-20 16:57:04 +11:00
Xavier Fernandez
18b5fc2c44 pip.wheel: change --wheel-dir default value
From <current working directory>/wheelhouse to <current working
directory> only to be consistent with pip download behavior.
2016-01-19 22:42:22 +01:00
Donald Stufft
1ae7707e96 Default to downloading to the current directory 2016-01-19 13:05:34 -05:00
Donald Stufft
3b3978b994 Merge pull request #3284 from ncoghlan/pep376-installer-file
Record pip in INSTALLER file
2016-01-19 10:41:08 -05:00
Donald Stufft
35feedebc1 Merge pull request #3324 from jsbarber/develop
Fix for issue #2834 with test
2016-01-18 23:21:09 -05:00
Donald Stufft
3ae13b2e35 Merge pull request #3312 from sbidoul/no-branch-in-egg-name-sbi
stop the addition of the branch name in the #egg=... fragment
2016-01-18 18:04:03 -05:00
Xavier Fernandez
d1136dda3e Add support for .xz files (with python >=3.3)
Closes #722
2016-01-14 22:39:45 +01:00
Stéphane Bidoul
6f790d1d80 stop the addition of the branch name in the #egg=... fragment 2016-01-14 19:04:02 +01:00
Xavier Fernandez
21fb8a28f0 Dont raise on #egg metadata mismatch, just warn
Since pip 7, via pip freeze, is producing such mismatching #egg
fragment, forbidding them in pip 8 would be too strongly
backward-incompatible.
It is a partial rollback of 1a012bb6.
2016-01-14 00:30:02 +01:00
Jeff Barber
24a5cc6a42 Fix for issue #2834 with test 2016-01-03 17:38:36 -05:00
Donald Stufft
44feed107f Fix one more test that didn't expect stderr on 2.6 2016-01-01 22:36:18 -05:00
Donald Stufft
2202f868f8 Adjust the tests to be more forgiving of extra stderr output 2016-01-01 22:20:14 -05:00
Donald Stufft
15a06418b5 PyPI no longer supports external files so this test doesn't make sense 2016-01-01 14:38:28 -05:00
Xavier Fernandez
034232f0e0 Merge pull request #3317 from scop/spelling
Spelling fixes
2015-12-29 23:19:56 +01:00
Ville Skyttä
0da18e93b3 Spelling fixes 2015-12-27 00:58:23 +02:00
Xavier Fernandez
d9e0a057b0 Rename test and mark as network
since the wheel package now needs to be installed
2015-12-17 00:24:38 +01:00
Xavier Fernandez
8767f892fd Fix wheel path test of --user install with prefix
From b227c45a
2015-12-17 00:08:50 +01:00
Xavier Fernandez
9457300142 Fix tests when wheel is available in global site packages
Make sure we are installing via setuptools and not wheels so that we get
egg-info directories.
2015-12-16 00:12:18 +01:00
Stéphane Bidoul
52556056c4 fix a test that was relying on incorrect non-detection of an editable pkg 2015-12-04 14:40:24 +01:00
Stéphane Bidoul
7d7b50a990 add freeze test with git subdirectory and srcdir 2015-12-04 14:40:24 +01:00
Stéphane Bidoul
e905e651d4 fix test that was removing setup.py hence causing spurious errors 2015-12-04 14:40:24 +01:00
Nick Coghlan
a925c88ed6 Record pip in INSTALLER file 2015-12-04 19:22:19 +10:00
Xavier Fernandez
3f21828f75 Unify output of pip list & fix test 2015-11-29 17:37:45 +01:00
Xavier Fernandez
795798f3f0 Allow combination of pip list options
--editable with --outdated/--updtodate
closes #933
2015-11-29 17:37:45 +01:00
Xavier Fernandez
82c45bcf63 Add changelog and test 2015-11-26 23:49:26 +01:00
Marcus Smith
ca47dc9949 Merge pull request #3252 from domenkozar/install/prefix
Support pip install --prefix
2015-11-26 09:30:20 -08:00
Domen Kožar
b4bb2eee14 Support also pip install -e --prefix 2015-11-24 10:01:46 +01:00
Domen Kožar
7270d272f4 Make sure --user and --prefix install flags conflict 2015-11-22 19:23:22 +01:00
Domen Kožar
e14a66f1b9 Support --prefix argument to install command.
There was no way to override prefix for an installation for wheels
previously. The default it whatever sys.prefix points to.
2015-11-22 19:13:51 +01:00
Steve Kowalik
dc8e7f01dd Join constraints and requested extras
Compare extras when checking if a requirement has already been
specified, and take a union of the extras before installation.

Co-Authored-By: Sachi King <nakato@nakato.io>
Closes #3046, #3189
2015-11-20 18:05:17 +11:00
Donald Stufft
f39bc756e5 Merge branch 'develop' into hashes2 2015-11-06 18:46:09 -05:00
Donald Stufft
0e240d7dde Force the --python-tag when autobuilding wheels
A lot of existing tarballs will successfully build a wheel, but the
wheel will be implicitly broken because they will have dynamically
adjusted the install_requires inside of their setup.py. Typically
this is done for things like Python version, implementation, or what
OS this is being installed on. We don't consider cache directories
to be OS agnostic but we do consider them to be Python version and
implementation agnostic. To solve this, we'll force the cached
wheel to use a more specific Python tag that includes the major
version and the implementation.
2015-11-04 08:52:28 -05:00
Xavier Fernandez
0cc9d733bf Fix traceback.format_exc call
format_exc takes only one argument, limit which should be an integer.
python 2 seems more lenient than python 3 on that point.

mistake introduced in commit 3148b967a
2015-10-24 00:46:44 +02:00
Xavier Fernandez
89a27cd740 Special-case based on exception message 2015-10-22 23:15:02 +02:00
Erik Rose
622b430491 Typos and docstrings 2015-10-19 23:40:00 -04:00
Erik Rose
925e4b4466 Fix false hash mismatches when installing a package that has a cached wheel.
This would occur when, for example, installing from a requirements file that references a certain hashed sdist, a common situation.

As of pip 7, pip always tries to build a wheel for each requirement (if one wasn't provided directly) and installs from that. The way this was implemented, InstallRequirement.link pointed to the cached wheel, which obviously had a different hash than the index-sourced archive, so spurious mismatch errors would result.

Now we no longer read from the wheel cache in hash-checking mode.

Make populate_link(), rather than the `link` setter, responsible for mapping InstallRequirement.link to a cached wheel. populate_link() isn't called until until prepare_files(). At that point, when we've examined all InstallRequirements and their potential --hash options, we know whether we should be requiring hashes and thus whether to use the wheel cache at all.

The only place that sets InstallRequirement.link other than InstallRequirement itself is pip.wheel, which does so long after hashes have been checked, when it's unpacking the wheel it just built, so it won't cause spurious hash mismatches.
2015-10-19 23:40:00 -04:00
Xavier Fernandez
8cbb8af466 Report import setuptools error to the user
closes #2931
2015-10-19 16:43:01 +02:00
Erik Rose
9e5e34e9f7 Add --algorithm flag to pip hash. 2015-10-12 14:05:10 -04:00
Donald Stufft
9b29884fe9 Merge pull request #3066 from mattrobenolt/update-2
Only update VCS when things have actually changed
2015-10-08 16:26:18 -04:00
Erik Rose
7a0a97c081 Merge 'develop' into 'hashing' to bring the latter up to date. 2015-10-08 13:37:19 -04:00
Erik Rose
09008bf190 Add pip hash command. 2015-10-08 00:36:03 -04:00
Xavier Fernandez
1a012bb63b Abort installation on metadata mismatch
If setup.py egg_info produces metadata for a different project name than
self.req.project_name, abort the installation.
Fixes #3143
2015-10-01 23:40:27 +02:00
Paul Moore
908d07734c Merge pull request #3047 from tgs/clean_wheel_build_dir
Clean build dir if bdist_wheel fails
2015-09-29 09:19:39 +01:00
Erik Rose
0c17248998 Pass PEP 8 checks. 2015-09-24 22:16:00 -04:00
Erik Rose
11dbb92440 Switch from --sha256 etc. to a single option: --hash.
Everybody seems to favor this. Spelled -H, it's still pretty short. And it is less unusual programmatically.
2015-09-24 22:16:00 -04:00
Erik Rose
1e41f01823 Add checks against requirements-file-dwelling hashes for most kinds of packages. Close #1175.
* Add --require-hashes option. This is handy in deployment scripts to force application authors to hash their requirements. It is also a convenient way to get pip to show computed hashes for a virgin, unhashed requirements file. Eventually, additions to `pip freeze` should fill a superset of this use case.
  * In --require-hashes mode, at least one hash is required to match for each requirement.
  * Option-based requirements (--sha256=...) turn on --require-hashes mode implicitly.
  * Internet-derived URL-based hashes are "necessary but not sufficient": they do not satisfy --require-hashes mode when they match, but they are still used to guard against transmission errors.
  * Other URL-based requirements (#md5=...) are treated just like flag-based ones, except they don't turn on --require-hashes.
* Complain informatively, with the most devastating errors first so you don't chase your tail all day only to run up against a brick wall at the end. This also means we don't complain that a hash is missing, only for the user to find, after fixing it, that we have no idea how to even compute a hash for that type of requirement.
  * Complain about unpinned requirements when hash-checking mode is on, lest they cause the user surprise later.
  * Complain about missing hashes.
  * Complain about requirement types we don't know how to hash (like VCS ones and local dirs).
* Have InstallRequirement keep its original Link around (original_link) so we can differentiate between URL hashes from requirements files and ones downloaded from the (untrustworthy) internet.
* Remove test_download_hashes, which is obsolete. Similar coverage is provided in test_utils.TestHashes and the various hash cases in test_req.py.
2015-09-24 22:16:00 -04:00
Xavier Fernandez
0b1acf9726 Merge pull request #3085 from patricklaw/add-pip-download-command
Add `pip download` command and deprecate `pip install --download`.
2015-09-15 23:27:47 +02:00
Donald Stufft
11d96fb3c5 Merge pull request #2937 from nakato/i2928
Attempt to install editable packge defined in constraints should error
2015-09-14 16:54:18 -04:00
Xavier Fernandez
bb1812b99d Adapt search tests to new PyPI searches
- unmark test_multiple_search for failure
- search for nonexistentpackage instead of non-existent-package since PyPI
  seems to fallback to searches about "package" and manages to find
  things...
2015-09-14 10:01:57 +02:00
Mathew Jennings
417f79d8b8 Add pip download command and deprecate pip install --download.
`pip download` has the same functionality as `pip install --download`,
and the behavior of `pip install --download` is preserved with a deprecation
warning.  `pip install --download` will be removed in pip version 10.
2015-09-13 17:41:00 -04:00
Xavier Fernandez
5c3074a9b7 tests: fix test_search
The pip package description was changed in 2014 via af1d6d5
2015-09-11 14:26:35 +02:00
Thomas Smith
2bbb3be1ff Failing test: should clean up failed wheel build
Test for PR #3047
2015-09-09 15:16:51 -04:00
Donald Stufft
6afc718307 Remove items slated for removal in pip 8.0 2015-09-03 10:55:11 -04:00
Donald Stufft
0f5d4286a5 Deprecate and Noop the PEP 438 functionality due to PEP 470 2015-09-02 23:47:05 -04:00
Donald Stufft
638160a2ac Expect this test to fail until PyPI is fixed 2015-09-02 22:44:18 -04:00
Matt Robenolt
4c3ab41e90 Only update VCS when things have actually changed
This saves a network hop when using git and passing an explicit sha
as a ref by comparing the version that's already checked out.

Yields a ~4x speedup on my local machine

Before:
```
$ /usr/local/bin/pip --version
pip 7.1.0 from /usr/local/lib/python2.7/site-packages (python 2.7)
$ time /usr/local/bin/pip install --disable-pip-version-check -e git+https://github.com/getsentry/raven-python.git@56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e#egg=raven_dev
Obtaining raven-dev from git+https://github.com/getsentry/raven-python.git@56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e#egg=raven_dev
  Updating ./src/raven-dev clone (to 56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e)
  Could not find a tag or branch '56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e', assuming commit.
Installing collected packages: raven-dev
  Running setup.py develop for raven-dev
Successfully installed raven-dev
/usr/local/bin/pip install --disable-pip-version-check -e   0.84s user 0.48s system 39% cpu 3.300 total
```

After:
```
$ /Users/matt/.virtualenvs/pip/bin/pip --version
pip 7.2.0.dev0 from /Users/matt/code/pip (python 2.7)
$ time /Users/matt/.virtualenvs/pip/bin/pip install --disable-pip-version-check -e git+https://github.com/getsentry/raven-python.git@56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e#egg=raven_dev
Obtaining raven-dev from git+https://github.com/getsentry/raven-python.git@56fc6f7beecf445843d0ec7052bb8c6f0ea80a2e#egg=raven_dev
checking version
  Skipping because already up-to-date.
Installing collected packages: raven-dev
  Running setup.py develop for raven-dev
Successfully installed raven-dev
/Users/matt/.virtualenvs/pip/bin/pip install --disable-pip-version-check -e   0.59s user 0.22s system 98% cpu 0.824 total
```
2015-09-01 13:23:18 -07:00
Sachi King
5d96864775 Attempt to get name for editable file:// URLs
When installing an editable from file:///path/to/file, pip currently does
not attempt to determine the name from #egg=NAME, just passing back
None.  This causes constraints code to completely ignore this line
resulting in unexpected installation behaviour.

This patch makes '-e file:///path#egg=name' function similarly to
'file:///path#egg=name' and '-e git+URL#egg=name'.  If #egg=name is not
defined, it returns None and the package becomes an unamed requirement,
which constraints will not parse but in the case of a requirement will
later be processed and determined.

Closes #3026
2015-08-18 11:44:20 +10:00
Sachi King
4c7fd6aead Attempt to install editable packge defined in constraints should error
Currently if the local package you are trying to install is listed in
the constraint file it will silently fail to install the local package
while installing its dependancies.

This process was caused by the has_requirement returning true when a
constraint with that name was defined, resulting in the local package
not being processed.

Closes #2928
2015-08-17 14:49:03 +10:00
James Polley
b227c45a7b Ignore distutils prefix when using --user
Fixes bug #2683

There are two changes here; one to fix the using-wheels codepath and one
to fix the no-wheels codepath. Two tests are introduced, one to test
each codepath.
2015-06-26 19:08:45 +10:00
Donald Stufft
3abaac5abc Merge pull request #2743 from Carreau/importlib
imp deprecated on 3.4
2015-06-23 19:13:31 -04:00
James Polley
6d719576e8 Handle missing case from bug #2888
If a single package is listed as a constraint; is a dependency of a
package being installed; *and* is already installed, we end up
processing it multiple times. This change adds a new "prepared" flag
which we set the first time the package is processed, to prevent
multiple handling.

Fixes bug #2888
2015-06-19 15:21:02 +10:00
Robert Collins
a66d3e2e8b Issue #2867: Accept --no/only-binary via pip.conf 2015-06-10 10:25:15 +12:00
Robert Collins
bb0b429a49 Issue #2731: Constraints files.
This adds constraints files. Like requirements files constraints files
control what version of a package is installed, but unlike
requirements files this doesn't itself choose to install the package.
This allows things that aren't explicitly desired to be constrained if
and only if they are installed.
2015-06-03 06:38:33 +12:00
Marcus Smith
8c20947a23 update 'pip freeze -r' test to include marker case 2015-06-02 06:50:16 +12:00
Donald Stufft
f6856d6687 Try to test against Python 3.5 2015-05-27 21:34:17 -04:00
Donald Stufft
547ba94900 This works again 2015-05-20 16:27:42 -04:00
Donald Stufft
fa5710614e Mark this test as xfail until PyPI's search is fixed 2015-05-19 19:00:06 -04:00
Donald Stufft
18064e7017 Remove the workarounds/hacks to handle distribute -> setuptools 2015-05-09 15:09:05 -04:00
Matthias Bussonnier
cdb1dc7685 imp deprecated on 3.4
importing it prevent to debug other packages with `-W error` as the
deprecation warning will raise.

Though there is still imp imported from a few vendorized packages,
and for other purposes than cache_from_source.
2015-05-02 10:48:25 -07:00
Robert Collins
582af6e684 Issue #2677: Disable wheels for setup.py options.
Using --install-options, --build-options, --global-options changes
the way that setup.py behaves, and isn't honoured by the wheel code.
The new wheel autobuilding code made this very obvious - disable
the use of wheels when these options are supplied.
2015-04-24 16:14:48 +12:00
Robert Collins
6aec23cafe Issue #2675: Granular control over wheels/sdists
With wheel autobuilding in place a release blocker is some granular
way to opt-out of wheels for known-bad packages. This patch introduces
two new options: --no-binary and --only-binary to control what
archives we are willing to use on both a global and per-package basis.

This also closes #2084
2015-04-24 08:52:48 +12:00
Marcus Smith
b911339625 Merge remote-tracking branch 'pypa/develop' into refactor_req_file
Conflicts:
	pip/req/req_file.py
2015-04-23 02:21:01 -07:00
Robert Collins
62041d3ca8 Cleanup now use_wheel is the default.
There were a bunch of tests passing use_wheel unnecessarily, this
makes the change to remove use_wheel larger than it needs to be.
2015-04-20 20:12:03 +12:00
Marcus Smith
1ca1f1053d pep8 fixes 2015-04-18 13:55:48 -07:00
Marcus Smith
285f71b34a Test --install-option in requirements file overrides same option in cli 2015-04-18 12:48:25 -07:00
Marcus Smith
9c66633c29 - fixes to TestOptionVarants
- consistent use of the finder fixture
2015-04-18 11:59:17 -07:00
Robert Collins
08acb6670d Issue #2140: Build wheels automatically
Building wheels before installing elminates a cause of broken environments -
where install fails after we've already installed one or more packages.

If a package fails to wheel, we run setup.py install as normally.
2015-04-13 18:33:07 +12:00
Marcus Smith
12eab18bde functional test for --install-option in a requirements file 2015-04-13 00:07:15 +02:00