issue #391: FileService metadata dict keys must be Unicode.

This is a regression since moving FileService from a 2.6-compatible file
with unicode_literals set, to a <2.5-compatible file.
issue510
David Wilson 6 years ago
parent 1756cea65b
commit 15ddecdb58

@ -787,12 +787,12 @@ class FileService(Service):
raise IOError('%r is not a regular file.' % (path,)) raise IOError('%r is not a regular file.' % (path,))
return { return {
'size': st.st_size, u'size': st.st_size,
'mode': st.st_mode, u'mode': st.st_mode,
'owner': self._name_or_none(pwd.getpwuid, 0, 'pw_name'), u'owner': self._name_or_none(pwd.getpwuid, 0, 'pw_name'),
'group': self._name_or_none(grp.getgrgid, 0, 'gr_name'), u'group': self._name_or_none(grp.getgrgid, 0, 'gr_name'),
'mtime': st.st_mtime, u'mtime': st.st_mtime,
'atime': st.st_atime, u'atime': st.st_atime,
} }
def on_shutdown(self): def on_shutdown(self):

Loading…
Cancel
Save