-
-
Notifications
You must be signed in to change notification settings - Fork 292
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
Fix --pip-log
re-use.
#2570
Merged
Merged
Fix --pip-log
re-use.
#2570
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
5c41a32
Fix `--pip-log` re-use.
jsirois 7872b3d
Fixup old style `--preserve-pip-download-log` handling.
jsirois 8950696
Fix missed PipLog.
jsirois c21667d
Merge remote-tracking branch 'refs/remotes/upstream/main' into issues…
jsirois 55e19e2
Simplify and fix by re-arranging lifecycle and improving `--help` docs.
jsirois f8ba7ac
Use Python 2.7 compatible file truncation code.
jsirois File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Copyright 2024 Pex project contributors. | ||
# Licensed under the Apache License, Version 2.0 (see LICENSE). | ||
|
||
from __future__ import absolute_import | ||
|
||
import re | ||
from textwrap import dedent | ||
|
||
from pex import targets | ||
from testing.cli import run_pex3 | ||
from testing.pytest.tmp import Tempdir | ||
|
||
|
||
def test_independent_logs_for_independent_runs(tmpdir): | ||
# type: (Tempdir) -> None | ||
|
||
lock = tmpdir.join("lock.json") | ||
log = tmpdir.join("pip.log") | ||
run_pex3( | ||
"lock", "sync", "--lock", lock, "--pip-log", log, "ansicolors==1.1.8", "cowsay==6.0" | ||
).assert_success() | ||
target = str(targets.current().platform.tag) | ||
run_pex3("lock", "sync", "--lock", lock, "--pip-log", log, "ansicolors==1.1.8").assert_success( | ||
expected_error_re=r".*{footer}$".format( | ||
footer=re.escape( | ||
dedent( | ||
"""\ | ||
Updates for lock generated by {target}: | ||
Deleted cowsay 6 | ||
Updates to lock input requirements: | ||
Deleted 'cowsay==6.0' | ||
""" | ||
).format(target=target) | ||
) | ||
), | ||
re_flags=re.DOTALL, | ||
) | ||
run_pex3("lock", "sync", "--lock", lock, "--pip-log", log, "ansicolors==1.1.8").assert_success( | ||
expected_error_re=r".*No updates for lock generated by {target}\.$".format( | ||
target=re.escape(target) | ||
), | ||
re_flags=re.DOTALL, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
N.B.: This is the issue OP test, but with cowsay 6.0 instead of 6.1 so the Python 2.7 tests work.