Flowise
Flowise copied to clipboard
[bug]It doesn't work when I add " const fs = require('fs');" to my custom tool
It doesn't work when I add the following to my custom tool: const fs = require('fs'); const path = require('path'); why?
Can't custom tools introduce packages about files and paths? So how to operate local files?
its not allowed by default, because then it exposes huge risk for others to gain access to your file system. However, you can still import it via TOOL_FUNCTION_BUILTIN_DEP
env variable - https://docs.flowiseai.com/configuration/environment-variables#built-in-and-external-dependencies
Flowise support different environment variables to configure your instance. You can specify the following variables in the .env file inside packages/server folder I did not find the above folder, mine is a windows system "C:\Users\msrobot\AppData\Roaming\npm\node_modules\flowise\node_modules\flowise-ui.env" I only found this file, but adding the environment variable had no effect on the task.
I did not install it with docker. Please help me point out the location of the .env file. I have been looking for it for a long time but could not find it. Thank you.
@musuiot you have to create a new file .env
file at C:\Users\msrobot\AppData\Roaming\npm\node_modules\flowise
folder