def _sorted_keys_items(dobj):
    """Return dictionary items sorted by key."""
    keys = sorted(dobj.keys())
    for key in keys:
        yield key, dobj[key]
def _sorted_keys_items ( dobj ) : keys = sorted ( dobj . keys ( ) ) for key in keys : yield key , dobj [ key ]
Return dictionary items sorted by key.