Skip to content

Commit e8852bf

Browse files
committed
Update golangci-lint to 1.47.3
1 parent bcde6f0 commit e8852bf

File tree

3 files changed

+5
-9
lines changed

3 files changed

+5
-9
lines changed

.github/workflows/golangci-lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,5 @@ jobs:
1919
- name: golangci-lint
2020
uses: golangci/golangci-lint-action@v2
2121
with:
22-
version: v1.45.2
22+
version: v1.47.3
2323
working-directory: ${{matrix.working-directory}}

pkg/client/apiutil/dynamicrestmapper.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ func (drm *dynamicRESTMapper) checkAndReload(needsReloadErr error, checkNeedsRel
167167
// NB(directxman12): `Is` and `As` have a confusing relationship --
168168
// `Is` is like `== or does this implement .Is`, whereas `As` says
169169
// `can I type-assert into`
170-
needsReload := errors.As(err, &needsReloadErr)
170+
needsReload := errors.As(err, needsReloadErr)
171171
if !needsReload {
172172
return err
173173
}
@@ -178,7 +178,7 @@ func (drm *dynamicRESTMapper) checkAndReload(needsReloadErr error, checkNeedsRel
178178

179179
// ... and double-check that we didn't reload in the meantime
180180
err = checkNeedsReload()
181-
needsReload = errors.As(err, &needsReloadErr)
181+
needsReload = errors.As(err, needsReloadErr)
182182
if !needsReload {
183183
return err
184184
}

pkg/internal/testing/process/process.go

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -184,16 +184,12 @@ func (ps *State) Start(stdout, stderr io.Writer) (err error) {
184184
ps.ready = true
185185
return nil
186186
case <-ps.waitDone:
187-
if pollerStopCh != nil {
188-
close(pollerStopCh)
189-
}
187+
close(pollerStopCh)
190188
return fmt.Errorf("timeout waiting for process %s to start successfully "+
191189
"(it may have failed to start, or stopped unexpectedly before becoming ready)",
192190
path.Base(ps.Path))
193191
case <-timedOut:
194-
if pollerStopCh != nil {
195-
close(pollerStopCh)
196-
}
192+
close(pollerStopCh)
197193
if ps.Cmd != nil {
198194
// intentionally ignore this -- we might've crashed, failed to start, etc
199195
ps.Cmd.Process.Signal(syscall.SIGTERM) //nolint:errcheck

0 commit comments

Comments
 (0)