Fix type of resource paths not being bytes.

Formerly the resource paths would just be what `json.loads` returned, which would be Unicode strings. This would cause problems when the `resources` module generates the URIs, silently being converted to `unicode`, ultimately leading to `httplib` complaining `UnicodeDecodeError` in some cases, e.g. setting non-ASCII values for 2i.

This commit just encodes the returned paths with UTF-8, which should fix the issue.

Thanks in advance!