Skip to content

Commit

Permalink
fix: do not await non-async function
Browse files Browse the repository at this point in the history
  • Loading branch information
winstxnhdw committed Jul 3, 2024
1 parent 3bb72e6 commit 2b4d73f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion capgen/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ async def main():
options['device'] = 'cuda'
resolve_cuda_libraries()

if not (transcription := await Transcriber(**options).transcribe(args.file, args.caption)):
if not (transcription := Transcriber(**options).transcribe(args.file, args.caption)):
raise InvalidFormatError(f'Invalid format: {args.caption}!')

with open(args.output, 'w', encoding='utf-8') as file:
Expand Down

0 comments on commit 2b4d73f

Please sign in to comment.