From 0fd7e11f9fa1972934bdc9d195ff78bb7e4a7da4 Mon Sep 17 00:00:00 2001 From: Yin Jifeng Date: Sun, 3 Sep 2017 23:00:00 +0800 Subject: [PATCH] fix: retry after HasLatestLocally **success** --- internal/gps/source.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/gps/source.go b/internal/gps/source.go index 6d1fccbcb6..d13800f124 100644 --- a/internal/gps/source.go +++ b/internal/gps/source.go @@ -272,7 +272,7 @@ func (sg *sourceGateway) exportVersionTo(ctx context.Context, v Version, to stri // TODO(sdboyer) It'd be better if we could check the error to see if this // actually was the cause of the problem. if err != nil && sg.srcState&sourceHasLatestLocally == 0 { - if _, err = sg.require(ctx, sourceHasLatestLocally); err != nil { + if _, err = sg.require(ctx, sourceHasLatestLocally); err == nil { err = sg.suprvsr.do(ctx, sg.src.upstreamURL(), ctExportTree, func(ctx context.Context) error { return sg.src.exportRevisionTo(ctx, r, to) })