Update main.py
Browse files199 unmodified lines20020120220320420520619 unmodified lines226227228229230231232199 unmodified linesasync def send_video_for_transcription(file_content: bytes, filename: str, content_type: str, hash_path: str):async with semaphore:try:logger.info(f"Background task: sending video {file.filename} for transcription")run_time = api.get_space_runtime(repo_id=repo_id)if run_time.stage != 'RUNNING':19 unmodified linesresponse = await client.post(transcribation_url, files=files, data=data, headers=headers)if response.status_code == 200:logger.info(f"Video successfully sent for transcription {file.filename}")else:logger.error(f"Error sending video for transcription: {response.text}")199 unmodified lines20020120220320420520619 unmodified lines226227228229230231232199 unmodified linesasync def send_video_for_transcription(file_content: bytes, filename: str, content_type: str, hash_path: str):async with semaphore:try:logger.info(f"Background task: sending video {filename} for transcription")run_time = api.get_space_runtime(repo_id=repo_id)if run_time.stage != 'RUNNING':19 unmodified linesresponse = await client.post(transcribation_url, files=files, data=data, headers=headers)if response.status_code == 200:logger.info(f"Video successfully sent for transcription {filename}")else:logger.error(f"Error sending video for transcription: {response.text}")
main.py+2-2