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)
commit41a4d11fc1fa4d9aa801c879c7464bd0de6defcc
tree23fd68bcdd353d3f5d77dae275a52da3014dd5d6
parent4d1be9934c46fb605b93e4dd9556263ae4e7363e
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