Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -58,7 +58,19 @@ def fetch_all_user_data():
|
|
| 58 |
return all_data
|
| 59 |
|
| 60 |
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 58 |
return all_data
|
| 59 |
|
| 60 |
|
| 61 |
+
import gradio as gr
|
| 62 |
+
|
| 63 |
+
def fetch_file():
|
| 64 |
+
return "all_users_data.json"
|
| 65 |
+
|
| 66 |
+
# Gradio Interface
|
| 67 |
+
interface = gr.Interface(
|
| 68 |
+
fn=fetch_file,
|
| 69 |
+
inputs=[],
|
| 70 |
+
outputs=gr.File(label="Download Fetched Data")
|
| 71 |
+
)
|
| 72 |
+
|
| 73 |
+
interface.launch()
|
| 74 |
+
|
| 75 |
+
fetch_all_user_data()
|
| 76 |
+
print("Data fetching complete. All data saved to 'all_users_data.json'.")
|