Stopped by user. #5848

Closed
opened 2026-02-21 18:12:51 -05:00 by yindo · 11 comments
Owner

Originally created by @18600709862 on GitHub (Sep 28, 2024).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

0.8.3

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

I created a long text generation workflow application and then ran it,
and the application stopped automatically.
log display: Stopped by user.

timeout set:
docker-compose.xml
GUNICORN_TIMEOUT: ${GUNICORN_TIMEOUT:-3600}
API_TOOL_DEFAULT_CONNECT_TIMEOUT: ${API_TOOL_DEFAULT_CONNECT_TIMEOUT:-6000}
API_TOOL_DEFAULT_READ_TIMEOUT: ${API_TOOL_DEFAULT_READ_TIMEOUT:-3600}
environment
HTTP_REQUEST_MAX_CONNECT_TIMEOUT: 6000

✔️ Expected Behavior

run complete

Actual Behavior

Start
43.843 ms
Generate Subtitles and Outlines
1.517K tokens · 31.743 s
Extract Subtitles and Outlines
139.945 ms
Iteration
19 m 28.879 s

3个迭代
Stopped by user.
LLM 3
41.141 s
Stopped by user.
2024-09-29 08-02-06屏幕截图

Originally created by @18600709862 on GitHub (Sep 28, 2024). ### Self Checks - [X] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [X] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [X] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [X] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [X] Please do not modify this template :) and fill in all the required fields. ### Dify version 0.8.3 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce I created a long text generation workflow application and then ran it, and the application stopped automatically. log display: Stopped by user. timeout set: docker-compose.xml GUNICORN_TIMEOUT: ${GUNICORN_TIMEOUT:-3600} API_TOOL_DEFAULT_CONNECT_TIMEOUT: ${API_TOOL_DEFAULT_CONNECT_TIMEOUT:-6000} API_TOOL_DEFAULT_READ_TIMEOUT: ${API_TOOL_DEFAULT_READ_TIMEOUT:-3600} environment HTTP_REQUEST_MAX_CONNECT_TIMEOUT: 6000 ### ✔️ Expected Behavior run complete ### ❌ Actual Behavior Start 43.843 ms Generate Subtitles and Outlines 1.517K tokens · 31.743 s Extract Subtitles and Outlines 139.945 ms Iteration 19 m 28.879 s 3个迭代 Stopped by user. LLM 3 41.141 s Stopped by user. ![2024-09-29 08-02-06屏幕截图](https://github.com/user-attachments/assets/c86872d1-5788-4198-8e75-f13a1979f787)
yindo closed this issue 2026-02-21 18:12:51 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Sep 28, 2024):

@18600709862 你好!我是Dosu,我是一个可以帮助您解决错误,回答问题并成为贡献者的机器人。我会在等待人类维护者的过程中帮助您。

I found a similar issue that might be relevant to your problem. The issue titled "The workflow has ended, but there is no output on the front end of the page, and the workflow keeps spinning" was closed and referenced by another issue titled "Detailed logs break down with graph_engine and iteration node" [1].

The log message "Stopped by user" indicates that the application is being stopped manually or by some external trigger. This message is not related to timeout settings in your docker-compose.yaml or environment variables. Given the provided docker-compose.yaml, the restart: always policy is set for all services, which means the services should automatically restart unless explicitly stopped.

Here are a few potential reasons for this issue:

  1. Manual Intervention: Someone might be manually stopping the containers using commands like docker stop.
  2. External Scripts or Tools: There might be external scripts or tools that are stopping the containers.
  3. Resource Constraints: If the host machine is running out of resources (CPU, memory), Docker might stop the containers.

To further diagnose the issue, you can:

  • Check the Docker logs for more details using docker logs <container_id>.
  • Ensure no external scripts or tools are stopping the containers.
  • Monitor the resource usage on the host machine.

If none of these apply, you might need to look into Docker's event logs to see what is triggering the stop event [2].

To continue talking to Dosu, mention @dosu.

