Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update vendor packages #3853

Merged
merged 2 commits into from
Jul 17, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions news/3807.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Update ``pythonfinder`` to fix a problem that ``python.exe`` will be mistakenly chosen for
virtualenv creation under WSL.
5 changes: 4 additions & 1 deletion pipenv/vendor/pythonfinder/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,10 @@
"pyston",
"micropython",
)
KNOWN_EXTS = {"exe", "py", "fish", "sh", ""}
if os.name == "nt":
KNOWN_EXTS = {"exe", "py", "bat", ""}
else:
KNOWN_EXTS = {"sh", "bash", "csh", "zsh", "fish", "py", ""}
KNOWN_EXTS = KNOWN_EXTS | set(
filter(None, os.environ.get("PATHEXT", "").split(os.pathsep))
)
Expand Down
8 changes: 5 additions & 3 deletions pipenv/vendor/requirementslib/models/setup_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
from vistir.misc import run
from vistir.path import create_tracked_tempdir, ensure_mkdir_p, mkdir_p, rmtree

from ..environment import MYPY_RUNNING
from ..exceptions import RequirementError
from .utils import (
get_default_pyproject_backend,
get_name_variants,
Expand All @@ -37,8 +39,6 @@
split_vcs_method_from_uri,
strip_extras_markers_from_requirement,
)
from ..environment import MYPY_RUNNING
from ..exceptions import RequirementError

try:
from setuptools.dist import distutils, Distribution
Expand Down Expand Up @@ -712,11 +712,13 @@ def ast_unparse(item, initial_mapping=False, analyzer=None, recurse=True): # no
item.right = right_item
unparsed = item
else:
unparsed = right_item + left_item
unparsed = left_item + right_item
else:
unparsed = item
elif isinstance(item.op, ast.Sub):
unparsed = unparse(item.left) - unparse(item.right)
else:
unparsed = item
elif isinstance(item, ast.Name):
if not initial_mapping:
unparsed = item.id
Expand Down
4 changes: 3 additions & 1 deletion pipenv/vendor/requirementslib/models/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -505,7 +505,9 @@ def split_markers_from_line(line):
# type: (AnyStr) -> Tuple[AnyStr, Optional[AnyStr]]
"""Split markers from a dependency"""
quote_chars = ["'", '"']
line_quote = next(iter(quote for quote in quote_chars if line.startswith(quote)), None)
line_quote = next(
iter(quote for quote in quote_chars if line.startswith(quote)), None
)
if line_quote and line.endswith(line_quote):
line = line.strip(line_quote)
if not any(line.startswith(uri_prefix) for uri_prefix in SCHEME_LIST):
Expand Down
2 changes: 2 additions & 0 deletions tasks/release.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ def release(ctx, dry_run=False):
ctx.run("towncrier --draft > CHANGELOG.draft.rst")
log("would remove: news/*")
log("would remove: CHANGELOG.draft.rst")
log("would update: pipenv/pipenv.1")
log(f'Would commit with message: "Release v{version}"')
else:
ctx.run("towncrier")
Expand All @@ -90,6 +91,7 @@ def release(ctx, dry_run=False):
)
ctx.run("git rm CHANGELOG.draft.rst")
generate_manual(ctx)
ctx.run("git add pipenv/pipenv.1")
ctx.run(f'git commit -m "Release v{version}"')

tag_content = tag_content.replace('"', '\\"')
Expand Down