Open simonokeefe opened 2 years ago
Knox tried os.path.isfile
but it also failed.
Condition: os.path.isfile('\\knox.local\fileserver\GIS\Data\Development\property\data_in\LandVictoria\SpatialDatamart\VicmapSimplified1\latest\VMPROP\V_PARCEL_MP.tab') is False
Could it have something to do with the dot in the network mount name? Or could it be this:
Note: os.path.exists() function may return False, if permission is not granted to execute os.stat() on the requested file, even if the path exists.
(from: https://www.geeksforgeeks.org/python-os-path-exists-method/)
@rdewit Thanks for your input. I didn't realise you were notified about issues or anything in this repo. I'll await further feedback from the council about another workaround I've suggested for them.
Knox's Pozi Connect log file shows that the
os.path.exists
function fails on a valid UNC path.This Stack Overflow comment suggests using
os.path.isfile
instead ofos.path.exists
.https://stackoverflow.com/questions/15077424/pros-and-cons-between-os-path-exists-vs-os-path-isdir#comment72540108_15077527