Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -100,17 +100,17 @@ with gr.Blocks() as demo:
|
|
| 100 |
label="دانلود ویدئو",
|
| 101 |
visible=False,
|
| 102 |
)
|
| 103 |
-
hidden_file = gr.File(visible=False)
|
| 104 |
-
|
| 105 |
# First chain: Process data and update hidden file
|
| 106 |
submit_btn.click(
|
| 107 |
fn=main,
|
| 108 |
inputs=[video_input, params],
|
| 109 |
-
outputs=[progress_report,
|
| 110 |
concurrency_limit=4,
|
| 111 |
)
|
| 112 |
|
| 113 |
-
# Second chain: Update download button when file is ready
|
| 114 |
def toggle_download(file_path):
|
| 115 |
if file_path:
|
| 116 |
return gr.DownloadButton(visible=True, value=file_path)
|
|
@@ -122,6 +122,6 @@ with gr.Blocks() as demo:
|
|
| 122 |
outputs=download_btn,
|
| 123 |
queue=False
|
| 124 |
)
|
| 125 |
-
|
| 126 |
demo.launch(debug=True)
|
| 127 |
|
|
|
|
| 100 |
label="دانلود ویدئو",
|
| 101 |
visible=False,
|
| 102 |
)
|
| 103 |
+
#hidden_file = gr.File(visible=False)
|
| 104 |
+
file_pa = gr.Text()
|
| 105 |
# First chain: Process data and update hidden file
|
| 106 |
submit_btn.click(
|
| 107 |
fn=main,
|
| 108 |
inputs=[video_input, params],
|
| 109 |
+
outputs=[progress_report, file_pa],
|
| 110 |
concurrency_limit=4,
|
| 111 |
)
|
| 112 |
|
| 113 |
+
""" # Second chain: Update download button when file is ready
|
| 114 |
def toggle_download(file_path):
|
| 115 |
if file_path:
|
| 116 |
return gr.DownloadButton(visible=True, value=file_path)
|
|
|
|
| 122 |
outputs=download_btn,
|
| 123 |
queue=False
|
| 124 |
)
|
| 125 |
+
"""
|
| 126 |
demo.launch(debug=True)
|
| 127 |
|