[mythtv-users] mythfs.py barfing on non-ascii encoding
Brian J. Murrell
brian at interlinx.bc.ca
Fri May 14 14:23:05 UTC 2010
Trying to use mythfs.py (on 0.23) and seeing this on trying to mount it:
$ python /usr/share/doc/mythtv-backend/contrib/exports/mythfs.py Recordings,'%T/(%oY%-%om%-%od) %S' /mnt/test -o ro,allow_other
Traceback (most recent call last):
File "/usr/share/doc/mythtv-backend/contrib/exports/mythfs.py", line 394, in <module>
File "/usr/share/doc/mythtv-backend/contrib/exports/mythfs.py", line 390, in main
File "/usr/share/doc/mythtv-backend/contrib/exports/mythfs.py", line 334, in prep
File "/usr/share/doc/mythtv-backend/contrib/exports/mythfs.py", line 84, in populate
path = self.getPath(data)
File "/usr/share/doc/mythtv-backend/contrib/exports/mythfs.py", line 267, in getPath
return data.formatPath(self.fmt, '-').encode('utf-8').\
File "/usr/lib/python2.6/dist-packages/MythTV/MythData.py", line 689, in formatPath
tmp = str(self[data]).replace('/','-')
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 3: ordinal not in range(128)
I know the show in question is most likely going to be Pokemon (with a
properly accented 'e').
I have already tried to set in my environment:
but that doesn't seem to be helping.
P.S. While I am talking about mythfs.py, will the mounted filesystem
allow me to copy over an exported "file"? i.e. if I wanted to replace
one recording with another file, will the mythfs.py mounted filesystem
allow that? From a brief look at the code, I'm guessing no. I see no
"write" handler in MythFS. Is this simply a lacking in the mythfs.py
implementation, or does the myth protocol behind it not allow writing?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 198 bytes
Desc: This is a digitally signed message part
More information about the mythtv-users