fix: guard makedirs in ExportWorker.run inside try/except
This commit is contained in:
@@ -220,6 +220,7 @@ class ExportWorker(QThread):
|
|||||||
self._image_sequence = image_sequence
|
self._image_sequence = image_sequence
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
|
try:
|
||||||
if self._image_sequence:
|
if self._image_sequence:
|
||||||
os.makedirs(self._output, exist_ok=True)
|
os.makedirs(self._output, exist_ok=True)
|
||||||
cmd = build_ffmpeg_command(
|
cmd = build_ffmpeg_command(
|
||||||
@@ -229,7 +230,6 @@ class ExportWorker(QThread):
|
|||||||
crop_center=self._crop_center,
|
crop_center=self._crop_center,
|
||||||
image_sequence=self._image_sequence,
|
image_sequence=self._image_sequence,
|
||||||
)
|
)
|
||||||
try:
|
|
||||||
result = subprocess.run(cmd, capture_output=True, text=True, timeout=120)
|
result = subprocess.run(cmd, capture_output=True, text=True, timeout=120)
|
||||||
if result.returncode == 0:
|
if result.returncode == 0:
|
||||||
self.finished.emit(self._output)
|
self.finished.emit(self._output)
|
||||||
|
|||||||
Reference in New Issue
Block a user