tern: report errors as metrics