fix pumps when used with slow streams

This is a very rough solution for #4.

Obviously `time.sleep()` is not good, but I wanted to post this to see how we can improve it.

I added a bunch of debugging to `dockerpty` and ran it on jenkins. I noticed that `select()` would only return the streams that were ready (in some cases just stdin), so when flush of stdin returned None, it would exit without every printing anything (because stdout was never flushed)

I think the change to the select/flush block is correct, but I'm not sure of the correct way to deal with waiting for the streams to be available.

Without the sleep this does nothing because the streams just aren't available yet and it just exits the while loop immediately.