Skip to content

Commit

Permalink
Add some new missing fields
Browse files Browse the repository at this point in the history
  • Loading branch information
epwalsh committed May 10, 2024
1 parent 994482d commit efacc96
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ use patch releases for compatibility fixes instead.
### Added

- Added `preemptible` argument to `TaskSpec.new()`.
- Added `Workspace.max_workload_priority` field.
- Added `Job.preemptible` field.

## [v1.26.11](https://github.com/allenai/beaker-py/releases/tag/v1.26.11) - 2024-05-10

Expand Down
1 change: 1 addition & 0 deletions beaker/data_model/job.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ class Job(BaseModel):
host_networking: bool = False
port_mappings: Optional[Dict[str, int]] = None
result: Optional[ExecutionResult] = None
preemptible: Optional[bool] = None

@property
def display_name(self) -> str:
Expand Down
2 changes: 2 additions & 0 deletions beaker/data_model/workspace.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

from .account import Account
from .base import BaseModel, BasePage, StrEnum
from .experiment_spec import Priority

__all__ = [
"WorkspaceSize",
Expand Down Expand Up @@ -38,6 +39,7 @@ class Workspace(BaseModel):
created: datetime
modified: datetime
archived: bool = False
max_workload_priority: Optional[Priority] = None


class WorkspaceRef(BaseModel):
Expand Down

0 comments on commit efacc96

Please sign in to comment.