change "except" to "except Exception" to avoid ignoring ctrl-C