Skip to content

Commit

Permalink
Make the job_id an int instead of str
Browse files Browse the repository at this point in the history
Signed-off-by: Fabrice Normandin <normandf@mila.quebec>
  • Loading branch information
lebrice committed Apr 25, 2024
1 parent 4b0b4ff commit 6d8ebac
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions milatools/cli/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,10 +242,10 @@ def add_arguments(parser: argparse.ArgumentParser):
)
code_parser.add_argument(
"--job",
type=str,
type=int,
default=None,
help="Job ID to connect to",
metavar="VALUE",
metavar="JOB_ID",
)
code_parser.add_argument(
"--node",
Expand Down Expand Up @@ -563,7 +563,7 @@ def code(
path: str,
command: str,
persist: bool,
job: str | None,
job: int | None,
node: str | None,
alloc: list[str],
cluster: Cluster = "mila",
Expand Down Expand Up @@ -801,7 +801,7 @@ class StandardServerArgs(TypedDict):
alloc: list[str]
"""Extra options to pass to slurm."""

job: str | None
job: int | None
"""Job ID to connect to."""

name: str | None
Expand Down Expand Up @@ -954,10 +954,10 @@ def _add_standard_server_args(parser: ArgumentParser):
)
parser.add_argument(
"--job",
type=str,
type=int,
default=None,
help="Job ID to connect to",
metavar="VALUE",
metavar="JOB_ID",
)
parser.add_argument(
"--name",
Expand Down Expand Up @@ -1005,7 +1005,7 @@ def _standard_server(
port: int | None,
name: str | None,
node: str | None,
job: str | None,
job: int | None,
alloc: list[str],
port_pattern=None,
token_pattern=None,
Expand Down Expand Up @@ -1290,7 +1290,7 @@ def get_colour(used: float, max: float) -> str:
def _find_allocation(
remote: Remote,
node: str | None,
job: str | None,
job: int | str | None,
alloc: list[str],
cluster: Cluster = "mila",
job_name: str = "mila-tools",
Expand Down

0 comments on commit 6d8ebac

Please sign in to comment.