From 826c0066476271204fd755d8566751f05b99c5ac Mon Sep 17 00:00:00 2001 From: Jackson Maxfield Brown Date: Tue, 8 Mar 2022 13:29:54 -0800 Subject: [PATCH] bugfix/move-yt-dlp-import-to-within-youtube-copy-func (#171) --- cdp_backend/utils/file_utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cdp_backend/utils/file_utils.py b/cdp_backend/utils/file_utils.py index 1f106380..d9e7053c 100644 --- a/cdp_backend/utils/file_utils.py +++ b/cdp_backend/utils/file_utils.py @@ -11,7 +11,6 @@ import aiohttp import fsspec from fsspec.core import url_to_fs -from yt_dlp import YoutubeDL ############################################################################### @@ -154,6 +153,8 @@ def youtube_copy(uri: str, dst: Path, overwrite: bool = False) -> str: dst: str The location of the downloaded file. """ + from yt_dlp import YoutubeDL + # dst = Path(str(dst) + ".mp4") dst = dst.with_suffix(".mp4")