You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2020/06/01 15:24:49 UTC

[GitHub] [incubator-dolphinscheduler] xiashao1980 opened a new issue #2867: [QUESTION] How to make current process stop in Python script?

xiashao1980 opened a new issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867


   In my Python script. I want to stop the current process if some condition was true. So how to stop it and report some error message to the UI list?
   
   
   **Describe the question**
   我想在Python节点中当检查到某些条件满足的情况下,我需要停止当前工作流实例并报错。请问是否支持? 如果用Python脚本实现?
   
   
   **Which version of DolphinScheduler:**
    -[1.2.0]
   
   Thanks.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] gabrywu commented on issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
gabrywu commented on issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867#issuecomment-645098012


   > use exit will be OK, if exit result is not 0, the task will be judged as failure, at the same time the workflow will stop if you choose stop when you started the workflow definition, then you can do some things, and then resume failure from the workflow instance list page
   > ![image](https://user-images.githubusercontent.com/15833811/84459944-38bc6300-ac9b-11ea-9492-4f47eeef3560.png)
   
   @xiashao1980  you can try this way. Feel free to reopen issue if necessary


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] xiashao1980 commented on issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
xiashao1980 commented on issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867#issuecomment-642748709


   Sometimes, I need to stop the current instance and ask the user to fix some problems, then resume this flow from the latest step.
   I just want to know if there is some existing way to implement this function. Just like return a false result to the worker process. Or use sys.exit(ExitStatus.failure)?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] gabrywu closed issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
gabrywu closed issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] Rubik-W commented on issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
Rubik-W commented on issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867#issuecomment-637303003


   You can try, when some condition was true, throw exception, and failure strategy set to "end".
   the node will set to fail.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] dailidong commented on issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
dailidong commented on issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867#issuecomment-643036425


   use exit will be OK, if exit result is not 0, the task will be judged as failure, at the same time the workflow will stop if you choose stop when you started the workflow definition,  then you can do some things, and then resume failure from the workflow instance list page
   ![image](https://user-images.githubusercontent.com/15833811/84459944-38bc6300-ac9b-11ea-9492-4f47eeef3560.png)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-dolphinscheduler] Rubik-W commented on issue #2867: [QUESTION] How to make current process stop in Python script?

Posted by GitBox <gi...@apache.org>.
Rubik-W commented on issue #2867:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/2867#issuecomment-643037447


   In process instance list page, you can stop instance or continue instance.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org