Skip to content

Commit

Permalink
Merge pull request #375 from argonne-lcf/release23
Browse files Browse the repository at this point in the history
Update for release
  • Loading branch information
cms21 authored Oct 31, 2023
2 parents a592495 + a3c8e7d commit 125b4b1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion balsam/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from balsam.util import config_root_logger

__version__ = "0.7.0.a22"
__version__ = "0.7.0.a23"
config_root_logger()
2 changes: 1 addition & 1 deletion balsam/_api/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def __repr__(self) -> str:

def __str__(self) -> str:
d = self.display_dict()
return yaml.dump(d, sort_keys=False, indent=4)
return str(yaml.dump(d, sort_keys=False, indent=4))

def __eq__(self, other: Any) -> bool:
if not isinstance(other, BalsamModel):
Expand Down
10 changes: 5 additions & 5 deletions balsam/_api/models.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# This file was auto-generated via /home/turam/miniconda3/bin/python balsam/schemas/api_generator.py
# [git rev 7634992]
# This file was auto-generated via /Users/turam/opt/miniconda3/bin/python balsam/schemas/api_generator.py
# [git rev 5034973]
# Do *not* make changes to the API by changing this file!

import datetime
Expand Down Expand Up @@ -765,7 +765,7 @@ class BatchJob(balsam._api.bases.BatchJobBase):
job_mode = Field[balsam.schemas.batchjob.JobMode]()
optional_params = Field[typing.Dict[str, str]]()
filter_tags = Field[typing.Dict[str, str]]()
partitions = Field[Optional[typing.Union[typing.List[balsam.schemas.batchjob.BatchJobPartition], None]]]()
partitions = Field[typing.Optional[typing.List[balsam.schemas.batchjob.BatchJobPartition]]]()
site_id = Field[int]()
project = Field[str]()
queue = Field[str]()
Expand All @@ -786,7 +786,7 @@ def __init__(
queue: str,
optional_params: Optional[typing.Dict[str, str]] = None,
filter_tags: Optional[typing.Dict[str, str]] = None,
partitions: Optional[typing.Union[typing.List[balsam.schemas.batchjob.BatchJobPartition], None]] = None,
partitions: Optional[typing.Optional[typing.List[balsam.schemas.batchjob.BatchJobPartition]]] = None,
**kwargs: Any,
) -> None:
"""
Expand Down Expand Up @@ -918,7 +918,7 @@ def create(
queue: str,
optional_params: Optional[typing.Dict[str, str]] = None,
filter_tags: Optional[typing.Dict[str, str]] = None,
partitions: Optional[typing.Union[typing.List[balsam.schemas.batchjob.BatchJobPartition], None]] = None,
partitions: Optional[typing.Optional[typing.List[balsam.schemas.batchjob.BatchJobPartition]]] = None,
) -> BatchJob:
"""
Create a new BatchJob object and save it to the API in one step.
Expand Down
10 changes: 6 additions & 4 deletions balsam/config/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,10 +236,12 @@ def save(self, path: Union[str, Path]) -> None:
fp.write(self.dump_yaml())

def dump_yaml(self) -> str:
return yaml.dump(
json.loads(self.json()),
sort_keys=False,
indent=4,
return str(
yaml.dump(
json.loads(self.json()),
sort_keys=False,
indent=4,
)
)

@classmethod
Expand Down

0 comments on commit 125b4b1

Please sign in to comment.