File validation failed when using custon file types in input #13337

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

Originally created by @qwfy326 on GitHub (Apr 25, 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.3.0

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

  1. create a work flow with a start node and a end node.

  2. set the llm enable memory.
    Image

  3. custom the file type.
    Image

  4. run the work flow and choose a file, then start the flow.

✔️ Expected Behavior

run is ok if upload the file and remember the query together.

Actual Behavior

Image

thanks for @crazywoola help.

Originally created by @qwfy326 on GitHub (Apr 25, 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.3.0 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce 1. create a work flow with a start node and a end node. 3. set the llm enable memory. ![Image](https://github.com/user-attachments/assets/97a15f2b-68c4-44a9-b3df-5bf11741328b) 4. custom the file type. ![Image](https://github.com/user-attachments/assets/a1016c15-b1f2-40f9-b4e8-9d034bfcd966) 5. run the work flow and choose a file, then start the flow. ### ✔️ Expected Behavior run is ok if upload the file and remember the query together. ### ❌ Actual Behavior ![Image](https://github.com/user-attachments/assets/7a934d47-eb95-463c-ac39-6c525825d1e2) thanks for @crazywoola help.
yindo closed this issue 2026-02-21 19:11:43 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Apr 25, 2025):

File validation failures when using custom file types in Dify version 1.3.0 are often due to not specifying the file type correctly in the input parameters. You need to ensure that the file type is set to 'custom' in the Workflow API's /workflows/run endpoint. Here's an example of how to specify it:

{
  'inputs': {
    'doc': {
      'type': 'custom',
      'transfer_method': 'remote_url',
      'url': 'your-file-url'
    }
  }
}

Using any other type, such as 'document', will result in a validation error [1].

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] commented on GitHub (Apr 25, 2025): <!-- Answer --> File validation failures when using custom file types in Dify version 1.3.0 are often due to not specifying the file type correctly in the input parameters. You need to ensure that the file type is set to `'custom'` in the Workflow API's `/workflows/run` endpoint. Here's an example of how to specify it: ```json { 'inputs': { 'doc': { 'type': 'custom', 'transfer_method': 'remote_url', 'url': 'your-file-url' } } } ``` Using any other type, such as 'document', will result in a validation error <sup>[[1]](https://github.com/langgenius/dify/issues/11671)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/2dfa67c4-22df-468e-8f00-0cd3d9edef6c?feedback_type=other)</sup>
Author
Owner

@crazywoola commented on GitHub (Apr 25, 2025):

The first time it reads the contents of sys.files, but the second time it doesn't, because this is removed from the context, so I let you put it in the paint variable.

To make it clear, you can orchestrate workflow like this.

Image
@crazywoola commented on GitHub (Apr 25, 2025): The first time it reads the contents of sys.files, but the second time it doesn't, because this is removed from the context, so I let you put it in the paint variable. To make it clear, you can orchestrate workflow like this. - https://docs.dify.ai/guides/workflow/node/doc-extractor - https://docs.dify.ai/workshop/intermediate/article-reader <img width="1605" alt="Image" src="https://github.com/user-attachments/assets/451b7d44-db41-4f86-b075-123aa3284517" />
Author
Owner

@qwfy326 commented on GitHub (Apr 25, 2025):

The first time it reads the contents of sys.files, but the second time it doesn't, because this is removed from the context, so I let you put it in the paint variable.

To make it clear, you can orchestrate workflow like this.

Image

Image

I don't want to use the one . Only want to use the two. Any way else?

@qwfy326 commented on GitHub (Apr 25, 2025): > The first time it reads the contents of sys.files, but the second time it doesn't, because this is removed from the context, so I let you put it in the paint variable. > > To make it clear, you can orchestrate workflow like this. > > * https://docs.dify.ai/guides/workflow/node/doc-extractor > * https://docs.dify.ai/workshop/intermediate/article-reader > > <img alt="Image" width="1605" src="https://private-user-images.githubusercontent.com/100913391/437305257-451b7d44-db41-4f86-b075-123aa3284517.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NDU1NjA4MDAsIm5iZiI6MTc0NTU2MDUwMCwicGF0aCI6Ii8xMDA5MTMzOTEvNDM3MzA1MjU3LTQ1MWI3ZDQ0LWRiNDEtNGY4Ni1iMDc1LTEyM2FhMzI4NDUxNy5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwNDI1JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDQyNVQwNTU1MDBaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hYmFmMThmZjQ1ZGM1ZTFkNzdkN2EzY2M5OWY5YTlmMWY5NTU1NTg0NDMxYzYwYmM1NzMzMTNiZjIxOTU3MmRkJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.3ClTg5RkBCaekgMUMH6pu_Pgcs3P9o4pvl-fpNXeT-0"> ![Image](https://github.com/user-attachments/assets/0bb74224-39fc-484f-8e9f-6cccce91df89) I don't want to use the one . Only want to use the two. Any way else?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#13337