Skip to content
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

Fix a crash in cstr.to_gres_dict when the input is just "gres:gpu" #334

Merged
merged 1 commit into from
Jan 25, 2024

Conversation

tazend
Copy link
Member

@tazend tazend commented Jan 25, 2024

Slurm allows to pass things like --gres=gpu, which in this case the default value will be just one. However, the char gres value also really just contains "gres:gpu" when displayed via scontrol, with no indication of the count. The code previously assumed that Slurm internally modifies the char explicitly to reflect the default count of 1.

Fixes #333

Slurm allows to pass things like --gres=gpu, which in this case the
default value will be just one. However, the char *gres value also
really just contains "gres:gpu" when displayed via scontrol, with no
indication of the count. The code previously assumed that Slurm
internally modifies the char* explicitly to reflect the default count of
1.
@tazend tazend merged commit e88afc5 into PySlurm:main Jan 25, 2024
1 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Particular value of gres is causing cstr to crash
1 participant