Re: [Tutor] file questions

2009-11-25 Thread Alan Gauld
"spir" wrote 1) encoding guess How can python do that? I'll let someone else try that one :-) 2) time stamp How to read it (found no attr in "file" type)? (If possible in platform independant manner, and as datetime object.) Which timestamp? There are several. To read them use the os.p

[Tutor] file questions

2009-11-25 Thread spir
Hello, 1) encoding guess >From the library manual: file.encoding The encoding that this file uses. When Unicode strings are written to a file, they will be converted to byte strings using this encoding. In addition, when the file is connected to a terminal, the attribute gives the encoding t