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
for image in images:
# Extract the original filename from the temporary path
original_filename = os.path.basename(image) # Gradio stores the original name here
raise AssertionError(f"original_filename: {original_filename}")
`
If preserving the filenames is not supported yet, does anyone know any alternative way to achieve this? Thanks a lot!
Have you searched existing issues? 🔎
I have searched and found no existing issues
Reproduction
please refer to previous section for minimal code to reproduce
Screenshot
No response
Logs
System Info
Gradio Environment Information:
------------------------------
Operating System: Linux
gradio version: 5.15.0
gradio_client version: 1.7.0
------------------------------------------------
gradio dependencies in your environment:
aiofiles: 23.2.1
anyio: 3.7.1
audioop-lts is not installed.
fastapi: 0.115.7
ffmpy: 0.5.0
gradio-client==1.7.0 is not installed.
httpx: 1.0.0b0
huggingface-hub: 0.28.1
jinja2: 3.1.5
markupsafe: 3.0.2
numpy: 2.2.2
orjson: 3.10.15
packaging: 24.1
pandas: 2.2.3
pillow: 11.1.0
pydantic: 2.10.6
pydub: 0.25.1
python-multipart: 0.0.20
pyyaml: 6.0.2
ruff: 0.9.6
safehttpx: 0.1.6
semantic-version: 2.10.0
starlette: 0.45.3
tomlkit: 0.13.2
typer: 0.15.1
typing-extensions: 4.12.2
urllib3: 2.2.3
uvicorn: 0.34.0
authlib; extra == 'oauth' is not installed.
itsdangerous; extra == 'oauth' is not installed.
gradio_client dependencies in your environment:
fsspec: 2024.12.0
httpx: 1.0.0b0
huggingface-hub: 0.28.1
packaging: 24.1
typing-extensions: 4.12.2
websockets: 14.2
Severity
Blocking usage of gradio
The text was updated successfully, but these errors were encountered:
Describe the bug
In frontend js, we uploaded the image files by:
`
const processedFiles = files.map(f =>
new File([f.file], f.file.name, { type: f.file.type }) // Ensure filename is included
);
`
and in backend, app.py, we try to get the original filenames but just have all filenames as blob:
`
def save_uploaded_images(images):
temp_dir = tempfile.mkdtemp(dir="/tmp/gradio") # Ensuring proper storage
saved_paths = []
seen_filenames = []
`
If preserving the filenames is not supported yet, does anyone know any alternative way to achieve this? Thanks a lot!
Have you searched existing issues? 🔎
Reproduction
please refer to previous section for minimal code to reproduce
Screenshot
No response
Logs
System Info
Severity
Blocking usage of gradio
The text was updated successfully, but these errors were encountered: