mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-10 15:28:34 +01:00
Merge pull request #753 from efiop/master
status: report callback stages as changed
This commit is contained in:
+6
-2
@@ -91,10 +91,14 @@ class Stage(object):
|
||||
self.project.logger.debug(msg.format(self.relpath, self.md5, md5))
|
||||
return True
|
||||
|
||||
@property
|
||||
def is_callback(self):
|
||||
return not self.is_data_source and len(self.deps) == 0
|
||||
|
||||
def changed(self):
|
||||
ret = False
|
||||
|
||||
if not self.is_data_source and len(self.deps) == 0:
|
||||
if self.is_callback:
|
||||
ret = True
|
||||
|
||||
for entry in itertools.chain(self.outs, self.deps):
|
||||
@@ -268,7 +272,7 @@ class Stage(object):
|
||||
ret.update(self._status(self.deps, 'deps'))
|
||||
ret.update(self._status(self.outs, 'outs'))
|
||||
|
||||
if ret or self.changed_md5():
|
||||
if ret or self.changed_md5() or self.is_callback:
|
||||
return {self.relpath: ret}
|
||||
|
||||
return {}
|
||||
|
||||
Reference in New Issue
Block a user