import-url: make version-aware and to-remote exclusive

This commit is contained in:
dberenbaum
2023-04-15 23:46:47 +03:00
committed by Ruslan Kuprieiev
parent 1be82fa56d
commit 870935ebdc
+3 -2
View File
@@ -36,9 +36,10 @@ def imp_url( # noqa: C901, PLR0913
out = resolve_output(url, out)
path, wdir, out = resolve_paths(self, out, always_local=to_remote and not out)
if to_remote and (no_exec or no_download):
if to_remote and (no_exec or no_download or version_aware):
raise InvalidArgumentError(
"--no-exec/--no-download cannot be combined with --to-remote"
"--no-exec/--no-download/--version-aware cannot be combined with "
"--to-remote"
)
if not to_remote and remote: