term: review usage of "version" in strings

This commit is contained in:
Jorge Orpinel
2020-01-29 00:21:30 -06:00
parent b10057a1b2
commit b3ff72c983
5 changed files with 11 additions and 11 deletions
+1 -1
View File
@@ -89,7 +89,7 @@ class DvcParser(argparse.ArgumentParser):
class VersionAction(argparse.Action): # pragma: no cover
# pylint: disable=too-few-public-methods
"""Shows dvc version and exits."""
"""Shows DVC version and exits."""
def __call__(self, parser, namespace, values, option_string=None):
from dvc import __version__
+1 -1
View File
@@ -412,7 +412,7 @@ class OutputBase(object):
if not self.info:
logger.warning(
"Output '{}'({}) is missing version info. Cache for it will "
"not be collected. Use dvc repro to get your pipeline up to "
"not be collected. Use `dvc repro` to get your pipeline up to "
"date.".format(self, self.stage)
)
return NamedCache()
+4 -4
View File
@@ -23,13 +23,13 @@ logger = logging.getLogger(__name__)
class StateVersionTooNewError(DvcException):
"""Thrown when dvc version is older than the state database version."""
"""Thrown when DVC version is older than the state database version."""
def __init__(self, dvc_version, expected, actual):
super().__init__(
"you are using an old version '{dvc_version}' of dvc that is "
"using state file version '{expected}' which is not compatible "
"with the state file version '{actual}' that is used in this "
"you are using an old version '{dvc_version}' of DVC that is "
"using state file version '{expected}', which is not compatible "
"with the state file version '{actual}', that is used in this "
"repo. Please upgrade right now!".format(
dvc_version=dvc_version, expected=expected, actual=actual
)
+2 -2
View File
@@ -11,7 +11,7 @@ _BASE_VERSION = "0.82.3"
def _generate_version(base_version):
"""Generate a version with information about the git repository"""
"""Generate a version with information about the Git repository."""
pkg_dir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
if not _is_git_repo(pkg_dir) or not _have_git():
@@ -28,7 +28,7 @@ def _generate_version(base_version):
def _is_git_repo(dir_path):
"""Is the given directory version-controlled with git?"""
"""Is the given directory version-controlled with Git?"""
return os.path.exists(os.path.join(dir_path, ".git"))
+3 -3
View File
@@ -498,9 +498,9 @@ class TestWarnOnOutdatedStage(TestDvc):
self._caplog.clear()
self.main(["status", "-c"])
expected_warning = (
"Output 'bar'(Stage: 'bar.dvc') is missing version info."
" Cache for it will not be collected."
" Use dvc repro to get your pipeline up to date."
"Output 'bar'(Stage: 'bar.dvc') is missing version info. "
"Cache for it will not be collected. "
"Use `dvc repro` to get your pipeline up to date."
)
assert expected_warning in self._caplog.text