More robust external interface

In particular; kill the thread on exception