Disabling shell in subprocess call requires arguments as list
atesca09 opened this issue · 3 comments
atesca09 commented
This commit 0fbd5ee broke the processing of fonts for me.
According to the python subprocess documentation, if parameters are to be passed to the executable they have to be passed as a list, otherwise if they are passed in the string they are interpreted to be the commant to be executed.
I think it should look like
import shlex
...
call(shlex.split('ttfautohint --symbol --fallback-script=latn --no-info "%(font)s.ttf" "%(font)s-hinted.ttf" && mv "%(font)s-hinted.ttf" "%(font)s.ttf"' % {'font': fontfile}))
...
call(shlex.split('python "%(path)s/../../bin/eotlitetool.py" "%(font)s.ttf" --output "%(font)s.eot"' % {'path': scriptPath, 'font': fontfile}))
L2jLiga commented
Hi there, would you like to send PR to fix the issue?
L2jLiga commented
Thanks! Released as v4.0.3