Fix several minor (but annoying) bugs with path checking
This revision fixes a couple of minor path validation and creation bugs which only
show up when you don't have the deployment repo completely configured.
- use dirname instead of basename with mkdir_p ;)
- check for filename==None in check_file_exists (improves error message when called incorrectly)
- automatically create the scap/log directory if it doesn't exist
after applying this patch, new deployment repo setup should be less frustrating, as in the following scenario:
- run deploy on a fresh scap setup (e.g. freshly created deploy repo without all the expected pieces)
- begin to work your way through adding all the expected pieces
- along the way to deployment bliss, notice that you experience fewer annoying errors with little more than a stack trace.
Reviewers: demon, Release-Engineering-Team, thcipriani
Reviewed By: Release-Engineering-Team, thcipriani
Subscribers: dduvall, jenkins
Differential Revision: https://phabricator.wikimedia.org/D101