old_contents: unset = object()
  
  
  def of(d):
      return {k: v for k, v in d.iteritems() if v != unset}
  
  
new_contents: from six import iteritems
  unset = object()
  
  
  def of(d):
      return {k: v for k, v in iteritems(d) if v != unset}
  
  
subject: Replace iteritems with six helper