Commit Graph

1225 Commits

Author SHA1 Message Date
Pradyun Gedam 58c594c06b
Prepare isort for black 2020-09-23 21:47:47 +05:30
Pradyun Gedam 25ab172b55
Update linter: isort 2020-09-23 19:52:28 +05:30
Pradyun Gedam e61bb616ef
Merge pull request #8839 from uranusjr/new-resolver-hash-intersect 2020-09-17 10:58:44 +05:30
Tzu-ping Chung 179ccbe6f5 Add tests for empty hash intersection 2020-09-11 15:01:50 +08:00
Devesh Kumar Singh 9450f8837a Use format options for abspath 2020-09-11 09:23:51 +05:30
Devesh Kumar Singh d22becc073 Add unit tests for --abspath flag 2020-09-11 09:23:51 +05:30
Tzu-ping Chung 753ad4d230 F Python 2 2020-09-03 17:35:22 +08:00
Tzu-ping Chung dfaa111004 Pull in hashes from constraint files 2020-09-03 17:26:52 +08:00
Tzu-ping Chung 700eb7734f Hashes from lines should intersect, not union 2020-09-03 17:19:01 +08:00
Pradyun Gedam 567630b4b8
Merge pull request #8758 from uranusjr/new-resolver-requires-python-when-no-deps 2020-09-02 20:09:32 +05:30
Pradyun Gedam a99190459e
Merge pull request #8817 from sbidoul/improve-git-checkout 2020-09-01 18:40:51 +05:30
Stéphane Bidoul eff32df28a
Add spacing in test
Co-authored-by: Pradyun Gedam <3275593+pradyunsg@users.noreply.github.com>
2020-08-30 18:15:35 +02:00
Stéphane Bidoul 1c61b4679f
Add failing test fetching a git commit in refs 2020-08-30 11:47:13 +02:00
Tzu-ping Chung 8b2b92485c Include Requires-Python dep even with --no-deps 2020-08-26 09:49:25 +08:00
Nguyễn Gia Phong c84ef7a67c Mark tests using remote svn and hg as xfail
The source repositories for testing is no longer available.
2020-08-24 09:43:50 +07:00
Nguyễn Gia Phong 14397418d1 Test hash checking for fast-deps 2020-08-17 20:46:39 +07:00
Nguyễn Gia Phong 46b938349a Allow py2 deprecation warning from setuptools 2020-08-14 17:56:15 +07:00
Tzu-ping Chung 312d1d0473 Add failing test for constraints with markers 2020-08-07 13:43:49 +08:00
Nguyễn Gia Phong 709ad37b2f
Make assertion failure give better message (#8692) 2020-08-06 15:40:13 +05:30
Pradyun Gedam 7e6ff08aae
Merge pull request #8656 from chrahunt/gracefully-handle-bad-data-paths
Trace a better error message on installation failure due to invalid .data files in wheels
2020-08-02 19:55:40 +05:30
Pradyun Gedam e51a027964
Merge pull request #8659 from uranusjr/fix-get-distribution-dot-in-name
Canonicalize name in check_if_exists
2020-08-02 07:44:24 +05:30
Nguyễn Gia Phong 0ef877339a Make assertions independent of log prefixes 2020-08-01 20:26:44 +07:00
Tzu-ping Chung 1fd5098b24 Canonicalize name in check_if_exists
The previous implementation uses pkg_resources.get_distribution(), which
does not canonicalize the package name correctly, and fails when
combined with pip's own get_distribution(), which does canonicalize
names. This makes InstallRequirement.check_if_exists() only use pip's
own canonicalization logic so different package name forms are matched
as expected.
2020-07-30 22:04:51 +08:00
Chris Hunt 3f9b326c11 Provide a reasonable error on invalid scheme keys
Originally we would throw an `AttributeError` if a bad scheme key was
used. After refactoring we would throw a `KeyError`, which isn't much
better. Now we call out the wheel being processed, scheme key we didn't
recognize, and provide a list of the valid scheme keys. This would
likely be useful for people developing/testing the wheel.
2020-07-29 22:24:09 -04:00
Chris Hunt 864f0e0efa Explicitly handle incorrect .data paths during wheel install
Previously our wheel installation process allowed wheels which contained
non-conforming contents in a contained .data directory.

After the refactoring to enable direct-from-wheel installation, pip
throws an exception when encountering these wheels, but does not include
any helpful information to pinpoint the cause.

Now if we encounter such a wheel, we trace an error that includes the
name of the requirement we're trying to install, the path to the wheel
file, the path we didn't understand, and a hint about what we expect.
2020-07-29 18:12:16 -04:00
Pradyun Gedam a8edffda1c
Merge pull request #8594 from pradyunsg/improve-install-conflict-warning 2020-07-28 18:22:53 +05:30
Pradyun Gedam 3962f9d2b8
Moar tests getting updated 2020-07-27 19:51:47 +05:30
Pradyun Gedam b9ff93f7ba
Update test messages to reflect new reality 2020-07-27 19:51:47 +05:30
Pradyun Gedam c631de61b9
Drop no-longer-used deprecated_python fixture 2020-07-27 19:51:47 +05:30
Pradyun Gedam e4f8e0a2b8
Change {matches -> contains}_expected_lines
This also updates invocations that can't be translated as-is into a
different equivalent check.
2020-07-27 19:51:47 +05:30
Pradyun Gedam a89ede7da3
tests: Check only the last output lines 2020-07-27 19:51:47 +05:30
Pradyun Gedam 7056132f6f
Merge pull request #8601 from rouge8/use-feature-requirements-file 2020-07-27 13:19:51 +05:30
Tzu-ping Chung 906072a292 Test for conflict message from requirements.txt 2020-07-26 15:59:07 +08:00
Stéphane Bidoul ccdfa74d79
Reduce reliance on .egg-info directories in test suite
Make more tests run with with_wheel and test
that a .dist-info directory is created.
2020-07-25 13:02:20 +02:00
Pradyun Gedam 89a51a6fef
Merge pull request #8588 from McSinyx/fast-deps
Use lazy wheel to obtain dep info for new resolver
2020-07-24 09:01:56 +05:30
Pradyun Gedam f94580bad7
Print output in test_debug__library_versions
This should make debugging issues in this test easier.
2020-07-22 19:57:20 +05:30
Nguyễn Gia Phong 4efae5c21a Add integration tests for experimental feature fast-deps
Test pip {download,install,wheel} where requirements have dependencies
listed in their wheels' metadata.
2020-07-21 16:00:34 +07:00
Andy Freeland 7a3c802626 Attempt to test --use-feature in pip freeze
I can't get the functional tests to run locally...
2020-07-19 02:44:12 -07:00
Pradyun Gedam 61d497120f
Merge pull request #8424 from jku/8288-deprecate-nonconforming-extras 2020-07-15 18:03:00 +05:30
Chris Hunt 328e4c06da
Merge pull request #8502 from uranusjr/new-resolver-binary-compat-on-target
Ensure binary compat is checked in --target
2020-07-13 20:38:13 -04:00
Jussi Kukkonen 76b20d738e Deprecate requirements format "base>=1.0[extra]"
This requirements format does not conform to PEP-508. Currently the
extras specified like this work by accident (because _strip_extras()
also parses them). The version checks end up being done with a
misparsed version '1.0[extra]' -- this is not changed in this commit.

Add deprecation warning and fix the corresponding resolver test. Add a
command line test.

Note that we really only check that the Requirement has SpecifierSet
with a specifier that ends in a ']'. A valid version number cannot
contain ']' and no wheels currently on pypi have versions ending in ']'.
2020-07-13 12:33:50 +03:00
Chris Hunt 15b7afbcad
Merge pull request #8266 from gutsytechster/add_logs_for_install
feat(): Add logs for pip environment when installing
2020-07-10 09:36:13 -04:00
Prashant Sharma f7abe1f874
test(functional/test_install): Use shared_data for installing package 2020-07-10 16:20:30 +05:30
Chris Hunt e9508591ce
Merge pull request #8556 from chrahunt/maint/fail-on-install-location-options
Disallow explicitly passing install-location-related arguments in --install-options
2020-07-09 21:25:20 -04:00
Tzu-ping Chung 152642ddcf Ensure binary compat is checked in --target 2020-07-09 21:23:21 +08:00
gutsytechster 0ccbad8367
feat(): Add logs for pip environment when installing 2020-07-09 18:15:43 +05:30
Christopher Hunt 2f9b50c097
Merge pull request #8534 from chrahunt/thoroughly-test-header-installation
Make wheel header installation test more explicit
2020-07-08 17:21:47 -04:00
Chris Hunt 89572a7d40 Throw CommandError on any location-related install options 2020-07-07 19:11:11 -04:00
Chris Hunt b46d8ab01a Refactor overriding test to not use disallowed option
Similar to our previous test refactoring, this removes the usage of
`--home` from the test command.

"Overriding" in the original test meant "placed after" in the
command-line arguments, which makes sense because setuptools will use
the last argument passed.
2020-07-07 19:11:02 -04:00
Chris Hunt 50d7b930d3 Create more robust test for isolated --install-option
The current test depends on passing `--home` to `--install-option`.
Since we would like that to fail, we need to use another argument. None
of the other possible arguments have a visible side-effect, so we just
write the provided arguments to a file and check that in the test.
2020-07-07 19:10:27 -04:00