Fix for error logging and catching, support for twnel specific keys