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

794 commits

Author SHA1 Message Date
Chris Jerdonek 9d00420c16 Use the requested log level when handling broken stdout pipe. 2019-01-21 12:45:59 -08:00
Chris Jerdonek eef02fd666 Unskip / get the end-to-end tests working for Windows. 2019-01-20 15:49:49 -08:00
Chris Jerdonek 7a9e1f344b Handle BrokenPipeError gracefully. 2019-01-20 15:49:49 -08:00
Chris Jerdonek e6d0127985 Add failing tests. 2019-01-20 15:49:49 -08:00
Jelmer Vernooij eb7d4b2178
Bazaar: Export directly from the remote branch.
This significantly improves performance, since it allows the remote
server to directly stream a tarball that just contains the requested
revision rather than the full repository contents.
2019-01-20 17:46:31 +00:00
Ami Fischman 2a90808387 Prefix user_log (--log) entries with timestamp (#6142)
Why? Eases post-facto analysis of time spent in different phases of pip operation.

Historical note:
767d11e49c (diff-b670e3b192038c9ffe810c1a12c0c51fL219)
made it so that pip invocations emit zero timestamp information to the log
file. Prior to that each pip invocation's start time was written out (search
that commit's diff for [strftime]).

Result: https://gist.github.com/fischman/f570886219de5c64a3b695300195c70a

Resolves https://github.com/pypa/pip/issues/6141
2019-01-20 03:02:22 -08:00
Donald Stufft 5074327bcb
Merge pull request #6147 from dstufft/warn-on-27
Warn on Python 2.7
2019-01-19 21:53:09 -05:00
Donald Stufft f3b9cf2e8f fix grammar, line lengths 2019-01-19 19:09:04 -05:00
Chris Jerdonek f982845aee
Merge pull request #6134 from cjerdonek/pip-no-use-pep517
Prevent the use of PIP_NO_USE_PEP517 to head off user confusion
2019-01-19 13:08:22 -08:00
Donald Stufft 71dbc9c3d5 Warn on Python 2.7 2019-01-19 14:54:07 -05:00
Chris Jerdonek 5fe3157917 Change the --no-cache-dir error to use raise_option_error(). 2019-01-15 09:21:16 -08:00
Chris Jerdonek c0cc004ca8 Raise an error if the user tries to use PIP_NO_USE_PEP517. 2019-01-15 09:21:12 -08:00
Chris Jerdonek 35b1cc1c97
Tweak two use_pep517 identity checks. (#6135) 2019-01-14 23:25:20 -08:00
Pradyun Gedam 47d7f2b92e
Merge pull request #6123 from xavfernandez/deprecate34
Deprecate Python 3.4
2019-01-13 12:46:43 +05:30
Xavier Fernandez b268c67f84 Deprecate Python 3.4 2019-01-12 22:08:24 +01:00
Chris Jerdonek 4dc8710654
Tweak freeze comment when no version control detected. (#6128) 2019-01-12 12:44:45 -08:00
Xavier Fernandez a09913673f Redact index password from logs
Closes #6124
2019-01-10 10:47:19 +01:00
Chris Jerdonek 2a6d282984
Merge pull request #6122 from cjerdonek/make-get-src-requirement-class-method
Make VersionControl.get_src_requirement() a class method
2019-01-09 20:54:16 -08:00
Xavier Fernandez 477147091e
Merge pull request #6116 from peterlisak/bug-fix-outdated-not-required
pip list --not-required --outdated should list only outdated packages…
2019-01-09 22:15:53 +01:00
Chris Jerdonek 8d45557ff1 Make get_src_requirement() a class method. 2019-01-09 01:52:24 -08:00
Chris Jerdonek 8a036105dd Make get_revision() and get_revision_hash() class methods. 2019-01-09 01:52:19 -08:00
Chris Jerdonek 8a771d027d Make get_remote_url() a class method. 2019-01-09 01:24:16 -08:00
Chris Jerdonek 41f058b4f5 Make _get_subdirectory(), _get_svn_url_rev(), and _is_local_repository() class methods. 2019-01-09 01:24:16 -08:00
Chris Jerdonek 00ae3f594d Make VersionControl.run_command() a class method. 2019-01-09 01:24:16 -08:00
Peter Lisák 1a87e577d0 Add comments 2019-01-07 17:10:08 +01:00
Pradyun Gedam 8ff8e1fa9e
Merge pull request #6060 from pradyunsg/remove/dependency-links
Remove dependency links support
2019-01-07 08:49:13 +05:30
Peter Lisák 4f35981085 pip list --not-required --outdated should list only outdated packages that are not dependencies of installed packages 2019-01-06 10:05:44 +01:00
Pradyun Gedam b7a4d70b25
Don't instantiate NotImplementedError 2019-01-02 17:27:34 +05:30
Pradyun Gedam f9b66cacb3
Stop passing finder to DistAbstraction.dist 2019-01-02 17:27:34 +05:30
Pradyun Gedam 71b6e95322
Remove an unused Subversion method that expects dependency links 2019-01-02 17:27:06 +05:30
Pradyun Gedam 7222cb8fdb
Remove --process-dependency-links and related support code 2019-01-02 17:27:06 +05:30
Chris Jerdonek 526ac40e63 Fix freeze to handle Git repos with no remote. 2018-12-21 01:10:06 -08:00
Chris Jerdonek 1764fbbdab Add failing tests. 2018-12-21 00:21:04 -08:00
Chris Jerdonek 2a902dd464
Merge pull request #5912 from cjerdonek/improve-get-branch
Fix get_branch() to work if the current branch shares a name with a tag
2018-12-20 20:20:12 -08:00
Chris Jerdonek 929c95833d Address review comments. 2018-12-20 17:39:08 -08:00
Maxim Kurnikov 932fb539ef finish types for pip._internal.req, disallow untyped defs 2018-12-19 19:39:35 +03:00
Pradyun Gedam 89ef777c18
Cleanup for issues fixed with mypy upgrade 2018-12-18 15:10:40 +05:30
Pradyun Gedam 22fe45d462
Fix new issues found in mypy 0.620 -> 0.650 2018-12-18 11:20:14 +05:30
Pradyun Gedam be5f4afcfc
Fix inconsistencies in mypy annotations 2018-12-17 23:56:00 +05:30
Maxim Kurnikov 8fc393a2d1 Add type annotations for pip._internal.pyproject, pip._internal.build_env, pip._internal.index, pip._internal.resolve (#6072) 2018-12-17 16:43:23 +05:30
Maxim Kurnikov 05eb7d8e92 Add type annotations for pip._internal.req (#6063) 2018-12-17 16:43:00 +05:30
Maxim Kurnikov 410072bc8b add type annotations for pip._internal.models (#6065) 2018-12-17 16:42:36 +05:30
Maxim Kurnikov 7ee388178a Add type annotations for pip._internal.operations (#6066)
References https://github.com/pypa/pip/issues/4748, https://github.com/pypa/pip/pull/6038.
2018-12-17 16:41:47 +05:30
Chris Jerdonek 1e903eab5a Improve branch detection to work if a tag exists with the same name. 2018-12-16 12:00:42 -08:00
Chris Jerdonek cc9f03dea9 Rename get_branch() to get_current_branch(). 2018-12-16 02:08:27 -08:00
Maxim Kurnikov 7696e7e530 Add type annotations for pip._internal.download, pip._internal.wheel and pip._internal.pep425tags (#6067)
References https://github.com/pypa/pip/issues/4748, https://github.com/pypa/pip/pull/6038.
2018-12-16 14:46:39 +05:30
Pradyun Gedam 5d2d16e575
Merge pull request #6062 from mkurnikov/cli-types
Add type annotations for pip._internal.cli
2018-12-14 12:31:58 +05:30
Maxim Kurnikov 5e5904e61c Add type annotations for pip._internal.utils and pip._internal.vcs.__init__ (#6061) 2018-12-08 08:47:24 +05:30
Paul Moore c5dc6aa784
Merge pull request #6029 from zooba/issue-3055
Fixes #3055 Uninstall causes paths to exceed MAX_PATH limit
2018-12-06 09:23:29 +00:00
Maxim Kurnikov 028848574a add type annotations for pip/_internal/cli/ 2018-12-03 15:47:11 +03:00
Pradyun Gedam fc62b5b677
Move wheel extension information to remove cycle imports 2018-11-30 12:46:08 +05:30
Pradyun Gedam 41f87fba35
Add notes for future cleanups 2018-11-30 11:43:35 +05:30
Pradyun Gedam 9781e1381e
Move an import to top of wheel.py 2018-11-30 11:43:15 +05:30
Paul Moore 087d8254a7
Merge pull request #5410 from wtolson/manylinux2010
Manylinux2010
2018-11-22 11:07:49 +00:00
Steve Dower 2538a07a8b Fix linting issue 2018-11-21 14:44:14 -08:00
Steve Dower 1948a7c378 Add compress_for_rename() test and preserve casing 2018-11-21 14:33:15 -08:00
Steve Dower f4bdd28e25 Fix linting issues 2018-11-21 14:13:45 -08:00
Steve Dower 60a08c838d Merge remote-tracking branch 'upstream/master' into issue-3055 2018-11-21 13:55:25 -08:00
Steve Dower 1bf93a78cb Adds test for AdjacentTempDirectory._generate_names 2018-11-21 13:53:49 -08:00
Steve Dower 85f9cdf866 Remove makedirs call 2018-11-21 13:25:49 -08:00
Steve Dower c7ae06c798 Fixes #3055 Uninstall causes paths to exceed MAX_PATH limit 2018-11-21 13:14:36 -08:00
Pradyun Gedam ad70174bfc
Minor cleanups to format_control.py 2018-11-21 14:23:48 +05:30
Paul Moore f06a0cb560 Move setup.py egg_info logging into run_egg_info 2018-11-14 19:24:27 +00:00
Paul Moore 85e4f8ec41 Fix some remaining TODO comments 2018-11-14 18:24:55 +00:00
Paul Moore 6b7473d664 Pass --use-pep517 option to the resolver in the pip wheel command 2018-11-14 18:18:48 +00:00
Paul Moore 3a0f9b1c71 Remove unneeded TODO 2018-11-14 14:31:24 +00:00
Paul Moore e8f7aa1446 Pass use_pep517 option to resolver 2018-11-14 14:06:35 +00:00
Paul Moore 4ca38e0c38 Merge with master 2018-11-11 13:49:35 +00:00
Chris Jerdonek 7e8e706791 Rename VersionControl.get_url() to get_remote_url(). 2018-11-09 22:55:59 -08:00
Chris Jerdonek 8a4e2851d2
Merge pull request #5996 from cjerdonek/simplify-get-src-requirement
Change VersionControl.get_src_requirement() to accept the project name
2018-11-09 12:33:25 -08:00
Benjamin Peterson 5f5415756d Add missing spaces to log message about skipping a link due python version incompatibility. (#5992) 2018-11-09 12:21:13 +05:30
Pradyun Gedam a2d7150b9b
Merge pull request #5995 from pradyunsg/misc/cleanup-vcs
Minor fixes in pip._internal.vcs directory
2018-11-09 11:12:39 +05:30
Chris Jerdonek fc1b1e4cf0
Merge pull request #5884 from cjerdonek/pip-no-cache-dir-var
Make PIP_NO_CACHE_DIR behave as it reads, and not crash pip
2018-11-08 14:19:48 -08:00
Chris Jerdonek 07900ed732 Change VersionControl.get_src_requirement() to accept the project name. 2018-11-08 04:24:05 -08:00
Chris Jerdonek b94d719f39 Make PIP_NO_CACHE_DIR disable the cache also if given a "true" value. 2018-11-08 03:43:56 -08:00
Pradyun Gedam f60c57df4f
Fix an incorrect type annotation 2018-11-08 16:47:07 +05:30
Pradyun Gedam 238df6f4f6
Remove no-longer-existing variable from __all__ 2018-11-08 16:47:02 +05:30
Pradyun Gedam 28cfd7d0b7
Merge pull request #5923 from psinghsodhi/stopPrintSt
Don't print stacktrace due to invalid req
2018-11-08 13:01:56 +05:30
Adam Tse aa42f14ee3 Adding type annotations to pip._internal.utils.glibc (#5956)
* Added type annotations

* to satsify flake8 E402

* Update src/pip/_internal/utils/glibc.py

Co-Authored-By: atse <atse@users.noreply.github.com>
2018-11-06 15:07:18 +05:30
Pradyun Gedam 523a3d0f1f
Merge pull request #5941 from erdincmutlu/erdinc
added mypy annotation to pip._internal.locations
2018-11-06 15:05:36 +05:30
Pradyun Gedam 63f92ea5b9
Merge pull request #5945 from cytolentino/compat-typing
Add mypy annotations to pip._internal.compat
2018-11-06 15:03:49 +05:30
Pradyun Gedam 4ec7b38f8c
Merge pull request #5925 from mbaluna/mypy-annotations-for-utils-appdirs
Add mypy annotations for utils/appdirs
2018-11-06 14:58:42 +05:30
Chris Jerdonek 3803ce3cb0
Merge pull request #5905 from cjerdonek/issue-5031-freeze-non-vcs-editable
Address #5031: freeze non-vcs editable installs as editable
2018-11-05 14:21:42 -08:00
cytolentino ecf90d4792 Add typing to compat.py 2018-11-05 12:12:03 +00:00
mbaluna eed9489a31
Remove win_path_to_bytes annotation 2018-10-31 10:05:52 +00:00
Pradyun Gedam 35701ea3cd
Merge pull request #5930 from cytolentino/basecommand-typing
Add mypy annotations to base_command.py
2018-10-31 01:57:46 +05:30
Pradyun Gedam afe98f3901
Merge pull request #5939 from cytolentino/internal-cache-typing
Add mypy annotations to pip._internal.cache
2018-10-31 01:51:42 +05:30
Pradyun Gedam bfc54bc84d
Satisfy the linter 2018-10-31 01:47:12 +05:30
Pradyun Gedam d95bc267fd
Merge pull request #5960 from cytolentino/cmdoptions-typing
Add mypy annotations to pip._internal.cli.cmdoptions
2018-10-31 01:38:35 +05:30
Pradyun Gedam 5005769b99
Merge pull request #5932 from petr-tik/no4748-add-type-hints-to-internals
Added type hints to internals/utils
2018-10-31 01:30:50 +05:30
Pradyun Gedam 2ed581c79f
Merge pull request #5968 from cjerdonek/dry-up-parse-credentials
Use split_auth_from_netloc() inside MultiDomainBasicAuth
2018-10-30 18:45:35 +00:00
cytolentino f08b34887b Add typing to cache.py 2018-10-30 12:23:13 +00:00
Riccardo Magliocchetti 376abc0655 remove last user of SafeConfigParser
Fixes #5059
2018-10-30 12:11:04 +01:00
Chris Jerdonek 5c93250fa9
Merge pull request #5875 from uranusjr/egg-info-canonical
Rewrite egg_info_matches with canonicalize_name
2018-10-30 01:30:40 -07:00
Chris Jerdonek 0aa301c60e Percent-encode the username in redact_netloc(). 2018-10-29 22:13:55 -07:00
Chris Jerdonek f54b68fea7 DRY up MultiDomainBasicAuth some more. 2018-10-29 22:13:55 -07:00
Chris Jerdonek a434431431 Use split_auth_from_netloc() inside MultiDomainBasicAuth(). 2018-10-29 22:13:51 -07:00
Chris Jerdonek 8166eb6c32 Percent-decode special characters in SVN URL credentials. 2018-10-29 22:12:51 -07:00
Paul Moore f805ac15a7 Properly wrap all hook calls in our subprocess runner 2018-10-29 23:33:21 +01:00
Paul Moore 3c94d81f68 Support --python-tag for PEP 517 builds 2018-10-29 23:33:21 +01:00
Paul Moore 83979fedaa Actually use the new --[no-]use-pep517 option 2018-10-29 23:33:21 +01:00
Paul Moore 9d2b17854d Add --[no-]use-pep517 command line flag 2018-10-29 23:33:21 +01:00
Paul Moore 41b07c9fb5 Include backend-provided requirements in build environment 2018-10-29 23:33:19 +01:00
Paul Moore c8d8e37ea4 Fix copy and paste error 2018-10-29 23:32:13 +01:00
Paul Moore 4281bf8e61 Correct an out of date comment 2018-10-29 23:32:13 +01:00
Paul Moore ab3e21635a Add a news file 2018-10-29 23:32:13 +01:00
Paul Moore 48e9cb693f Address test failures 2018-10-29 23:32:13 +01:00
Paul Moore b62284a81b Build PEP 517 and legacy wheels separately 2018-10-29 23:32:13 +01:00
Paul Moore b9e92a70fd With build isolation, we shouldn't check if wheel is installed to decide if we build wheels 2018-10-29 23:32:13 +01:00
Paul Moore 4de2915113 Update required setuptools version for PEP 517 2018-10-29 23:32:03 +01:00
Paul Moore 8fbf78d407 Phase 2 - generate metadata using PEP 517 hook 2018-10-29 23:28:23 +01:00
Paul Moore 14f35f91f5 Experimental fix to pep517 to use pip's subprocess caller 2018-10-29 23:28:23 +01:00
Paul Moore de4d5038f8 Phase 1 - build wheels using PEP 517 hook 2018-10-29 23:28:23 +01:00
Benoit Pierre 744b8cf96e improve build environment
- check build requirements for conflicts
- better isolation (ignore system site packages)
- support 2 prefixes: a "normal" one, and an "overlay" one
  (with higher priority over "normal")
2018-10-29 23:17:51 +01:00
Yuan Jing Vincent Yan 4ccea7e67a Improve documentation in misc.py 2018-10-29 22:40:16 +01:00
Tzu-ping Chung 033a47cbf2 More test cases 2018-10-29 15:48:43 +08:00
cytolentino 0dbdb6250b Add typing to cmdoptions.py 2018-10-28 16:44:00 +00:00
Erdinc Mutlu 11f7fba714 flake8 issue fixed 2018-10-28 16:42:24 +00:00
Erdinc Mutlu ee38a8f028 Fixed Travis issues with my commit 2018-10-28 15:08:21 +00:00
Erdinc Mutlu 1429f14184 Minor change according to review and comment for typeshed issue reported 2018-10-28 14:12:45 +00:00
Pradyun Gedam b47b2fa8e6
Merge pull request #5841 from benoit-pierre/fix_python_src/pip
fix support for invoking pip using `python src/pip ...`
2018-10-28 12:35:53 +00:00
Erdinc Mutlu 613dc33656 added remaining mypy annotation to pip._internal.locations 2018-10-28 12:16:20 +00:00
petr-tik 55f6787c04 Added type hints
Found a potential bug i.e. missing return statement in check_path_owner. If
while loop falls through without returning,
return a defensive False

Added a trivial file as per the contributor guidelines

Make linter happy - ignore "unused" import
2018-10-27 15:37:29 +01:00
Chris Jerdonek afdfb7b210 Include package name in a freeze warning if package is not installed. 2018-10-27 06:50:15 -07:00
Erdinc Mutlu 25cb31ab10 added mypy annotation to pip._internal.locations 2018-10-27 14:34:20 +01:00
cytolentino 12a2334429 Add mypy annotations to base_command.py 2018-10-27 13:28:06 +01:00
Monica Baluna 49737605d7 Add mypy annotations for utils/appdirs 2018-10-26 19:24:33 +03:00
Prabhjyotsing Surjit Singh Sodhi e34b19b02a Don't print stacktrace due to invalid req 2018-10-26 12:03:31 -04:00
Chris Jerdonek 951e0cba51
Fix #5868: TypeError in move_wheel_files(). (#5883) 2018-10-24 09:19:58 -07:00
Chris Jerdonek f828dff5ca Switch log message from info to debug. 2018-10-23 00:29:42 -07:00
Xavier Fernandez 3b8c076c1f
Merge pull request #5842 from takluyver/i5839
Don't crash on invalid requirements in installed packages
2018-10-22 17:22:04 +02:00
Chris Jerdonek 20ab0b8b75 Address #5031: freeze editable, non-VCS installs as editable. 2018-10-22 02:03:42 -07:00
Tzu-ping Chung ad9cbf50ca More robust egg-info/name match
The idea is to use regex to scan for character sequences that would
be canonicalized into a dash, and skip the equal amount of sequences
to the given canonical name.
2018-10-22 16:48:24 +08:00
Tzu-ping Chung 3368819156 Split, simplify, and fix egg_info_matches 2018-10-22 16:46:42 +08:00
Chris Jerdonek 4e6bdf6adc
Merge pull request #5881 from cjerdonek/remove-vcs-get-src-requirement
Remove the module-level get_src_requirement().
2018-10-22 01:43:04 -07:00
wim glenn 3a6a1c06a9 Remove dead code: import_or_raise utility function (#5876)
* Remove dead code import_or_raise utility function

* add news marker
2018-10-21 22:15:27 +02:00
Dave Jones 62c27dee45 Use ZipFile.open instead of ZipFile.read (#5848)
To avoid huge memory usage in unusual situations (e.g. a TensorFlow
wheel on a Raspberry Pi), use ZipFile.open and shutil.copyfileobj
instead of reading all the decompressed data into a byte-string.
2018-10-19 10:32:30 -07:00
Tom Forbes 78371cc950 Redact basic authentication passwords from log messages (#5773)
Redact basic authentication passwords from URLs.
2018-10-19 02:06:10 -07:00
Xavier Fernandez 7f3b2c1f92
Merge pull request #5659 from patter001/master
fix for: Incorrect username/password gives misleading error
2018-10-16 14:39:02 +02:00
Chris Jerdonek 46ffb13f13 Remove unused dependency_links variables in freeze.py. 2018-10-16 02:42:20 -07:00
Chris Jerdonek ddfe130b31 Make get_requirement_info() a function rather than a class method. 2018-10-16 02:27:12 -07:00
Benoit Pierre 83b879b1ec Improve PEP 518 build isolation (#5824)
Handle .pth files, so namespace packages are correctly supported under Python 3.2 and earlier, and more.
2018-10-16 12:04:28 +05:30
Chris Jerdonek c976f2c1e9 Flatten the try-except. 2018-10-13 02:15:37 -07:00
Chris Jerdonek 5ad0379e8d Remove the module-level function get_src_requirement(). 2018-10-13 02:15:33 -07:00
Chris Jerdonek 1228f64ec0
Merge pull request #5873 from cjerdonek/remove-get-backend-from-location
Simplify vcs.get_src_requirement().
2018-10-13 00:57:17 -07:00
Chris Jerdonek 8dbbe165f8
Merge pull request #5838 from uranusjr/htmlpage-extract-breakdown-get-page
Refactor _get_html_page() to use exceptions for flow control
2018-10-11 12:27:17 -07:00
Tzu-ping Chung fc53f711b9 More tests on successful scenarios, fix docstrings 2018-10-11 17:47:08 +08:00
Tzu-ping Chung 65260d0449 Fix behavior if archive-like URL is not HTTP(S)
The original implementation erros out when this happens, and the new one
follows. The debug logging message is however changed to be clearer about
what happened.

Also fixed some minor typos.
2018-10-11 17:45:22 +08:00
Tzu-ping Chung 68cf77ac0b Only store what we need in _NotHTML 2018-10-11 17:45:22 +08:00
Tzu-ping Chung a9ebb795ed More detailed information on Content-Type error, fix typos 2018-10-11 17:45:11 +08:00
Tzu-ping Chung d4da76ceaa Move directory check out of _get_html_response()
This also "fixes" an edge case where a directory is dropped if it is
named like an archive.
2018-10-11 17:45:11 +08:00
Tzu-ping Chung 231e6165dd Group HEAD optimization logic into HTML getter, add docs 2018-10-11 17:44:59 +08:00
Tzu-ping Chung bad04d8549 Extract content type detection logic 2018-10-11 17:44:59 +08:00
Tzu-ping Chung 44713cafe5 Move VCS scheme check back out 2018-10-11 17:44:59 +08:00
Chris Jerdonek 00a2ff198e Remove unneeded if block in vcs.get_src_requirement(). 2018-10-10 02:34:40 -07:00
Chris Jerdonek 2f16b88fb3 Refactor away VcsSupport.get_backend_from_location(). 2018-10-10 02:16:00 -07:00
Chris Jerdonek 47b94f19bb
Merge pull request #5869 from cjerdonek/remove-svn-freeze-code
Address #5866: remove deprecated SVN-specific freeze code.
2018-10-09 02:19:08 -07:00
Pradyun Gedam 35f0983639
Merge pull request #5863 from benoit-pierre/drop_py25_workaround
drop workaround for Python<=2.5
2018-10-09 14:34:49 +05:30
Chris Jerdonek faff436100 Add guard clause. 2018-10-08 22:57:32 -07:00
Chris Jerdonek 500598287d Remove deprecated SVN-specific freeze code. 2018-10-08 22:27:04 -07:00
Xavier Fernandez 3832020a1f
Merge pull request #5483 from popravich/retry_fix
Handle RetryError in HTMLPage (fixes #5270)
2018-10-08 23:12:34 +02:00
Chris Jerdonek b3ac98eff4 Only define comments when needed. 2018-10-08 11:31:27 -07:00
Chris Jerdonek e80a90e96c Add try-else clause. 2018-10-08 11:31:27 -07:00
Chris Jerdonek 39b413352d Combine some lines. 2018-10-08 11:31:27 -07:00
Chris Jerdonek f5026e7db9 Remove unneeded boolean flag variables. 2018-10-08 11:31:27 -07:00
Chris Jerdonek 7aa7bf0295 Add fourth guard clause. 2018-10-08 11:31:27 -07:00
Chris Jerdonek 6d84b4747a Add third guard clause. 2018-10-08 11:30:50 -07:00
Chris Jerdonek e4ce62a5de Add second guard clause. 2018-10-08 11:30:50 -07:00
Chris Jerdonek 16333ef1da Add first guard clause. 2018-10-08 11:29:39 -07:00
Chris Jerdonek 69b5917bc1
Merge pull request #5836 from uranusjr/bugfix-warn-directory-path-drop-index-url
Warn when dropping index URL value to directory
2018-10-08 11:20:35 -07:00
Pradyun Gedam 9e26002fcd
Bump deprecation version to unlock workflow 2018-10-08 20:46:17 +05:30
Benoit Pierre 0a58159571 drop workaround for Python<=2.5 2018-10-07 14:26:34 +02:00
Pradyun Gedam c759504217
Merge pull request #5798 from pradyunsg/improve-configuration-handling
Improve configuration handling
2018-10-04 14:27:42 +05:30
Thomas Kluyver 32b8a797cb Remove unused variable 2018-10-02 14:29:58 +02:00
Thomas Kluyver 4286f49d6d Arrange imports as required by linter 2018-10-02 14:25:42 +02:00
Thomas Kluyver 9a1194e4be Exit 'pip check' with code 1 on problems parsing requirements 2018-10-02 12:38:16 +02:00
Benoit Pierre 464b2f30a8 fix support for invoking pip using python src/pip ...
Ensure the subprocess call to pip for installing the PEP 518
build dependencies is using the same version of pip.
2018-10-02 12:15:03 +02:00
Thomas Kluyver 3ec6775e1f Catch errors checking for conflicts, don't crash install 2018-10-02 12:07:48 +02:00
Thomas Kluyver 172a71b0cf Log warning when there's a problem parsing requirements 2018-10-02 12:03:26 +02:00
Thomas Kluyver cfac80f374 Catch errors parsing requirements to check packages 2018-10-02 12:00:53 +02:00
Alexey Popravka a853ca02b8 fix lint issues 2018-10-02 12:53:06 +03:00
Alexey Popravka 41a9d5e003 handle RetryError in HTMLPage/PackageFinder 2018-10-02 12:53:06 +03:00
Tzu-ping Chung 025dc45ad1 Don't need to unpack prematurely 2018-10-01 16:49:57 +08:00
Tzu-ping Chung bb6dae6e71 Inline PackageFinder._get_page() 2018-10-01 16:07:41 +08:00
Tzu-ping Chung 72779c674e Extract request part of get_page into helper
Also switch to use exceptions as flow control for VCS and Content-Type
detection. Hopefully this makes the flow much clearer.
2018-10-01 16:07:00 +08:00
Tzu-ping Chung 7a17a1f7dd Extract VCS scheme check into helper function 2018-10-01 15:54:04 +08:00
Tzu-ping Chung 8dcae5ba48 Warn when dropping index URL value to directory 2018-10-01 14:50:09 +08:00
Pradyun Gedam 34d5af662f
Merge branch 'master' into improve-configuration-handling 2018-09-30 23:04:55 +05:30
Tzu-ping Chung bd6a7ea6c6 Pass the URL instead of the page itself into Link
This argument (comes_from) is only used for reporting, and it is enough
to pass in only the URL since that's what is actually used.
2018-09-30 17:46:21 +08:00
Tzu-ping Chung d275360745 Move static methods out of HTMLPage
Because the class is going away, but these functions will still be
needed by the thing replacing it.
2018-09-30 17:46:21 +08:00
Chris Jerdonek 356dc432f7
Merge pull request #5818 from cjerdonek/simplify-from-dist
Add FrozenRequirement._init_args_from_dist() helper method
2018-09-30 02:28:53 -07:00
Tzu-ping Chung 6f85fcdd7d Move clean_link out of HTMLPage 2018-09-28 23:58:24 +08:00
Tzu-ping Chung 47ba191d3a Rename HTMLPage.links to clarify its purpose 2018-09-28 16:53:02 +08:00
Tzu-ping Chung aa83222bf0 Rename base URL detection function 2018-09-28 16:52:57 +08:00
Tzu-ping Chung dc7e6b5950 Refactor _parse_base_url to use early return 2018-09-28 15:52:00 +08:00
Tzu-ping Chung 28ef0c2014 Convert HTMLPage.parsed into a local variable
This attribute is only used by HTMLPage.links, which is only used once
per instance in PackageFinder.find_all_candidates(), so this change does
not affect performance or behavior, but improves data locality.
2018-09-28 15:02:51 +08:00
Tzu-ping Chung 94d0428924 Extract encoding detection into helper function 2018-09-28 15:00:58 +08:00
Tzu-ping Chung 40bf3688b4 Convert base_url property into local variable
This property is only used in HTMLPage.links, which is only called once
per instance in PackageFinder.find_all_candidates(). This would not
affect performance or behavior, but improves data locality.

The unit test of this property is and modified to test the underlying
function instead.
2018-09-28 14:56:52 +08:00
Tzu-ping Chung 96a3254a1f Extract base URL parsing logic 2018-09-28 14:49:40 +08:00
Donald Stufft f4a41a2048
Merge pull request #5819 from uranusjr/htmlpage-clean
HTMLPage cleanup and egg_info_matches fix
2018-09-27 10:21:22 -04:00