-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Open
Labels
P2Important issue, but not time-criticalImportant issue, but not time-criticalcommunity-backlogcoreIssues that should be addressed in Ray CoreIssues that should be addressed in Ray CoreenhancementRequest for new feature and/or capabilityRequest for new feature and/or capability
Description
Description
I'm not sure if there is currently a way to do this, ideally resource dictionaries would be typed like
class Resources(TypedDict, extra_items=float):
CPU: float
GPU: float
memory: float
object_store_memory: float
I don't think this is currently possible (please let us know if you know it is) -- but will be possible with this PEP: https://peps.python.org/pep-0728/
Use case
This will give people autocomplete in their IDE and make it less likely to mistype the keys in the dict (and still be fully compatible with the current API) :)
Metadata
Metadata
Assignees
Labels
P2Important issue, but not time-criticalImportant issue, but not time-criticalcommunity-backlogcoreIssues that should be addressed in Ray CoreIssues that should be addressed in Ray CoreenhancementRequest for new feature and/or capabilityRequest for new feature and/or capability