determining file type

Sion Arrowsmith siona at chiark.greenend.org.uk
Wed Jun 14 07:39:16 EDT 2006


Ritesh Raj Sarraf <riteshsarraf at gmail.com> wrote:
>Also,
>f =3D file ('some_file.jpg')
>
>throws an error.
>"str object is not callable"

You know all the times people say in this group "Don't use list
or str or file[HINT] or anything else that shadows a built in as
a variable name"? Now you know why.

-- 
\S -- siona at chiark.greenend.org.uk -- http://www.chaos.org.uk/~sion/
  ___  |  "Frankly I have no feelings towards penguins one way or the other"
  \X/  |    -- Arthur C. Clarke
   her nu becomeþ se bera eadward ofdun hlæddre heafdes bæce bump bump bump



More information about the Python-list mailing list