PluginInvokeError No such file or directory #14583

Closed
opened 2026-02-21 19:17:54 -05:00 by yindo · 3 comments
Owner

Originally created by @nicho2 on GitHub (Jun 12, 2025).

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

1.4.2

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Hello,

I just updated form 1.4.0 to version 1.4.2.
And the two plugins, azure_openai and azure_ai_studio, no longer work.
However, the openai and ollama plugins work fine.

azure_openai plugin version: 0.0.16
azure_ai_studio plugin version: 0.0.3

To reproduce, just use a model from a chatbot

✔️ Expected Behavior

have no error

Actual Behavior

For azure_openai, I get the following error:

[azure_openai] Error: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"}

in log api container :

[on_llm_new_chunk]2025-06-12 09:18:43.490 ERROR [Thread-1244 (worker_with_context)] [app_generator.py:244] - Error when generating

Traceback (most recent call last):

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator

    for chunk in result:

                 ^^^^^^

  File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm

    yield from response

  File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream

    self._handle_plugin_daemon_error(error.error_type, error.message)

  File "/app/api/core/plugin/impl/base.py", line 245, in _handle_plugin_daemon_error

    raise PluginInvokeError(description=message)

core.plugin.impl.exc.PluginInvokeError: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"}

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker

    runner.run(

  File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run

    self._handle_invoke_result(

  File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result

    self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent)

  File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream

    for result in invoke_result:

                  ^^^^^^^^^^^^^

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator

    raise self._transform_invoke_error(e)

core.model_runtime.errors.invoke.InvokeError: [azure_openai] Error: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"}

2025-06-12 09:18:43.494 INFO [Thread-1243 (process_request_thread)] [_internal.py:97] - 172.23.0.11 - - [12/Jun/2025 09:18:43] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 -

and for azure_ai_studio:

[azure_ai_studio] Error: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"}

[on_llm_new_chunk]2025-06-12 09:16:49.504 ERROR [Thread-1239 (worker_with_context)] [app_generator.py:244] - Error when generating

Traceback (most recent call last):

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator

    for chunk in result:

                 ^^^^^^

  File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm

    yield from response

  File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream

    self._handle_plugin_daemon_error(error.error_type, error.message)

  File "/app/api/core/plugin/impl/base.py", line 245, in _handle_plugin_daemon_error

    raise PluginInvokeError(description=message)

core.plugin.impl.exc.PluginInvokeError: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"}

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker

    runner.run(

  File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run

    self._handle_invoke_result(

  File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result

    self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent)

  File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream

    for result in invoke_result:

                  ^^^^^^^^^^^^^

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator

    raise self._transform_invoke_error(e)

core.model_runtime.errors.invoke.InvokeError: [azure_ai_studio] Error: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"}

2025-06-12 09:16:49.509 INFO [Thread-1238 (process_request_thread)] [_internal.py:97] - 172.23.0.11 - - [12/Jun/2025 09:16:49] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 -
Originally created by @nicho2 on GitHub (Jun 12, 2025). ### 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 1.4.2 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce Hello, I just updated form 1.4.0 to version 1.4.2. And the two plugins, azure_openai and azure_ai_studio, no longer work. However, the openai and ollama plugins work fine. azure_openai plugin version: 0.0.16 azure_ai_studio plugin version: 0.0.3 To reproduce, just use a model from a chatbot ### ✔️ Expected Behavior have no error ### ❌ Actual Behavior For azure_openai, I get the following error: [azure_openai] Error: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"} in log api container : [on_llm_new_chunk]2025-06-12 09:18:43.490 ERROR [Thread-1244 (worker_with_context)] [app_generator.py:244] - Error when generating Traceback (most recent call last): File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator for chunk in result: ^^^^^^ File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm yield from response File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream self._handle_plugin_daemon_error(error.error_type, error.message) File "/app/api/core/plugin/impl/base.py", line 245, in _handle_plugin_daemon_error raise PluginInvokeError(description=message) core.plugin.impl.exc.PluginInvokeError: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"} During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker runner.run( File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run self._handle_invoke_result( File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent) File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream for result in invoke_result: ^^^^^^^^^^^^^ File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator raise self._transform_invoke_error(e) core.model_runtime.errors.invoke.InvokeError: [azure_openai] Error: PluginInvokeError: {"args":{"description":"[models] Error: [Errno 2] No such file or directory"},"error_type":"InvokeError","message":"[models] Error: [Errno 2] No such file or directory"} 2025-06-12 09:18:43.494 INFO [Thread-1243 (process_request_thread)] [_internal.py:97] - 172.23.0.11 - - [12/Jun/2025 09:18:43] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 - and for azure_ai_studio: [azure_ai_studio] Error: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"} [on_llm_new_chunk]2025-06-12 09:16:49.504 ERROR [Thread-1239 (worker_with_context)] [app_generator.py:244] - Error when generating Traceback (most recent call last): File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator for chunk in result: ^^^^^^ File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm yield from response File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream self._handle_plugin_daemon_error(error.error_type, error.message) File "/app/api/core/plugin/impl/base.py", line 245, in _handle_plugin_daemon_error raise PluginInvokeError(description=message) core.plugin.impl.exc.PluginInvokeError: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"} During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker runner.run( File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run self._handle_invoke_result( File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent) File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream for result in invoke_result: ^^^^^^^^^^^^^ File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator raise self._transform_invoke_error(e) core.model_runtime.errors.invoke.InvokeError: [azure_ai_studio] Error: PluginInvokeError: {"args":{"description":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"},"error_type":"InvokeError","message":"[models] Error: [models] Error: Could not find a suitable TLS CA certificate bundle, invalid path: /usr/local/share/ca-certificates/dify.crt"} 2025-06-12 09:16:49.509 INFO [Thread-1238 (process_request_thread)] [_internal.py:97] - 172.23.0.11 - - [12/Jun/2025 09:16:49] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 -
yindo added the 🐞 bug label 2026-02-21 19:17:54 -05:00
yindo closed this issue 2026-02-21 19:17:54 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Jun 12, 2025):

For the "No such file or directory" error with the azure_openai plugin, this is often caused by a missing file in the Docker environment—commonly a PM2 PID file or a plugin artifact. The recommended fix is to stop and remove all existing Docker containers and images, then pull and start fresh containers. This has resolved similar issues for others after upgrades or migrations [source].

For the azure_ai_studio plugin's TLS CA certificate error, the message indicates that the file /usr/local/share/ca-certificates/dify.crt is missing inside the container. This usually means the certificate was not mounted or created as expected. Double-check your Docker volumes and ensure that the certificate exists at that path inside the relevant container. If you don't require a custom CA, you may need to update your plugin or environment configuration to not reference this file.

No breaking changes between 1.4.0 and 1.4.2 were found that directly affect these plugins' file paths or TLS handling. If you migrated or changed your Docker setup, re-check your plugin installations and any custom file mounts. If you removed plugins before the upgrade, reinstalling them after the upgrade has also resolved similar issues for others [source].

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Join Discord Share on X

@dosubot[bot] commented on GitHub (Jun 12, 2025): <!-- Answer --> For the "No such file or directory" error with the azure_openai plugin, this is often caused by a missing file in the Docker environment—commonly a PM2 PID file or a plugin artifact. The recommended fix is to stop and remove all existing Docker containers and images, then pull and start fresh containers. This has resolved similar issues for others after upgrades or migrations [[source](https://github.com/langgenius/dify/issues/19079)]. For the azure_ai_studio plugin's TLS CA certificate error, the message indicates that the file `/usr/local/share/ca-certificates/dify.crt` is missing inside the container. This usually means the certificate was not mounted or created as expected. Double-check your Docker volumes and ensure that the certificate exists at that path inside the relevant container. If you don't require a custom CA, you may need to update your plugin or environment configuration to not reference this file. No breaking changes between 1.4.0 and 1.4.2 were found that directly affect these plugins' file paths or TLS handling. If you migrated or changed your Docker setup, re-check your plugin installations and any custom file mounts. If you removed plugins before the upgrade, reinstalling them after the upgrade has also resolved similar issues for others [[source](https://github.com/langgenius/dify/issues/19481)]. <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/8a4c03c5-cddd-4d4b-bec6-76248c77c314?feedback_type=other)</sup>&nbsp;&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify/issues/20960)
Author
Owner

@nicho2 commented on GitHub (Jun 12, 2025):

Ok,

I restarted the containers and now I have another type of error for azure_openai

[models] Connection Error, Connection error

[on_llm_new_chunk]2025-06-12 12:24:48.280 ERROR [Thread-97 (worker_with_context)] [app_generator.py:244] - Error when generating

Traceback (most recent call last):

  File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker

    runner.run(

  File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run

    self._handle_invoke_result(

  File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result

    self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent)

  File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream

    for result in invoke_result:

                  ^^^^^^^^^^^^^

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator

    raise self._transform_invoke_error(e)

  File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator

    for chunk in result:

                 ^^^^^^

  File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm

    yield from response

  File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream

    self._handle_plugin_daemon_error(error.error_type, error.message)

  File "/app/api/core/plugin/impl/base.py", line 237, in _handle_plugin_daemon_error

    raise InvokeConnectionError(description=args.get("description"))

core.model_runtime.errors.invoke.InvokeConnectionError: [models] Connection Error, Connection error.

2025-06-12 12:24:48.293 INFO [Thread-96 (process_request_thread)] [_internal.py:97] - 172.22.0.11 - - [12/Jun/2025 12:24:48] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 -

This seems to be a connection issue between dify and azure

For the azure_ai_studio plugin, the error is staying the same

@nicho2 commented on GitHub (Jun 12, 2025): Ok, I restarted the containers and now I have another type of error for azure_openai [models] Connection Error, Connection error [on_llm_new_chunk]2025-06-12 12:24:48.280 ERROR [Thread-97 (worker_with_context)] [app_generator.py:244] - Error when generating Traceback (most recent call last): File "/app/api/core/app/apps/chat/app_generator.py", line 227, in _generate_worker runner.run( File "/app/api/core/app/apps/chat/app_runner.py", line 217, in run self._handle_invoke_result( File "/app/api/core/app/apps/base_app_runner.py", line 279, in _handle_invoke_result self._handle_invoke_result_stream(invoke_result=invoke_result, queue_manager=queue_manager, agent=agent) File "/app/api/core/app/apps/base_app_runner.py", line 314, in _handle_invoke_result_stream for result in invoke_result: ^^^^^^^^^^^^^ File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 304, in _invoke_result_generator raise self._transform_invoke_error(e) File "/app/api/core/model_runtime/model_providers/__base/large_language_model.py", line 275, in _invoke_result_generator for chunk in result: ^^^^^^ File "/app/api/core/plugin/impl/model.py", line 189, in invoke_llm yield from response File "/app/api/core/plugin/impl/base.py", line 211, in _request_with_plugin_daemon_response_stream self._handle_plugin_daemon_error(error.error_type, error.message) File "/app/api/core/plugin/impl/base.py", line 237, in _handle_plugin_daemon_error raise InvokeConnectionError(description=args.get("description")) core.model_runtime.errors.invoke.InvokeConnectionError: [models] Connection Error, Connection error. 2025-06-12 12:24:48.293 INFO [Thread-96 (process_request_thread)] [_internal.py:97] - 172.22.0.11 - - [12/Jun/2025 12:24:48] "POST /console/api/apps/82593598-82d7-4003-b3cd-6a8385a6b649/chat-messages HTTP/1.1" 200 - This seems to be a connection issue between dify and azure For the azure_ai_studio plugin, the error is staying the same
Author
Owner

@nicho2 commented on GitHub (Jun 12, 2025):

I found it, it was me who wanted to add my self-signed certificate and who deactivated the others (I think)

SSL_CERT_FILE: /usr/local/share/ca-certificates/dify.crt
REQUESTS_CA_BUNDLE: /usr/local/share/ca-certificates/dify.crt

@nicho2 commented on GitHub (Jun 12, 2025): I found it, it was me who wanted to add my self-signed certificate and who deactivated the others (I think) SSL_CERT_FILE: /usr/local/share/ca-certificates/dify.crt REQUESTS_CA_BUNDLE: /usr/local/share/ca-certificates/dify.crt
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#14583