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

cobra panics when running "pod inspect" without parameter #2681

Closed
tobwen opened this issue Mar 17, 2019 · 1 comment
Closed

cobra panics when running "pod inspect" without parameter #2681

tobwen opened this issue Mar 17, 2019 · 1 comment
Labels
kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@tobwen
Copy link
Contributor

tobwen commented Mar 17, 2019

Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)

/kind bug

Description
cobra panics when running "pod inspect" without parameter

Steps to reproduce the issue:

  1. /home/podman/podman/usr/local/bin/podman pod inspect
  2. /home/podman/podman/usr/local/bin/podman pod inspect busybox

Describe the results you received:
Step 1 breaks with this error:

podman pod inspect
panic: runtime error: index out of range

goroutine 1 [running]:
main.podInspectCmd(0x2a3d900, 0x0, 0x0)
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/cmd/podman/pod_inspect.go:59 +0x407
main.glob..func74(0x289ee60, 0x2a624c8, 0x0, 0x0, 0x0, 0x0)
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/cmd/podman/pod_inspect.go:26 +0x7f
github.com/containers/libpod/vendor/github.com/spf13/cobra.(*Command).execute(0x289ee60, 0xc00003a0b0, 0x0, 0x0, 0x289ee60, 0xc00003a0b0)
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/vendor/github.com/spf13/cobra/command.go:762 +0x473
github.com/containers/libpod/vendor/github.com/spf13/cobra.(*Command).ExecuteC(0x289e4e0, 0x28, 0x2a64060, 0xc000752000)
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/vendor/github.com/spf13/cobra/command.go:852 +0x2fd
github.com/containers/libpod/vendor/github.com/spf13/cobra.(*Command).Execute(0x289e4e0, 0xc0006cc370, 0xc0000ac058)
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/vendor/github.com/spf13/cobra/command.go:800 +0x2b
main.main()
        /home/podman/go/src/github.com/containers/libpod/_output/src/github.com/containers/libpod/cmd/podman/main.go:231 +0x3c

Describe the results you expected:
The output of step 2

@openshift-ci-robot openshift-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Mar 17, 2019
giuseppe added a commit to giuseppe/libpod that referenced this issue Mar 17, 2019
Closes: containers#2681

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@giuseppe
Copy link
Member

PR here: #2684

giuseppe added a commit to giuseppe/libpod that referenced this issue Mar 18, 2019
Closes: containers#2681

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
muayyad-alsadi pushed a commit to muayyad-alsadi/libpod that referenced this issue Apr 21, 2019
Closes: containers#2681

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 24, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug Categorizes issue or PR as related to a bug. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

No branches or pull requests

3 participants