str will raise an exception if someone has non-ASCII chars in their home directory, so use unicode instead.