On 06/06/2013 22:07, Lele Gaifax wrote:
Νικόλαος Κούρας <nikos.gr...@gmail.com> writes:
Tahnks here is what i have up until now with many corrections.
I'm afraid many more are needed :-)
...
# rename filename form greek bytestreams --> utf-8 bytestreams
old_path = b'/home/nikos/public_html/data/apps/' + b'filename')
new_path = b'/home/nikos/public_html/data/apps/' +
b'new_filename')
os.rename( old_path, new_path )
a) there are two syntax errors, you have spurious close brackets there
b) you are basically assigning *constant* expressions to both variables,
most probably not what you meant
Yet again, he's changed things unnecessarily, and the code was meant
only as a one-time
fix to correct the encoding of some filenames. :-(
--
http://mail.python.org/mailman/listinfo/python-list