From 60f1f6dc44985046b416f6f0707869b39acfd74c Mon Sep 17 00:00:00 2001 From: Tom Arad Date: Sun, 1 May 2022 15:11:14 +0300 Subject: [PATCH 1/3] Fixed lock -r warning being logged to stdout instead of stderr --- pipenv/cli/command.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pipenv/cli/command.py b/pipenv/cli/command.py index 7e6885cb65..cc3a51133b 100644 --- a/pipenv/cli/command.py +++ b/pipenv/cli/command.py @@ -324,14 +324,13 @@ def lock(ctx, state, **kwargs): pre = state.installstate.pre if emit_requirements: secho( - """ - Warning: The lock flag -r/--requirements will be deprecated in a future version - of pipenv in favor of the new requirements command. For more info see - https://pipenv.pypa.io/en/latest/advanced/#generating-a-requirements-txt - NOTE: the requirements command parses Pipfile.lock directly without performing any - locking operations. Updating packages should be done by running pipenv lock - """, + "Warning: The lock flag -r/--requirements will be deprecated in a future version\n" + "of pipenv in favor of the new requirements command. For more info see\n" + "https://pipenv.pypa.io/en/latest/advanced/#generating-a-requirements-txt\n" + "NOTE: the requirements command parses Pipfile.lock directly without performing any\n" + "locking operations. Updating packages should be done by running pipenv lock.", fg="yellow", + err=True, ) # Emit requirements file header (unless turned off with --no-header) if state.lockoptions.emit_requirements_header: From 8b8d2e14d1f3b42414394e0d4d03a64e590cbcfe Mon Sep 17 00:00:00 2001 From: Tom Arad Date: Sun, 1 May 2022 15:38:46 +0300 Subject: [PATCH 2/3] Added a news fragment --- news/5091.bugfix.rst | 1 + 1 file changed, 1 insertion(+) create mode 100644 news/5091.bugfix.rst diff --git a/news/5091.bugfix.rst b/news/5091.bugfix.rst new file mode 100644 index 0000000000..879fc5f9ea --- /dev/null +++ b/news/5091.bugfix.rst @@ -0,0 +1 @@ +Fixes issue of ``pipenv lock -r`` command printing to stdout instead of stderr. \ No newline at end of file From 470acd3b9e392114fa26841e68e5557d75e85c3f Mon Sep 17 00:00:00 2001 From: Tom Arad Date: Mon, 2 May 2022 08:27:53 +0300 Subject: [PATCH 3/3] Added a newline at the end of the news fragment --- news/5091.bugfix.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/news/5091.bugfix.rst b/news/5091.bugfix.rst index 879fc5f9ea..dc7de5bbab 100644 --- a/news/5091.bugfix.rst +++ b/news/5091.bugfix.rst @@ -1 +1 @@ -Fixes issue of ``pipenv lock -r`` command printing to stdout instead of stderr. \ No newline at end of file +Fixes issue of ``pipenv lock -r`` command printing to stdout instead of stderr.