Closed rustyhu closed 2 weeks ago
samething happen while trying to enter directory with no permission.
Caught panic:
runtime error: makeslice: len out of range
Restoring terminal...
goroutine 1 [running]:
runtime/debug.Stack()
/home/guest/.local/src/go/src/runtime/debug/stack.go:24 +0x5e
runtime/debug.PrintStack()
/home/guest/.local/src/go/src/runtime/debug/stack.go:16 +0x13
github.com/charmbracelet/bubbletea.(*Program).Run.func1()
/home/guest/.go/pkg/mod/github.com/charmbracelet/bubbletea@v0.26.5/tea.go:479 +0x91
panic({0x5625c0?, 0x5cf7b0?})
/home/guest/.local/src/go/src/runtime/panic.go:770 +0x132
main.(*model).View(0xc00011d0e0)
/home/guest/.go/pkg/mod/github.com/antonmedv/walk@v1.9.0/main.go:486 +0x2b1
github.com/charmbracelet/bubbletea.(*Program).eventLoop(0xc000150200, {0x5d0998?, 0xc00011d0e0?}, 0xc00008e180)
/home/guest/.go/pkg/mod/github.com/charmbracelet/bubbletea@v0.26.5/tea.go:414 +0x707
github.com/charmbracelet/bubbletea.(*Program).Run(0xc000150200)
/home/guest/.go/pkg/mod/github.com/charmbracelet/bubbletea@v0.26.5/tea.go:550 +0xa0e
main.main()
/home/guest/.go/pkg/mod/github.com/antonmedv/walk@v1.9.0/main.go:132 +0x511
Got this one too when trying 'walk' the first time today.
Fixed.
Nonexist start path listing:
Empty directory previewing:
Both lead to invalid
rows
number returned from algorithm ofwrap()
, which are used inmake([]string, rows)
, then lead toruntime error: makeslice: len out of range
.