File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 3434)
3535
3636# Mapping from string to protobuf enum value
37- _CRON_OVERLAP_POLICY_MAP : dict [str , int ] = {
37+ _CRON_OVERLAP_POLICY_MAP : dict [str , workflow_pb2 . CronOverlapPolicy ] = {
3838 "SKIPPED" : workflow_pb2 .CRON_OVERLAP_POLICY_SKIPPED ,
3939 "BUFFER_ONE" : workflow_pb2 .CRON_OVERLAP_POLICY_BUFFER_ONE ,
4040}
4141
4242
43- def _resolve_cron_overlap_policy (policy : CronOverlapPolicyType ) -> int :
43+ def _resolve_cron_overlap_policy (
44+ policy : CronOverlapPolicyType ,
45+ ) -> workflow_pb2 .CronOverlapPolicy :
4446 """Convert string or enum to protobuf enum value."""
4547 if isinstance (policy , str ):
4648 policy_upper = policy .upper ()
@@ -50,7 +52,7 @@ def _resolve_cron_overlap_policy(policy: CronOverlapPolicyType) -> int:
5052 "Expected 'SKIPPED' or 'BUFFER_ONE'"
5153 )
5254 return _CRON_OVERLAP_POLICY_MAP [policy_upper ]
53- return int ( policy )
55+ return policy
5456
5557
5658class StartWorkflowOptions (TypedDict , total = False ):
You can’t perform that action at this time.
0 commit comments