more msftidy checks

More msftidy checks.

See
#4369
#4362
#3853

There are some fp like
`def prev_error_log_path; datastore['ERROR_LOG']; end `

but i think those should be changed to multiline for codestyle (#4372)
best to make that non-capturing to stick with the style used here as well as for good practice.  But, if you keep it capturing, you could use ```Regexp.last_match(1)``` in the ```info``` call to make it more informative.