title: (python) os.path.exists os.path.isfile lies?
body: <p>os.path.exists is giving me incorrect answers.</p>
  
  <p>it's not the same problem discussed at below link since I'm at windows.
  Are there other reasons for it to fail?</p>
  
  <p><a href="https://stackoverflow.com/questions/3112546/os-path-exists-lies">os.path.exists() lies</a> </p>
  
  <p>The test returns ok when I test it against a file at the same directory as the *.py script runs, but none of its sub directories.. </p>
  
  <p>-EDIT-</p>
  
  <p>I'm using absolute path. </p>
  
  <p>I'm looking at one of the sub directories as this script runs,       and can literally see file's last modified time field being changed in the windows explorer.<br>
  There are no other stuff going on my computer I can think of that will modify the files in question.</p>
  
  <pre><code>def SaveIfNewer(doc, aiFile, pngFile):
      options = win32com.client.Dispatch('Illustrator.ExportOptionsPNG24')
      options.SetArtBoardClipping(True)
      if (os.path.exists(pngFile)):
          aiFileTime = os.stat(aiFile)[8]
          pngFileTime = os.stat(pngFile)[8]
          print("aiFileTime: ", aiFileTime, "pngFileTime: ", pngFileTime)
  
          if(aiFileTime &gt; pngFileTime):
              os.remove(pngFile)
  
      if( not os.path.isfile(pngFile)):
          doc.Export(pngFile, constants.aiPNG24, options)
          print 'exporting:', pngFile
      else:
          print 'skipping file:', pngFile
  </code></pre>