def _attr_key(attr):
return (attr[<NUM_LIT:0>][<NUM_LIT:0>] or '<STR_LIT>'), attr[<NUM_LIT:0>][<NUM_LIT:1>]<EOL>
Return an appropriate key for an attribute for sorting

    Attributes have a namespace that can be either ``None`` or a string. We
    can't compare the two because they're different types, so we convert
    ``None`` to an empty string first.