Update app.py
Browse files
app.py
CHANGED
|
@@ -1,29 +1,23 @@
|
|
| 1 |
#!/usr/bin/env python3
|
| 2 |
-
import
|
|
|
|
|
|
|
| 3 |
|
| 4 |
-
print("===
|
| 5 |
-
print(f"Python
|
| 6 |
-
print(f"
|
| 7 |
-
print(f"Files in current dir: {os.listdir('.')}", flush=True)
|
| 8 |
|
| 9 |
-
|
|
|
|
| 10 |
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
import traceback
|
| 18 |
-
traceback.print_exc()
|
| 19 |
-
sys.exit(1)
|
| 20 |
|
| 21 |
if __name__ == "__main__":
|
| 22 |
-
print("===
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
except Exception as e:
|
| 26 |
-
print(f"=== main() FAILED: {e} ===", flush=True)
|
| 27 |
-
import traceback
|
| 28 |
-
traceback.print_exc()
|
| 29 |
-
sys.exit(1)
|
|
|
|
| 1 |
#!/usr/bin/env python3
|
| 2 |
+
import gradio as gr
|
| 3 |
+
import sys
|
| 4 |
+
import os
|
| 5 |
|
| 6 |
+
print("=== MINIMAL TEST APP STARTING ===", flush=True)
|
| 7 |
+
print(f"Python: {sys.version}", flush=True)
|
| 8 |
+
print(f"Working dir: {os.getcwd()}", flush=True)
|
|
|
|
| 9 |
|
| 10 |
+
def test_function(text):
|
| 11 |
+
return f"Minimal app working! Input: {text}"
|
| 12 |
|
| 13 |
+
demo = gr.Interface(
|
| 14 |
+
fn=test_function,
|
| 15 |
+
inputs="text",
|
| 16 |
+
outputs="text",
|
| 17 |
+
title="BackgroundFX Pro - Minimal Test Mode"
|
| 18 |
+
)
|
|
|
|
|
|
|
|
|
|
| 19 |
|
| 20 |
if __name__ == "__main__":
|
| 21 |
+
print("=== LAUNCHING MINIMAL GRADIO ===", flush=True)
|
| 22 |
+
demo.launch(server_name="0.0.0.0", server_port=7860)
|
| 23 |
+
print("=== LAUNCH COMPLETED ===", flush=True)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|