mirror of
https://github.com/labring/FastGPT.git
synced 2026-05-07 01:02:55 +08:00
3df8908851
* style: re-component Editor * style: re-component Editor * feat: sandbox file preview support with binary detection and mime type handling * feat: preview support for markdown, svg, and html files in sandbox editor * feat(sandbox): support multimedia preview and source/preview toggle in editor * fix: XSS SVG rendering with MyPhotoView * refactor: blob URL lifecycle management, improve filename encoding in downloads * feat: implement S3-based HTML preview for sandbox editor and add PDF support to binary file detection * refactor: improve sandbox editor stability by adding file size validation * feat: introduce fileService to encapsulate sandbox file operations and add unit tests * refactor: secure HTML sandbox preview by fetching content from server and injecting CSP meta tags * refactor: replace unified file operation API with dedicated endpoints for list, read, write, and download operations * chore: remove packageManager field from package.json * fix: sandbox file read error message * refactor: improve sandbox editor UI styling, type safety, and CSP security policy * feat: HTML preview link API and standardize sandbox request/response types * fix: improve log view layout responsiveness by adding overflow handling and flex constraints * perf: fix review --------- Co-authored-by: archer <545436317@qq.com>
目录说明
该目录为 FastGPT 主项目。
-
app fastgpt 核心应用。
-
sandbox 沙盒项目,用于运行工作流里的代码执行 (需求python环境为python:3.11,额外安装的包请于requirements.txt填写,在运行时会读取安装。
-
注意个别安装的包可能需要额外安装库(如pandas需要安装libffi))。
-
新加入python的包遇见超时或者权限拦截的问题(确定不是自己的语法问题),请进入docker容器内部执行以下指令:
docker exec -it 《替换成容器名》 /bin/bash chmod -x testSystemCall.sh bash ./testSystemCall.sh然后将新的数组替换或追加到src下sandbox的constants.py中的SYSTEM_CALLS数组即可
-