Before base64 encoding the _id, UTF-8 encode it

Because we currently bomb out with a Unicode error when we try to base64
encode a unicode class. This encodes the unicode to str using UTF-8
codec.

The new test confirms that we can support non-ascii Unicode characters.

The existing test_data_id shows that the _id does *not* change for
existing, ascii-only ids. So we don't need to flush the buckets.