You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Without git installed, running go-blueprint create --name app --framework echo --driver postgres --git skip causes panic. CreateMainFile() at cmd/createate.go:271 returns an error and goes into error handling, but at line 273 ReleaseTerminal() panics (is it bad that p.cancelReader is nil?), and even after recovering, it still panics. The same thing seems to be happening again even after further recovering.
I could not reproduce the same bug on my Ubuntu 22.04 (x86-64). I am not very familiar with go, so please feel free to point out if I am saying something strange.🙇
Operating System
Amazon Linux 2
Architecture Version (x86, x64, arm, etc)
x86_64
Steps to reproduce
With git not installed, run go-blueprint create --name app --framework echo --driver postgres --git skip
Relevant log output
The program encountered an unexpected issue and had to exit. The error was: runtime error: invalid memory address or nil pointer dereference
If you continue to experience this issue, please post a message on our GitHub page or join our Discord server for support.
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=0x18 pc=0x57fa0c]
goroutine 1 [running]:
github.com/charmbracelet/bubbletea.(*Program).ReleaseTerminal(0xc0000fe480)
/home/ec2-user/go/pkg/mod/github.com/charmbracelet/[email protected]/tea.go:611 +0x2c
github.com/melkeydev/go-blueprint/cmd.init.func1.2()
/home/ec2-user/go/pkg/mod/github.com/melkeydev/[email protected]/cmd/create.go:264 +0xbd
panic({0x638960?, 0x8af260?})
/usr/local/go/src/runtime/panic.go:785 +0x132
github.com/charmbracelet/bubbletea.(*Program).ReleaseTerminal(0xc0000fe480)
/home/ec2-user/go/pkg/mod/github.com/charmbracelet/[email protected]/tea.go:611 +0x2c
github.com/melkeydev/go-blueprint/cmd.init.func1(0x8b71c0, {0x8dcbc0?, 0x0?, 0x0?})
/home/ec2-user/go/pkg/mod/github.com/melkeydev/[email protected]/cmd/create.go:273 +0x1f0b
github.com/spf13/cobra.(*Command).execute(0x8b71c0, {0x8dcbc0, 0x0, 0x0})
/home/ec2-user/go/pkg/mod/github.com/spf13/[email protected]/command.go:944 +0x847
github.com/spf13/cobra.(*Command).ExecuteC(0x8b74a0)
/home/ec2-user/go/pkg/mod/github.com/spf13/[email protected]/command.go:1068 +0x3a5
github.com/spf13/cobra.(*Command).Execute(...)
/home/ec2-user/go/pkg/mod/github.com/spf13/[email protected]/command.go:992
github.com/melkeydev/go-blueprint/cmd.Execute()
/home/ec2-user/go/pkg/mod/github.com/melkeydev/[email protected]/cmd/root.go:20 +0x1a
main.main()
/home/ec2-user/go/pkg/mod/github.com/melkeydev/[email protected]/main.go:6 +0xf
The text was updated successfully, but these errors were encountered:
This shouldn't happen, especially since the skip flag is specifically designed to handle cases without Git.
We're not properly handling the Git-not-installed scenario even when the user explicitly requests to skip Git functionality and ReleaseTerminal() is being called when the Program isn't properly initialized.
What is the problem?
Without git installed, running
go-blueprint create --name app --framework echo --driver postgres --git skip
causes panic. CreateMainFile() at cmd/createate.go:271 returns an error and goes into error handling, but at line 273 ReleaseTerminal() panics (is it bad that p.cancelReader is nil?), and even after recovering, it still panics. The same thing seems to be happening again even after further recovering.I could not reproduce the same bug on my Ubuntu 22.04 (x86-64). I am not very familiar with go, so please feel free to point out if I am saying something strange.🙇
Operating System
Amazon Linux 2
Architecture Version (x86, x64, arm, etc)
x86_64
Steps to reproduce
go-blueprint create --name app --framework echo --driver postgres --git skip
Relevant log output
The text was updated successfully, but these errors were encountered: