Syntax & logging cleanup
Bump release to 4.0.7