Fix docker settings
This commit is contained in:
parent
26181d083f
commit
c2b56cc85d
2 changed files with 6 additions and 1 deletions
|
@ -10,3 +10,4 @@ TRANSLOGGER_OPTS = {
|
|||
"set_logger_level": logging.INFO,
|
||||
"setup_console_handler": True,
|
||||
}
|
||||
FFMPEG_OPTIONS = ["-loglevel", "warning"]
|
||||
|
|
|
@ -3,6 +3,7 @@ import logging
|
|||
import tempfile
|
||||
import os
|
||||
from datetime import datetime, timedelta
|
||||
import shutil
|
||||
from subprocess import Popen
|
||||
from time import sleep
|
||||
from typing import Callable, Optional
|
||||
|
@ -186,7 +187,10 @@ async def create_mp3(
|
|||
if not validator(start, end, tmp_file.name):
|
||||
os.unlink(tmp_file.name)
|
||||
return False
|
||||
os.rename(tmp_file.name, outfile)
|
||||
try:
|
||||
os.rename(tmp_file.name, outfile)
|
||||
except OSError:
|
||||
shutil.move(tmp_file.name, outfile)
|
||||
return True
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue