Pathlib ruta existe
import pathlib
path = pathlib.Path('my/path/to/file/or/dir')
assert path.exists()
Clever Crossbill
import pathlib
path = pathlib.Path('my/path/to/file/or/dir')
assert path.exists()