Skip to content

Commit

Permalink
generate and upload thumbs to voctoweb regardless of whether event wa…
Browse files Browse the repository at this point in the history
…s created or uploaded
  • Loading branch information
Kunsi committed Nov 23, 2024
1 parent f4e2563 commit aecbdfb
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions voctopublish/voctopublish.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,11 +310,6 @@ def _publish_to_voctoweb(self):
if r.status_code in [200, 201]:
self.logger.info("new event created")
# generate thumbnails and a visual timeline for video releases (will not overwrite existing files)
if self.ticket.mime_type.startswith("video"):
vw.generate_thumbs()
vw.upload_thumbs()
vw.generate_timelens()
vw.upload_timelens()
self.logger.debug("response: " + str(r.json()))
try:
# TODO only set recording id when new recording was created, and not when it was only updated
Expand All @@ -337,6 +332,12 @@ def _publish_to_voctoweb(self):
+ " - "
+ str(r.text)
)
# generate thumbnails and timelens
if self.ticket.mime_type.startswith("video"):
vw.generate_thumbs()
vw.upload_thumbs()
vw.generate_timelens()
vw.upload_timelens()

# in case of a multi language release we create here the single language files
if len(self.ticket.languages) > 1:
Expand Down

0 comments on commit aecbdfb

Please sign in to comment.