Spaces:
Runtime error
Runtime error
ahmedJaafari
commited on
Commit
•
69e0e2c
1
Parent(s):
519c9c1
Update app.py
Browse files
app.py
CHANGED
@@ -57,8 +57,11 @@ def submit_video(video_url):
|
|
57 |
headers=headers,
|
58 |
data=json.dumps(payload))
|
59 |
|
60 |
-
|
61 |
-
|
|
|
|
|
|
|
62 |
def submit_job(video_url, channel_id) :
|
63 |
if video_url != "":
|
64 |
return submit_video(video_url)
|
|
|
57 |
headers=headers,
|
58 |
data=json.dumps(payload))
|
59 |
|
60 |
+
try:
|
61 |
+
return f"Task Successfully Submited. Task ID: {response.json()['task_id']}"
|
62 |
+
except:
|
63 |
+
return "Error"
|
64 |
+
|
65 |
def submit_job(video_url, channel_id) :
|
66 |
if video_url != "":
|
67 |
return submit_video(video_url)
|