little fixes

pull/280/head
iaacornus 3 years ago
parent 0e70327bd3
commit 08f7132f3c
No known key found for this signature in database
GPG Key ID: 281739AE7252598C

@ -1,8 +1,6 @@
import re import re
import os import os
from random import randrange from random import randrange
from pathlib import Path
from turtle import back
from yt_dlp import YoutubeDL from yt_dlp import YoutubeDL
from moviepy.video.io.ffmpeg_tools import ffmpeg_extract_subclip from moviepy.video.io.ffmpeg_tools import ffmpeg_extract_subclip
@ -30,7 +28,7 @@ def download_background(background):
"merge_output_format": "mp4", "merge_output_format": "mp4",
} }
background_check = Path("assets/mp4/background.mp4").is_file() background_check = os.path.isfile("assets/mp4/background.mp4")
if background is not None or not background_check: if background is not None or not background_check:
if background_check and background is not None: if background_check and background is not None:
print_substep( print_substep(

@ -22,7 +22,7 @@ W, H = 1080, 1920
def make_final_video(number_of_clips, file_name): def make_final_video(number_of_clips, file_name):
# Calls opacity from the .env # Calls opacity from the .env
load_dotenv() load_dotenv()
opacity = os.getenv('OPACITY') opacity = os.getenv("OPACITY")
print_step("Creating the final video...") print_step("Creating the final video...")
@ -44,7 +44,6 @@ def make_final_video(number_of_clips, file_name):
TypeError TypeError
): ):
print(f"Please ensure that OPACITY is set between 0 and 1 in your .env file") print(f"Please ensure that OPACITY is set between 0 and 1 in your .env file")
configured = False
# Gather all audio clips # Gather all audio clips
audio_clips = [] audio_clips = []

Loading…
Cancel
Save