fix: remove redundant "/" in Gradio mount path to prevent double slash in URL - #296
fix: remove redundant "/" in Gradio mount path to prevent double slash in URL#296clifford402 wants to merge 1 commit into
Conversation
fix: remove the wrong path "/"
|
It works! I did it online with the following command in the console: sed -i 's|app = gr.mount_gradio_app(app, demo, path="/")|app = gr.mount_gradio_app(app, demo, path="")|' gradio_app.py Make sure you run it in the right folder containing the gradio_app.py file: root@9127afe2bc15:/app/Hunyuan3D-2# ls -al |
Description
This PR fixes the issue where accessing the app resulted in URLs like (double slash), which caused front-end errors.
The fix is to set the
pathargument ingr.mount_gradio_appto an empty string ("") instead of"/".This ensures all URLs are generated correctly with a single slash.
Code Diff
After merging this PR, the app will no longer generate URLs with double slashes, and the front-end will work as expected.