def verify_fallback_consistency(self, dirname, varname, cached_dep):
    subi = self.subprojects.get(dirname)
    if ((not cached_dep) or (not varname) or (not subi) or (not cached_dep.found())):
        return
    dep = subi.get_variable_method([varname], {})
    if (dep.held_object != cached_dep):
        m = 'Inconsistency: Subproject has overridden the dependency with another variable than {!r}'
        raise DependencyException(m.format(varname))
def verify_fallback_consistency(self, dirname, varname, cached_dep):
    subi = self.subprojects.get(dirname)
    if ((not cached_dep) or (not varname) or (not subi) or (not cached_dep.found())):
        return
    dep = subi.get_variable_method([varname], {})
    if (dep.held_object != cached_dep):
        m = 'Inconsistency: Subproject has overridden the dependency with another variable than {!r}'
        raise DependencyException(m.format(varname))