File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 3232import temporalio .common
3333import temporalio .converter
3434import temporalio .nexus
35- from temporalio .exceptions import ApplicationError
35+ from temporalio .exceptions import ApplicationError , WorkflowAlreadyStartedError
3636from temporalio .nexus import Info , logger
3737from temporalio .service import RPCError , RPCStatusCode
3838
@@ -445,6 +445,12 @@ def _exception_to_handler_error(err: BaseException) -> nexusrpc.HandlerError:
445445 type = nexusrpc .HandlerErrorType .INTERNAL ,
446446 retryable_override = not err .non_retryable ,
447447 )
448+ elif isinstance (err , WorkflowAlreadyStartedError ):
449+ handler_err = nexusrpc .HandlerError (
450+ err .message ,
451+ type = nexusrpc .HandlerErrorType .INTERNAL ,
452+ retryable_override = False ,
453+ )
448454 elif isinstance (err , RPCError ):
449455 if err .status == RPCStatusCode .INVALID_ARGUMENT :
450456 handler_err = nexusrpc .HandlerError (
You can’t perform that action at this time.
0 commit comments