From e729bb3ce7a3d866f715068fb2c73f049259243c Mon Sep 17 00:00:00 2001 From: sunbeam Date: Fri, 17 Jan 2025 14:08:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.py | 2 +- note.txt | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index b1127d4..61397d1 100755 --- a/main.py +++ b/main.py @@ -37,7 +37,7 @@ async def create_upload_file(file: UploadFile = File(...)): copyfileobj(file.file, buffer) # 执行外部程序 - command = [ + command = [ # coderdbc -dbc ./DMK-RP-77A.dbc -out ./gen -drvname CANmatrix -nodeutils -rw -driverdir -gendate os.path.join(folder_path, "coderdbc"), "-dbc", file_location, "-out", os.path.join(folder_path, "gen"), diff --git a/note.txt b/note.txt index fd87c1c..ce7ebd9 100755 --- a/note.txt +++ b/note.txt @@ -1,5 +1,8 @@ 1.进入虚拟环境 source .venv/bin/activate + +安装fastapi + 2.运行fastapi uvicorn main:app --reload --host 0.0.0.0 --port 8000