Make directory exist ok for ray spinning up multiple replicas on a single instance (#33604)
Signed-off-by: Jiang Wu <jwu@cclgroup.com>
This commit is contained in:
@@ -64,9 +64,7 @@ class ObjectStorageModel:
|
||||
"model_streamer",
|
||||
hashlib.sha256(str(url).encode()).hexdigest()[:8],
|
||||
)
|
||||
if os.path.exists(dir_name):
|
||||
shutil.rmtree(dir_name)
|
||||
os.makedirs(dir_name)
|
||||
os.makedirs(dir_name, exist_ok=True)
|
||||
self.dir = dir_name
|
||||
logger.debug("Init object storage, model cache path is: %s", dir_name)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user