I think you need to use ```six.string_type``` here. @mdboom?