Read/write file disk - no output

Hi

I’m trying to build a simple workflow in n8n installed locally with npm:

  1. upload pdf, docx or text file file to a specific folder
  2. get file name and path
  3. grab the file
  4. depending on the file type, route it to extract from pdf, text or docx
  5. extract the text from the document

the flow appears to work as intended until Read/write file disk.

In this example I have placed a .txt file in the folder and the flow grabs the path and file name. then Read/write file disk node correctly identifies the path of the file, but there is no output and the workflow stops.

Please advise. I’ve been searching far and wide and tried different things to no avail.

The workflow so far is more or less identical to the start of this template, but not working.

please help me :slight_smile:

Information on your n8n setup

  • n8n version: 1.80.5
  • Database (default: SQLite): Default
  • n8n EXECUTIONS_PROCESS setting (default: own, main): Default
  • Running n8n via (Docker, npm, n8n cloud, desktop app): npm
  • Operating system: Windows 10

Hey @revola
The info for the path parameter says you have to use forward slashes for paths even on windows:

I think that’s why your node is not getting the file.

Thanks a lot!

I hadn’t noticed the forward slash text. had to tinker a bit with “edit fields”, but now it works perfectly!

Guys,
I have similar problem. Fwd slashes are ok for me, but output data is weird.
My read node is looking for json file from the local folder. It is returning data block with metadata (filename, size, MIME, etc), but after that I cannot do anything with that block. No matter what I connect afterwards, no info from json file is passed on.
Do I understand purpose of read node incorrectly? Does read node has to return contents of the file(-s)? If not, what do i need to connect next to parse data? Thanks

I have the same issue… a very basic operation of Read/write files from Disk is returning a null - no matter what I try and which file type I try… did you find how to solve for it?

Is this an issue with trial period? by any chance?

yes. you need trigger node for read/write to work. Its not obvious and intuitive.

Add trigger “when clicked test workflow” before read node.

n8n is open source, there is no trial.

nice, going to play around with this more too :slight_smile:

I met the same issue. finally I figured it out. The reason is I run n8n from docker container. As a result, the container cannot access any folder or file outside of the container. The solution is to use another -v parameter to mount the local folder into the n8n container and the issue was fixed.