Skip to content

Commit 6149bda

Browse files
committed
Fix redundant type params
1 parent 18129a8 commit 6149bda

File tree

1 file changed

+13
-17
lines changed

1 file changed

+13
-17
lines changed

temporalio/client.py

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -817,7 +817,7 @@ async def execute_update_with_start_workflow(
817817
self,
818818
update: temporalio.workflow.UpdateMethodMultiParam[[SelfType], LocalReturnType],
819819
*,
820-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
820+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
821821
id: Optional[str] = None,
822822
rpc_metadata: Mapping[str, str] = {},
823823
rpc_timeout: Optional[timedelta] = None,
@@ -832,7 +832,7 @@ async def execute_update_with_start_workflow(
832832
],
833833
arg: ParamType,
834834
*,
835-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
835+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
836836
id: Optional[str] = None,
837837
rpc_metadata: Mapping[str, str] = {},
838838
rpc_timeout: Optional[timedelta] = None,
@@ -847,7 +847,7 @@ async def execute_update_with_start_workflow(
847847
],
848848
*,
849849
args: MultiParamSpec.args, # pyright: ignore
850-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
850+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
851851
id: Optional[str] = None,
852852
rpc_metadata: Mapping[str, str] = {},
853853
rpc_timeout: Optional[timedelta] = None,
@@ -860,22 +860,20 @@ async def execute_update_with_start_workflow(
860860
update: str,
861861
arg: Any = temporalio.common._arg_unset,
862862
*,
863-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
863+
start_workflow_operation: WithStartWorkflowOperation[Any, Any],
864864
args: Sequence[Any] = [],
865865
id: Optional[str] = None,
866866
result_type: Optional[Type] = None,
867867
rpc_metadata: Mapping[str, str] = {},
868868
rpc_timeout: Optional[timedelta] = None,
869869
) -> Any: ...
870870

871-
# TODO (dan):
872-
# temporalio/client.py:840: error: Overloaded function implementation does not accept all possible arguments of signature 1 [misc]
873-
async def execute_update_with_start_workflow( # type: ignore
871+
async def execute_update_with_start_workflow(
874872
self,
875873
update: Union[str, Callable],
876874
arg: Any = temporalio.common._arg_unset,
877875
*,
878-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
876+
start_workflow_operation: WithStartWorkflowOperation[Any, Any],
879877
args: Sequence[Any] = [],
880878
id: Optional[str] = None,
881879
result_type: Optional[Type] = None,
@@ -936,7 +934,7 @@ async def start_update_with_start_workflow(
936934
self,
937935
update: temporalio.workflow.UpdateMethodMultiParam[[SelfType], LocalReturnType],
938936
*,
939-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
937+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
940938
wait_for_stage: WorkflowUpdateStage,
941939
id: Optional[str] = None,
942940
rpc_metadata: Mapping[str, str] = {},
@@ -952,7 +950,7 @@ async def start_update_with_start_workflow(
952950
],
953951
arg: ParamType,
954952
*,
955-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
953+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
956954
wait_for_stage: WorkflowUpdateStage,
957955
id: Optional[str] = None,
958956
rpc_metadata: Mapping[str, str] = {},
@@ -968,7 +966,7 @@ async def start_update_with_start_workflow(
968966
],
969967
*,
970968
args: MultiParamSpec.args, # pyright: ignore
971-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
969+
start_workflow_operation: WithStartWorkflowOperation[SelfType, Any],
972970
wait_for_stage: WorkflowUpdateStage,
973971
id: Optional[str] = None,
974972
rpc_metadata: Mapping[str, str] = {},
@@ -982,7 +980,7 @@ async def start_update_with_start_workflow(
982980
update: str,
983981
arg: Any = temporalio.common._arg_unset,
984982
*,
985-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
983+
start_workflow_operation: WithStartWorkflowOperation[Any, Any],
986984
wait_for_stage: WorkflowUpdateStage,
987985
args: Sequence[Any] = [],
988986
id: Optional[str] = None,
@@ -991,14 +989,12 @@ async def start_update_with_start_workflow(
991989
rpc_timeout: Optional[timedelta] = None,
992990
) -> WorkflowUpdateHandle[Any]: ...
993991

994-
# TODO (dan):
995-
# temporalio/client.py:926: error: Overloaded function implementation does not accept all possible arguments of signature 1 [misc]
996-
async def start_update_with_start_workflow( # type: ignore
992+
async def start_update_with_start_workflow(
997993
self,
998994
update: Union[str, Callable],
999995
arg: Any = temporalio.common._arg_unset,
1000996
*,
1001-
start_workflow_operation: WithStartWorkflowOperation[SelfType, ReturnType],
997+
start_workflow_operation: WithStartWorkflowOperation[Any, Any],
1002998
wait_for_stage: WorkflowUpdateStage,
1003999
args: Sequence[Any] = [],
10041000
id: Optional[str] = None,
@@ -6145,7 +6141,7 @@ async def _start_workflow_update_with_start(
61456141
):
61466142
break
61476143

6148-
handle = WorkflowUpdateHandle(
6144+
handle: WorkflowUpdateHandle[Any] = WorkflowUpdateHandle(
61496145
client=self._client,
61506146
id=update_req.request.meta.update_id,
61516147
workflow_id=start_input.id,

0 commit comments

Comments
 (0)