Wrap all callbacks such that they yield the event loop