@dosubot[bot] commented on GitHub (Sep 28, 2024): <!-- Greeting --> @18600709862 你好!我是[Dosu](https://dosu.dev),我是一个可以帮助您解决错误,回答问题并成为贡献者的机器人。我会在等待人类维护者的过程中帮助您。 <!-- Answer --> I found a similar issue that might be relevant to your problem. The issue titled "[The workflow has ended, but there is no output on the front end of the page, and the workflow keeps spinning](https://github.com/langgenius/dify/issues/6906)" was closed and referenced by another issue titled "[Detailed logs break down with graph_engine and iteration node](https://github.com/langgenius/dify/issues/8693)" <sup>[[1]](https://github.com/langgenius/dify/issues/6906)</sup>. The log message "Stopped by user" indicates that the application is being stopped manually or by some external trigger. This message is not related to timeout settings in your `docker-compose.yaml` or environment variables. Given the provided `docker-compose.yaml`, the `restart: always` policy is set for all services, which means the services should automatically restart unless explicitly stopped. Here are a few potential reasons for this issue: 1. **Manual Intervention**: Someone might be manually stopping the containers using commands like `docker stop`. 2. **External Scripts or Tools**: There might be external scripts or tools that are stopping the containers. 3. **Resource Constraints**: If the host machine is running out of resources (CPU, memory), Docker might stop the containers. To further diagnose the issue, you can: - Check the Docker logs for more details using `docker logs <container_id>`. - Ensure no external scripts or tools are stopping the containers. - Monitor the resource usage on the host machine. If none of these apply, you might need to look into Docker's event logs to see what is triggering the stop event <sup>[[2]](https://github.com/langgenius/dify/blob/main/docker/docker-compose.yaml)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
Author
Owner

@massif-01 commented on GitHub (Oct 8, 2024):

I had the same problem

@massif-01 commented on GitHub (Oct 8, 2024): I had the same problem
Author
Owner

@crazywoola commented on GitHub (Oct 9, 2024):

Can you guys provide a minimal DSL to reproduce this issue?

@crazywoola commented on GitHub (Oct 9, 2024): Can you guys provide a minimal DSL to reproduce this issue?
Author
Owner

@yuncengshangdepingyuan commented on GitHub (Oct 10, 2024):

屏幕截图 2024-10-10 172939 屏幕截图 2024-10-10 173033 There seems to be a 20 minute\1200s run limit, what should I do with it?
@yuncengshangdepingyuan commented on GitHub (Oct 10, 2024): <img width="638" alt="屏幕截图 2024-10-10 172939" src="https://github.com/user-attachments/assets/0d5dc5d8-0067-4897-9f06-1a9c9f932413"> <img width="335" alt="屏幕截图 2024-10-10 173033" src="https://github.com/user-attachments/assets/dcf1ae92-c6ff-4837-9264-8ad1ddd26b14"> There seems to be a 20 minute\1200s run limit, what should I do with it?
Author
Owner

@massif-01 commented on GitHub (Oct 10, 2024):

屏幕截图 2024-10-10 172939 屏幕截图 2024-10-10 173033 There seems to be a 20 minute\1200s run limit, what should I do with it?

I've solved this problem by add "APP_MAX_EXECUTION_TIME: ${APP_MAX_EXECUTION_TIME:-12000}" in docker-compose.yaml

https://github.com/massif-01/dify/blob/main/docker/docker-compose.yaml

@massif-01 commented on GitHub (Oct 10, 2024): > <img alt="屏幕截图 2024-10-10 172939" width="638" src="https://private-user-images.githubusercontent.com/141716071/375315206-0d5dc5d8-0067-4897-9f06-1a9c9f932413.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjg1NjQwMTEsIm5iZiI6MTcyODU2MzcxMSwicGF0aCI6Ii8xNDE3MTYwNzEvMzc1MzE1MjA2LTBkNWRjNWQ4LTAwNjctNDg5Ny05ZjA2LTFhOWM5ZjkzMjQxMy5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQxMDEwJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MTAxMFQxMjM1MTFaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT00MTM1MjUwNWE2ZTQyODJkMGI3Y2YzMzNlZjY1NzllZGZjMmMzNjk1NDcwODM2YzE2MDJlZDViMDQzYTVjYzA3JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.BthmAV1MncuJczQhTeJy7o_1KPtDv086MS60Fk-D_0s"> <img alt="屏幕截图 2024-10-10 173033" width="335" src="https://private-user-images.githubusercontent.com/141716071/375315276-dcf1ae92-c6ff-4837-9264-8ad1ddd26b14.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjg1NjQwMTEsIm5iZiI6MTcyODU2MzcxMSwicGF0aCI6Ii8xNDE3MTYwNzEvMzc1MzE1Mjc2LWRjZjFhZTkyLWM2ZmYtNDgzNy05MjY0LThhZDFkZGQyNmIxNC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQxMDEwJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MTAxMFQxMjM1MTFaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hODQ0MWViNWJjMWYxZTI4NTE4NzFmMzMxZjgxODdlZjQ4ZDE4YTFhNGY0ZDcxMzE4ZmYyZDkyMzE5MTNiNGMyJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.dX0LLLtN2d_bkfIap8nl0GU8MdGl4AlMVFwn3zMyDEE"> There seems to be a 20 minute\1200s run limit, what should I do with it? I've solved this problem by add "APP_MAX_EXECUTION_TIME: ${APP_MAX_EXECUTION_TIME:-12000}" in docker-compose.yaml https://github.com/massif-01/dify/blob/main/docker/docker-compose.yaml
Author
Owner

@yuncengshangdepingyuan commented on GitHub (Oct 10, 2024):

屏幕截图 2024-10-11 100125 thank you,and may be I can change this one ?
@yuncengshangdepingyuan commented on GitHub (Oct 10, 2024): > <img width="666" alt="屏幕截图 2024-10-11 100125" src="https://github.com/user-attachments/assets/74054dea-ed41-42f4-83cd-f2fb4ef47cb5"> thank you,and may be I can change this one ?
Author
Owner

@massif-01 commented on GitHub (Oct 11, 2024):

屏幕截图 2024-10-11 100125 thank you,and may be I can change this one ?

i have also changed this

@massif-01 commented on GitHub (Oct 11, 2024): > > > > <img alt="屏幕截图 2024-10-11 100125" width="666" src="https://private-user-images.githubusercontent.com/141716071/375600925-74054dea-ed41-42f4-83cd-f2fb4ef47cb5.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mjg2Mjk3MjgsIm5iZiI6MTcyODYyOTQyOCwicGF0aCI6Ii8xNDE3MTYwNzEvMzc1NjAwOTI1LTc0MDU0ZGVhLWVkNDEtNDJmNC04M2NkLWYyZmI0ZWY0N2NiNS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQxMDExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MTAxMVQwNjUwMjhaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1lZWI2ZDI3MzNjYjRjY2MyYzk4MThkOWMzNTYxZWE4YjNhODIzM2ZmNDBjMTJhYTUzYTkwNmI5MGZiNmQ2OTdhJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.2v5OvFBh3lLwTx6GjO5i_6KwXvDAIZPZiDyVdzEKsp4"> thank you,and may be I can change this one ? i have also changed this
Author
Owner

@yuncengshangdepingyuan commented on GitHub (Oct 22, 2024):

It's useless.I found that it has been written here:
1
Modify or add to these parameters.
1
It's ok now for me.

@yuncengshangdepingyuan commented on GitHub (Oct 22, 2024): It's useless.I found that it has been written here: <img width="421" alt="1" src="https://github.com/user-attachments/assets/04df7536-a53e-4f41-9127-932b1d9cdce8"> Modify or add to these parameters. <img width="434" alt="1" src="https://github.com/user-attachments/assets/9fbb0b1f-b0f8-4596-bc0a-27818fb9b9df"> It's ok now for me.
Author
Owner

@detongz commented on GitHub (Dec 11, 2024):

After changing .env config, 'Stopped by user' still exists and stops my workflow.
image
image

@detongz commented on GitHub (Dec 11, 2024): After changing .env config, 'Stopped by user' still exists and stops my workflow. ![image](https://github.com/user-attachments/assets/8794af38-f104-4d0b-9dce-1736f61c4811) ![image](https://github.com/user-attachments/assets/669371df-ca86-4dbe-9353-edb3d8044fb5)
Author
Owner

@yuncengshangdepingyuan commented on GitHub (Dec 11, 2024):

Ensure that there is no work_flow_max_Execution_time=1200 elsewhere; Ensure that the container is restarted. If it doesn't work, there's nothing I can do.

@yuncengshangdepingyuan commented on GitHub (Dec 11, 2024): Ensure that there is no work_flow_max_Execution_time=1200 elsewhere; Ensure that the container is restarted. If it doesn't work, there's nothing I can do.
Author
Owner

@RandalTeng commented on GitHub (Sep 5, 2025):

Found solution: you should recreate you container after change .env file. Like this:

cd /path/to/dify/docker
vi .env
{change the (APP|WORKFLOW)_MAX_EXECUTION_TIME to as bigger enough you wished.}

And then, run command blow:

docker compose up -d --force-recreate api worker worker_beat nginx

OR you have specific project name:

docker compose [-p dify] up -d --force-recreate api worker worker_beat nginx

Wait for seconds, run you workflow or chat apps.

@RandalTeng commented on GitHub (Sep 5, 2025): Found solution: you should **recreate** you container after change .env file. Like this: ``` shell cd /path/to/dify/docker vi .env {change the (APP|WORKFLOW)_MAX_EXECUTION_TIME to as bigger enough you wished.} ``` And then, run command blow: > docker compose up -d --force-recreate api worker worker_beat nginx OR you have specific project name: > docker compose [-p dify] up -d --force-recreate api worker worker_beat nginx Wait for seconds, run you workflow or chat apps.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#5848