problems with os.path.isdir on windows shares (i've read the FAQ)

Roger Upole rupole at hotmail.com
Tue Jan 20 01:29:41 EST 2004


This used to work (1.5.2 maybe ?), and I got bit pretty bad when it stopped.
Had a small function to copy a file to either a full path or into a
directory,
as determined by os.path.isdir.  After upgrading, the results weren't pretty
the
first time I tried to copy a file to a share.
I had to replace os.path.isdir(pathname) with
win32file.GetFileAttributes(pathname) & win32con.FILE_ATTRIBUTE_DIRECTORY
to get around it.
          Roger

"todd smith" <todcsmith at yahoo.com> wrote in message
news:4489035c.0401190821.bf3ff14 at posting.google.com...
> "Michel Claveau/Hamster" <No.Spam.mc at No.Spam.mclaveau.No.Spam.com> wrote
in message news:<bua2ud$cm7$1 at news-reader2.wanadoo.fr>...
> > Hi !
> >
> > \\\\ren\\backup   is perhaps no a directory, but the name of a shared
> > ressource.
> >
> >
> >
> > @-salutations
>
>
> i'm a bit confused as to what you mean by a shared resource. but
> \\ren\backup is definately a shared directory, i mkdir'd it myself :)





More information about the Python-list mailing list