Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix panic in Velero analyzer when there's no Velero deployment found #1497

Merged
merged 2 commits into from
Mar 5, 2024

Conversation

nvanthao
Copy link
Member

@nvanthao nvanthao commented Mar 4, 2024

Description, Motivation and Context

#1366 introduces a panic when there's no Velero Deployment found.

panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x58 pc=0x2f71931]

goroutine 1 [running]:
go.opentelemetry.io/otel/sdk/trace.(*recordingSpan).End.func1()
	/home/runner/go/pkg/mod/go.opentelemetry.io/otel/[email protected]/trace/span.go:405 +0x25
go.opentelemetry.io/otel/sdk/trace.(*recordingSpan).End(0xc000ee8480, {0x0, 0x0, 0x106a36b?})
	/home/runner/go/pkg/mod/go.opentelemetry.io/otel/[email protected]/trace/span.go:443 +0xa3b
panic({0x3301020?, 0x55ce110?})
	/opt/hostedtoolcache/go/1.21.6/x64/src/runtime/panic.go:914 +0x21f
github.com/replicatedhq/troubleshoot/pkg/analyze.getVeleroVersion({0x5660860, 0x0, 0x0}, 0xc000f29b60)
	/home/runner/work/troubleshoot/troubleshoot/pkg/analyze/velero.go:669 +0x1f1

Checklist

  • New and existing tests pass locally with introduced changes.
  • Tests for the changes have been added (for bug fixes / features)
  • The commit message(s) are informative and highlight any breaking changes
  • Any documentation required has been added/updated. For changes to https://troubleshoot.sh/ create a PR here

Does this PR introduce a breaking change?

  • Yes
  • No

@nvanthao nvanthao requested a review from a team as a code owner March 4, 2024 23:21
@nvanthao nvanthao added bug::regression type::bug Something isn't working labels Mar 4, 2024
@nvanthao nvanthao requested a review from danj-replicated March 5, 2024 10:54
@nvanthao nvanthao merged commit 553d709 into main Mar 5, 2024
25 checks passed
@nvanthao nvanthao deleted the gerard/b-panic-velero-analyzer branch March 5, 2024 10:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug::regression type::bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants