You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using from fastapi_admin.file_upload import FileUpload and it returns the save path (endpoint to fetch the file) using prefix and filename, it joins the path using os.path.join, which is OS-dependent. This causes the filename to contain \ separated path on Windows.
Example:
upload_face=FileUpload(
uploads_dir="./static/uploads",
prefix="/faces", # StaticFiles is mounted herefilename_generator=random_filename, # Ignore this
)
It just causes the backslash escape character sequence to mess up path when fetching images sometimes.
The text was updated successfully, but these errors were encountered:
Title says it all.
When using
from fastapi_admin.file_upload import FileUpload
and it returns the save path (endpoint to fetch the file) using prefix and filename, it joins the path usingos.path.join
, which is OS-dependent. This causes the filename to contain\
separated path on Windows.Example:
It just causes the backslash escape character sequence to mess up path when fetching images sometimes.
The text was updated successfully, but these errors were encountered: