From c48e0dd815b361529ec6cbe3a751993710b921dc Mon Sep 17 00:00:00 2001 From: Clayton Coleman Date: Thu, 21 Mar 2019 22:54:06 -0400 Subject: [PATCH] Avoid using `%#v` for errors when %T is more informative `%#v` may have significant performance costs in frequently invoked code. Kubernetes-commit: 435db312e1773d3ad506604219b9b1d00176d6fc --- tools/cache/shared_informer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/cache/shared_informer.go b/tools/cache/shared_informer.go index b2f3dba0..9715d344 100644 --- a/tools/cache/shared_informer.go +++ b/tools/cache/shared_informer.go @@ -555,7 +555,7 @@ func (p *processorListener) run() { case deleteNotification: p.handler.OnDelete(notification.oldObj) default: - utilruntime.HandleError(fmt.Errorf("unrecognized notification: %#v", next)) + utilruntime.HandleError(fmt.Errorf("unrecognized notification: %T", next)) } } // the only way to get here is if the p.nextCh is empty and closed