[Tutor] os.path.exists(path) returns false when the pathactually exists!

Thorsten Kampe thorsten at thorstenkampe.de
Sat Jul 28 11:57:49 CEST 2007

* Tiger12506 (Sat, 28 Jul 2007 10:33:36 -0500)
> > So the better question is, does is this file a broken symbolic link or
> > can os.stat() be executed on it?
> >
> > How do I find if it is a broken symbolic link in Windows 2000 ?
> >
> > os.stat(path) returns an OSError saying that there is no such file or 
> > directory
> Wow. I've never heard of this. What are the file's attributes? What does it 
> say about the file when you right-click Properties? Hmmm... what's going on 
> here? Permission not granted to execute os.stat()? Why wouldn't anyone have 
> permission to do that?
> A broken symbolic link... That means a hard link that has been cut-off 
> right?

No, symbolic links and hard links are totally different.

> (Hard-links are like pointers to files in NTFS)  ~ so if the file's 
> been moved, that hard link will point to nothing, being broken, right?

Thre are no "broken hard links"...

More information about the Tutor mailing list