code: def validate_keys(dict_, expected, funcname):
      """Validate that a dictionary has an expected set of keys."""
      expected = set(expected)
      received = set(dict_)
  
      missing = expected - received
      if missing:
          raise ValueError(
              "Missing keys in {}:\n"
              "Expected Keys: {}\n"
              "Received Keys: {}".format(
                  funcname,
                  sorted(expected),
                  sorted(received),
              )
          )
  
      unexpected = received - expected
      if unexpected:
          raise ValueError(
              "Unexpected keys in {}:\n"
              "Expected Keys: {}\n"
              "Received Keys: {}".format(
                  funcname,
                  sorted(expected),
                  sorted(received),
              )
          )
  
imports: from datetime import tzinfo
  from functools import partial
  from operator import attrgetter
  from numpy import dtype
  import pandas
  from pytz import timezone
  from six import iteritems, string_types, PY3
  from toolz import valmap, complement, compose
  import toolz.curried.operator
  from zipline.utils.compat import wraps
  from zipline.utils.functional import getattrs
  from zipline.utils.preprocess import call, preprocess
label_desc: Use image node_id 19 for calling a global function with example usage: validate_keys(dict_, expected, funcname) without return types