Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
except:
print ("No categories found.")
if 'tags' in vid_meta: # some video services don't have tags
try:
if 'tags' in vid_meta is None:
tags_string += '%s;' % vid_meta['id']
tags_string += '%s;' % 'video'
else:
for tag in vid_meta['tags']:
tags_string += '%s;' % tag
except:
print ("Unable to process tags successfully.")
# license
licenseurl = TubeUp.determine_licenseurl(vid_meta)
# if there is no description don't upload the empty .description file
description_text = vid_meta.get('description', '')
description = ('{0} <br><br>Source: <a href="{1}">{2}</a>'
'<br>Uploader: <a href="{3}">{4}</a>').format(
description_text, videourl, videourl, uploader_url, uploader)
metadata = dict(
mediatype=('audio' if collection == 'opensource_audio'
else 'movies'),
creator=uploader,
collection=collection,
title=title,
description=description,
date=upload_date,