```isinstance(dim_coord_names, basestring)``` is preferred as it supports unicode.