attribute of the self object for name converted into a string. raise an KeyError with an argument string 'Unknown media type "%s"', where '%s' is replaced with name.
raise KeyError ( 'Unknown media type "%s"' % name )