code: def dependencies_draft3(validator, dependencies, instance, schema):
      if not validator.is_type(instance, "object"):
          return
  
      for property, dependency in iteritems(dependencies):
          if property not in instance:
              continue
  
          if validator.is_type(dependency, "object"):
              for error in validator.descend(
                  instance,
                  dependency,
                  schema_path=property,
              ):
                  yield error
          elif validator.is_type(dependency, "string"):
              if dependency not in instance:
                  yield ValidationError(
                      "%r is a dependency of %r"
                      % (dependency, property)
                  )
          else:
              for each in dependency:
                  if each not in instance:
                      message = "%r is a dependency of %r"
                      yield ValidationError(message % (each, property))
  
file_path: catboost/contrib/python/jsonschema/py2/jsonschema/_legacy_validators.py
imports: from jsonschema import _utils
  from jsonschema.compat import iteritems
  from jsonschema.exceptions import ValidationError
label_desc: Use image node_id 1 for calling a global function with example usage: dependencies_draft3(validator, dependencies, instance, schema) without return types