voc / intro-outro-generator

Frab-Based Into- and Outro-Generator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

setting cwd for inkscape subprocess uses wrong directory

dvzrv opened this issue · comments

While trying to do the work on #39 I tried to use the default inkscape-based compilation of the videos.
Unfortunately the subprocess call in renderlib.py sets cwd to task.workdir:

errorReturn = subprocess.check_output(cmd, shell=True, universal_newlines=True, stderr=subprocess.STDOUT, cwd=task.workdir)

This leads to inkscape not being able to open the generated SVG files, because the path is concatenated to something like /absolute/path/to/<project_dir>/artwork/<project_dir>/artwork/.frames/.
Moreover, this does not lead to make.py (or rather renderlib.py) exiting with a non-zero exit code. The script tries to render all frames, but ultimately fails to finish any of them and is therefore also unable to render the video (the process should exit early).

For me it worked to just remove the cwd setting.