mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-11 23:10:10 +01:00
Remove check deps flag and add warning on req miss
This commit is contained in:
@@ -21,6 +21,6 @@ def supported_url(url):
|
||||
|
||||
def Remote(project, config):
|
||||
for r in REMOTES:
|
||||
if r.supported(config, check_dependencies=True):
|
||||
if r.supported(config):
|
||||
return r(project, config)
|
||||
raise DvcException('Remote \'{}\' is not supported.'.format(config))
|
||||
|
||||
+6
-4
@@ -39,10 +39,12 @@ class RemoteBase(object):
|
||||
pass
|
||||
|
||||
@classmethod
|
||||
def supported(cls, config, check_dependencies=False):
|
||||
url = config[Config.SECTION_REMOTE_URL]
|
||||
deps_ok = not check_dependencies or all(cls.REQUIRES)
|
||||
return cls.match(url) != None and deps_ok
|
||||
def supported(cls, config):
|
||||
url_ok = cls.match(config[Config.SECTION_REMOTE_URL])
|
||||
deps_ok = all(cls.REQUIRES)
|
||||
if url_ok and not deps_ok:
|
||||
Logger.warning("URL matches but requires missing dependencies")
|
||||
return url_ok and deps_ok
|
||||
|
||||
@classmethod
|
||||
def match(cls, url):
|
||||
|
||||
Reference in New Issue
Block a user