remote_error_handler var is in main package