sub-http-file-02-get-file-and-upload 的問題

68 views
Skip to first unread message

Dennis Lin

unread,
Dec 18, 2024, 9:28:09 AM12/18/24
to NYCU NASA 課程討論區
助教好,我的 db 和 get ip 有過但 file upload 會出現以圖片中錯誤,而我的 backend server 出現 INFO:     192.168.90.1:28391 - "POST /upload HTTP/1.0" 422 Unprocessable Entity
而且可以印出
Uploaded file name: test.txt
Uploaded file size: 33 bytes
我使用 fastapi 

截圖 2024-12-18 晚上10.24.31.png

管培勛

unread,
Dec 18, 2024, 8:14:47 PM12/18/24
to NYCU NASA 課程討論區
同學好:

因為可能有 http 和 https 兩種得分方式,所以我會先測 http 沒成功再測 https。有一個 422 是正常的。

你的問題並不是那個 422,而是你有一個 typo,請仔細看一下你貼上來的這張圖。

Best Regrads,
資工系計中助教
管培勛 phkoan
Computer Center, Department of Computer Science,
National Yang Ming Chiao Tung University, Taiwan.
1001 University Road, Hsinchu, Taiwan 300, ROC.
lintinwe...@gmail.com 在 2024年12月18日 星期三晚上10:28:09 [UTC+8] 的信中寫道:
Reply all
Reply to author
Forward
0 new messages