Skip to content

Commit b9646bd

Browse files
Remove outdated poetry lock --no-update suggestion (#9936)
1 parent d9f1914 commit b9646bd

File tree

6 files changed

+6
-7
lines changed

6 files changed

+6
-7
lines changed

docs/cli.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1086,8 +1086,7 @@ poetry self lock
10861086

10871087
#### Options
10881088

1089-
* `--check`: Verify that `poetry.lock` is consistent with `pyproject.toml`. (**Deprecated**)
1090-
* `--no-update`: Do not update locked versions, only refresh lock file.
1089+
* `--regenerate`: Ignore existing lock file and overwrite it with a new lock file created from scratch.
10911090

10921091
### self show
10931092

src/poetry/console/commands/check.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def handle(self) -> int:
158158
if self.poetry.locker.is_locked() and not self.poetry.locker.is_fresh():
159159
check_result["errors"] += [
160160
"pyproject.toml changed significantly since poetry.lock was last generated. "
161-
"Run `poetry lock [--no-update]` to fix the lock file."
161+
"Run `poetry lock` to fix the lock file."
162162
]
163163

164164
if not check_result["errors"] and not check_result["warnings"]:

src/poetry/installation/installer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ def _do_install(self) -> int:
257257
if not self._locker.is_fresh():
258258
raise ValueError(
259259
"pyproject.toml changed significantly since poetry.lock was last"
260-
" generated. Run `poetry lock [--no-update]` to fix the lock file."
260+
" generated. Run `poetry lock` to fix the lock file."
261261
)
262262
if not (reresolve or self._locker.is_locked_groups_and_markers()):
263263
if self._io.is_verbose():

tests/console/commands/test_check.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ def test_check_lock_outdated(
258258
status_code = tester.execute(options)
259259
expected = (
260260
"Error: pyproject.toml changed significantly since poetry.lock was last generated. "
261-
"Run `poetry lock [--no-update]` to fix the lock file.\n"
261+
"Run `poetry lock` to fix the lock file.\n"
262262
)
263263

264264
assert tester.io.fetch_error() == expected

tests/installation/test_installer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ def test_not_fresh_lock(installer: Installer, locker: Locker) -> None:
240240
ValueError,
241241
match=re.escape(
242242
"pyproject.toml changed significantly since poetry.lock was last generated. "
243-
"Run `poetry lock [--no-update]` to fix the lock file."
243+
"Run `poetry lock` to fix the lock file."
244244
),
245245
):
246246
installer.run()

tests/packages/test_locker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,7 @@ def test_locker_properly_assigns_metadata_files(locker: Locker) -> None:
526526
For multiple constraints dependencies, there is only one common entry in
527527
metadata.files. However, we must not assign all the files to each of the packages
528528
because this can result in duplicated and outdated entries when running
529-
`poetry lock --no-update` and hash check failures when running `poetry install`.
529+
`poetry lock` and hash check failures when running `poetry install`.
530530
"""
531531
content = """\
532532
[[package]]

0 commit comments

Comments
 (0)