Try to make missing pidfile and logfile parent dir
authorJeremy Stanley <fungi@yuggoth.org>
Sat, 27 Oct 2018 20:52:04 +0000 (20:52 +0000)
committerJeremy Stanley <fungi@yuggoth.org>
Sat, 27 Oct 2018 20:52:04 +0000 (20:52 +0000)
commit491c1c73689b9e2c7c59442a051240b9330e6b82
tree23fd68bcdd353d3f5d77dae275a52da3014dd5d6
parent1976da0d1777c1b7fcdc01f36b2abdf80a7d3b93
Try to make missing pidfile and logfile parent dir

Rather than assume the path to a specified pidfile or logfile
already exists, try to make it before opening the file for writing.
This solves an issue with `tox -e debug` raising FileNotFoundError
when trying to open the logfile. Remove the mkdir() call in the
selftest setup so that this gets exercised properly.
mudpy/misc.py
mudpy/tests/selftest.py