Spaces:
Sleeping
Sleeping
fix return
Browse files
app.py
CHANGED
|
@@ -211,9 +211,12 @@ def import_and_run_function(script_path, function_name="eval"):
|
|
| 211 |
function_to_run = getattr(module, function_name)
|
| 212 |
result = function_to_run()
|
| 213 |
print(f"TYPE: {type(result), {type(result[0])}}")
|
| 214 |
-
|
|
|
|
|
|
|
| 215 |
else:
|
| 216 |
-
|
|
|
|
| 217 |
|
| 218 |
|
| 219 |
|
|
|
|
| 211 |
function_to_run = getattr(module, function_name)
|
| 212 |
result = function_to_run()
|
| 213 |
print(f"TYPE: {type(result), {type(result[0])}}")
|
| 214 |
+
|
| 215 |
+
print(f"Function '{function_name}' executed successfully. Output: {result}")
|
| 216 |
+
return result
|
| 217 |
else:
|
| 218 |
+
print(f"Error: Function '{function_name}' not found in {script_path}")
|
| 219 |
+
return None
|
| 220 |
|
| 221 |
|
| 222 |
|