Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1116)

Side by Side Diff: dm/appengine/deps/util.go

Issue 2963503003: [errors] Greatly simplify common/errors package. (Closed)
Patch Set: fix nits Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « dm/appengine/deps/service.go ('k') | dm/appengine/distributor/notify_execution.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The LUCI Authors. All rights reserved. 1 // Copyright 2017 The LUCI Authors. All rights reserved.
2 // Use of this source code is governed under the Apache License, Version 2.0 2 // Use of this source code is governed under the Apache License, Version 2.0
3 // that can be found in the LICENSE file. 3 // that can be found in the LICENSE file.
4 4
5 package deps 5 package deps
6 6
7 import ( 7 import (
8 "github.com/luci/luci-go/common/errors" 8 "github.com/luci/luci-go/common/errors"
9 "github.com/luci/luci-go/grpc/grpcutil" 9 "github.com/luci/luci-go/grpc/grpcutil"
10 "google.golang.org/grpc/codes" 10 "google.golang.org/grpc/codes"
11 ) 11 )
12 12
13 func grpcAnnotate(err error, code codes.Code) *errors.Annotator { 13 func grpcAnnotate(err error, code codes.Code, reason string, args ...interface{} ) *errors.Annotator {
14 » return errors.Annotate(err).Tag(grpcutil.Tag.With(code)) 14 » return errors.Annotate(err, reason, args...).Tag(grpcutil.Tag.With(code) )
15 } 15 }
OLDNEW
« no previous file with comments | « dm/appengine/deps/service.go ('k') | dm/appengine/distributor/notify_execution.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698