Skip to content

Commit

Permalink
Add panopto status message on upload error
Browse files Browse the repository at this point in the history
  • Loading branch information
nikolas committed Feb 5, 2025
1 parent aef7d06 commit 9c44cf5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion wardenclyffe/panopto/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,13 @@ def verify_upload_to_panopto(operation):

(state, panopto_id) = upload_status.check()
if state != 4: # Panopto "Complete" State
raise Exception('Panopto is not yet finished.')
status_msg = None
if state in upload_status.UPLOAD_STATES:
status_msg = upload_status.UPLOAD_STATES[state]

raise Exception(
'Panopto is not yet finished. Status: {}'.format(status_msg)
)

url = settings.PANOPTO_LINK_URL.format(panopto_id)

Expand Down

0 comments on commit 9c44cf5

Please sign in to comment.