From 2501be4381cd8ed7732325e8e3deadff6859b473 Mon Sep 17 00:00:00 2001 From: nitintecg Date: Mon, 22 Apr 2024 01:17:17 +0530 Subject: [PATCH] Fix the issue(#6126): add lockfile_path presence in pipenv check command --- news/6126.bugfix.rst | 1 + pipenv/routines/check.py | 3 +++ 2 files changed, 4 insertions(+) create mode 100644 news/6126.bugfix.rst diff --git a/news/6126.bugfix.rst b/news/6126.bugfix.rst new file mode 100644 index 0000000000..e11d7604eb --- /dev/null +++ b/news/6126.bugfix.rst @@ -0,0 +1 @@ +Fix a bug that passes pipenv check command if Pipfile.lock not exist diff --git a/pipenv/routines/check.py b/pipenv/routines/check.py index a067a41e74..4f2ab27fc1 100644 --- a/pipenv/routines/check.py +++ b/pipenv/routines/check.py @@ -133,6 +133,9 @@ def do_check( else: if not quiet and not project.s.is_quiet(): click.secho("Passed!", fg="green") + # Check for lockfile exists + if not project.lockfile_exists: + return if not quiet and not project.s.is_quiet(): if use_installed: click.secho(