Skip to content

fix: accept integer GPU indexes in nvidia_gpus#43

Merged
alubbock merged 1 commit intomainfrom
fix/nvidia-gpus-type
Mar 13, 2026
Merged

fix: accept integer GPU indexes in nvidia_gpus#43
alubbock merged 1 commit intomainfrom
fix/nvidia-gpus-type

Conversation

@alubbock
Copy link
Copy Markdown
Owner

Summary

  • nvidia_gpus validation used .match(gpu) which requires strings, but the README documents integer indexes like nvidia_gpus = (0, )
  • Convert GPU identifiers to str() before regex validation and when joining for the nvidia-smi command
  • Added test test_nvidia_gpus_integer_accepted

Test plan

  • Existing nvidia tests pass
  • New test verifies integer GPU indexes are accepted

The README documents `nvidia_gpus = (0, )` but the regex validation
called `.match(gpu)` which requires a string, causing TypeError on
integers. Convert to str() before validation and when joining for
the nvidia-smi command.
@alubbock alubbock merged commit b4fc917 into main Mar 13, 2026
20 checks passed
@alubbock alubbock deleted the fix/nvidia-gpus-type branch March 13, 2026 10:20
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.

1 participant