Message 284857 - Python tracker
I've added a patch that should handle these errors (including the SysLogHandlerTest, which wasn't reported, but I think the same logic applies).
To simulate failure during setup, uncomment one or more of the lines which says
# raise ValueError('dummy error raised')