developer icon indicating copy to clipboard operation
developer copied to clipboard

Fix: File Permission Error

Open billysweird opened this issue 1 year ago • 0 comments

Updated to check if writing to file or directory, Saves time and don't have to write large complicated prompts, should normally sort itself out instead.

For example without this with a simple prompt it may try and write a single files code to a directory name, and get a Error 13: Permission error. Instead this will check if the file_path is a directory or a file first, it seems that the handler response is enough to trigger the AI to look inside the directory to write the multiple files it needs to, instead of treating a directory like a file and trying to save files or write files to it.

And also using os.path.join is standard for cross-platform forgot to add this point instead of manually setting it with directory + "/" + filename, Avoids uni-code conflicts.

Just ignore the gitignore and parameter settings, you can just accept the update to the file system.

billysweird avatar May 26 '23 05:05 billysweird