Skip to content

Commit

Permalink
ui: error out for meaningless options for non-cloud dvc status
Browse files Browse the repository at this point in the history
  • Loading branch information
Suor committed Jan 7, 2020
1 parent 0ad3548 commit 1b1f8f9
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions dvc/repo/status.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import logging
from itertools import compress

from funcy.py3 import cat

from dvc.exceptions import DvcException
from . import locked


Expand Down Expand Up @@ -113,4 +115,15 @@ def status(
remote=remote,
all_tags=all_tags,
)

ignored = list(
compress(
["--all-branches", "--all-tags", "--jobs"],
[all_branches, all_tags, jobs],
)
)
if ignored:
msg = "the following options are meaningless for local status: {}"
raise DvcException(msg.format(", ".join(ignored)))

return _local_status(self, targets, with_deps=with_deps)

0 comments on commit 1b1f8f9

Please sign in to comment.