Bug Report: update command panic #2457
-
aqua info$ aqua info
{
"version": "2.17.1",
"commit_hash": "6102460adf2c26d21bd964577097e66d73131930",
"os": "linux",
"arch": "amd64",
"pwd": "/(USER)/workspace",
"root_dir": "/(USER)/.local/share/aquaproj-aqua",
"env": {},
"config_files": [
{
"path": "/(USER)/workspace/aqua.yaml"
}
]
} $ aqua version
aqua version 2.17.1 (6102460adf2c26d21bd964577097e66d73131930) OS (Windows, Linux, macOS, etc): OverviewIf aqua updates a package that is not managed by aqua, command How to reproduce$ docker run --name=aqua_tst --rm -it archlinux:latest
# in docker
$ pacman -Sy
# install gh first
$ pacman -S github-cli
$ gh version
gh version 2.38.0 (2023-11-01)
# install aqua
$ pacman -S curl
$ mkdir ~/workspace
cd ~/workspace
export PATH="${AQUA_ROOT_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/aquaproj-aqua}/bin:$PATH"
curl -sSfL -O https://raw.githubusercontent.com/aquaproj/aqua-installer/v2.2.0/aqua-installer
echo "d13118c3172d90ffa6be205344b93e8621de9bf47c852d80da188ffa6985c276 aqua-installer" | sha256sum -c
chmod +x aqua-installer
./aqua-installer
$ aqua version
aqua version 2.17.1 (6102460adf2c26d21bd964577097e66d73131930)
$ aqua init
# update gh by aqua
$ aqua up gh
# panic
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0xb00d04]
goroutine 1 [running]:
github.com/aquaproj/aqua/v2/pkg/controller/update.(*Controller).getPackageNewVersion(0xc00041a1b0?, {0xe934a0?, 0xc000123b40?}, 0x97?, 0xc00042a420?, 0x7ffe1eb49e8e?, 0x2?)
/home/runner/work/aqua/aqua/pkg/controller/update/package.go:82 +0x224
github.com/aquaproj/aqua/v2/pkg/controller/update.(*Controller).updateCommand(0xc0004380a0, {0xe934a0, 0xc000123b40}, 0xc0004014a0?, 0xc00042a420)
/home/runner/work/aqua/aqua/pkg/controller/update/update.go:40 +0x178
github.com/aquaproj/aqua/v2/pkg/controller/update.(*Controller).Update(0xc0004380a0, {0xe934a0, 0xc000123b40}, 0x15265a0?, 0xc00042a420)
/home/runner/work/aqua/aqua/pkg/controller/update/update.go:15 +0x33
github.com/aquaproj/aqua/v2/pkg/cli.(*Runner).updateAction(0xc00007aeb0, 0xc000412400)
/home/runner/work/aqua/aqua/pkg/cli/update.go:136 +0x1da
github.com/urfave/cli/v2.(*Command).Run(0xc000409e40, 0xc000412400, {0xc000416a20, 0x2, 0x2})
/home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:274 +0x998
github.com/urfave/cli/v2.(*Command).Run(0xc00042a160, 0xc000412180, {0xc0000222a0, 0x3, 0x3})
/home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:267 +0xbe5
github.com/urfave/cli/v2.(*App).RunContext(0xc000404000, {0xe934a0?, 0xc000123b40}, {0xc0000222a0, 0x3, 0x3})
/home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/app.go:332 +0x5b7
github.com/aquaproj/aqua/v2/pkg/cli.(*Runner).Run(0xc00007aeb0, {0xe934a0, 0xc000123b40}, {0xc0000222a0, 0x3, 0x3})
/home/runner/work/aqua/aqua/pkg/cli/runner.go:185 +0x2a2c
main.core(0xc0003127e0, 0xc0000714e0)
/home/runner/work/aqua/aqua/cmd/aqua/main.go:56 +0x246
main.main()
/home/runner/work/aqua/aqua/cmd/aqua/main.go:30 +0x4c Debug output$ Expected behaviourexit with log instead of panic Actual behaviourpanic Important FactoidsNo response Reference |
Beta Was this translation helpful? Give feedback.
Answered by
suzuki-shunsuke
Nov 15, 2023
Replies: 1 comment 2 replies
-
Thank you for your report! |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The issue was resolved at v2.17.2 🎉
https://github.com/aquaproj/aqua/releases/tag/v2.17.2