-
-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prevent crash if folder already exists #2867
Conversation
oops!
|
@jcohenadad, up to now i only tested if the sbatch batch script worked, i am not sure i can configure slurm without connecting to a cluster. But it should work, I'm just wondering if |
@PaulBautin i'm not sure what post you are referring to in the URL, but this is the reason i switched for makedirs:
|
@jcohenadad you are right. So unless you want a test with another configuration of slurm, it is all good for me. |
if it's all good you need to approve the review so i can merge |
* Update sct_run_batch.py * Replaced mkdir by makedirs
When launching multiple
sct_run_batch
in parallel using run_all with the same output folder, the following error sometimes happens:This PR fixes the problem by changing:
os.mkdir(pth)
foros.mkdir(pth, exist_ok=True)
Fixes #2866