catch any exception while waiting for server to start

in html tests.

requests 2.4 changed the exception type for a failed connection, causing recent test failures.

ping @takluyver who pinged me about the failures on the test bots.