Completed main for tc-diag

  -- Added pretty printing for error messages