dify icon indicating copy to clipboard operation
dify copied to clipboard

Variable is unavailable in workflow.

Open tigflanker opened this issue 8 months ago • 1 comments

Self Checks

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

Dify version

1.3.0

Cloud or Self Hosted

Cloud

Steps to reproduce

Variable is unavailable in workflow, both in docker and cloud way. I have already set up a variable, but i can't assign new value.

cloud: Image

docker: Image

✔️ Expected Behavior

No response

❌ Actual Behavior

No response

tigflanker avatar Apr 26 '25 13:04 tigflanker

I found some similar discussions that might be relevant to your issue:

  1. After the workflow is compiled into the tool, the output variable cannot get the value, and it can be obtained normally in the tool - This discussion is still open and might provide insights into similar variable issues [1].

  2. There is no session variable in the workflow. When will this feature be available? - This is another open discussion that might be related to your problem [2].

Regarding your issue with variable assignment in Dify version 1.3.0, common causes of variable assignment failures include incorrect configuration of value assignments, unsupported operations for specific variable types, and invalid input values. Ensure that the values being assigned are correctly set in the workflow configuration and that the operations and input types are supported [3].

If you are encountering specific error messages, you might want to check the API container logs in your Docker environment for detailed error messages in JSON format, which can help troubleshoot the issue [4].

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

dosubot[bot] avatar Apr 26 '25 13:04 dosubot[bot]

what does that means no response? does your chatflow can not output anything when a variable is setted?

su37sm avatar Apr 26 '25 15:04 su37sm

I have a similar problem.you can take a look this. https://github.com/langgenius/dify/issues/18637

su37sm avatar Apr 26 '25 15:04 su37sm

if you have variable windows in the APP ,you must in the chatflow not workflow,I am sure you are using the chatflow.

su37sm avatar Apr 26 '25 15:04 su37sm

I am facing the same issue. Not able to set the variable in any block after defining it globally.

koushik16 avatar Apr 26 '25 17:04 koushik16

if you have variable windows in the APP ,you must in the chatflow not workflow,I am sure you are using the chatflow.

@su37sm No, in fact, I am using the workflow mode precisely. The reason is that my application scenario requires the use of a loop node within the workflow, and the criterion for determining whether to break the loop is to check if a certain variable meets the condition.

In Docker version 1.2.0 and the official documentation, it is indeed the case that variables are not available by default in workflows. I noticed that version 1.3.0 suddenly introduced them, but they cannot be assigned values.

tigflanker avatar Apr 27 '25 01:04 tigflanker

It's a frontend bug, and it has been fixed already.

fix: not render conversation var in prompt editor (https://github.com/langgenius/dify/pull/18728)

crazywoola avatar Apr 27 '25 01:04 crazywoola