Log exceptions properly, and produce a 500 page
Log the failing request
Merge pull request #1 from paul-lshift/logging-fixes

Logging fixes