ensure mkdirs_exists_ok is not called for URLs

albatross
Greg Hogan 2020-06-08 19:29:33 -07:00
parent 5fdb60d43e
commit 7bf9b04570
1 changed files with 2 additions and 0 deletions

View File

@ -5,6 +5,8 @@ from atomicwrites import AtomicWriter
def mkdirs_exists_ok(path):
if path.startswith('http'):
raise ValueError('URL path')
try:
os.makedirs(path)
except OSError: