Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image component omit comma on the file name #10318

Open
1 task done
CNgg opened this issue Jan 9, 2025 · 0 comments
Open
1 task done

Image component omit comma on the file name #10318

CNgg opened this issue Jan 9, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@CNgg
Copy link

CNgg commented Jan 9, 2025

Describe the bug

while set Image component as type='filepath', and drag image to the component, found the temp filename have omitted the comma on the original file name. It's may be a issue while the file name carried some information, for example coordinates.

Have you searched existing issues? 🔎

  • I have searched and found no existing issues

Reproduction

def show_image(image_path):
    print(image_path)

# Gradio 界面
with gr.Blocks() as demo:
    img = gr.Image(type="filepath", sources=["upload"], interactive=True)
    btn = gr.Button("显示图片")
    btn.click(show_image, inputs=img, outputs=None)
demo.launch()

Screenshot

filename example
QQ20250109-100029

Logs

No response

System Info

Gradio Environment Information:
------------------------------
Operating System: Windows
gradio version: 5.11.0
gradio_client version: 1.5.3

------------------------------------------------
gradio dependencies in your environment:

aiofiles: 23.2.1
anyio: 4.8.0
audioop-lts is not installed.
fastapi: 0.115.6
ffmpy: 0.5.0
gradio-client==1.5.3 is not installed.
httpx: 0.28.1
huggingface-hub: 0.27.1
jinja2: 3.1.5
markupsafe: 2.1.5
numpy: 2.2.1
orjson: 3.10.14
packaging: 24.2
pandas: 2.2.3
pillow: 11.1.0
pydantic: 2.10.4
pydub: 0.25.1
python-multipart: 0.0.20
pyyaml: 6.0.2
ruff: 0.8.6
safehttpx: 0.1.6
semantic-version: 2.10.0
starlette: 0.41.3
tomlkit: 0.13.2
typer: 0.15.1
typing-extensions: 4.12.2
urllib3: 2.3.0
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: 0.28.1
huggingface-hub: 0.27.1
packaging: 24.2
typing-extensions: 4.12.2
websockets: 14.1

Severity

I can work around it

@CNgg CNgg added the bug Something isn't working label Jan 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant