First start: create the config file and open the Config view
Without a config file arr-tui refused to start. It now creates an empty one (private, with its directory) and opens the Config view. A service with neither address nor key is "not configured", which validation allows: its client returns ErrNotConfigured without a request, its indicator stays grey, it is logged once as information, and its lists say so instead of showing errors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019reK4DUGYqDUjniWYJvwUW
This commit is contained in:
@@ -363,8 +363,11 @@ func (v *libraryView) reloadPane(p *libPane) {
|
||||
defer v.loadSeriesFiles(false)
|
||||
}
|
||||
if err != nil {
|
||||
// Keep showing the last good list; say why it is stale.
|
||||
v.app.SetMessage("[red]" + kind.service() + ": " + tview.Escape(err.Error()))
|
||||
// Keep showing the last good list; say why it is stale. A service
|
||||
// that is not set up says so in its list instead.
|
||||
if !notConfigured(err) {
|
||||
v.app.SetMessage("[red]" + kind.service() + ": " + tview.Escape(err.Error()))
|
||||
}
|
||||
} else {
|
||||
p.all, p.loaded = items, true
|
||||
}
|
||||
@@ -418,6 +421,8 @@ func (v *libraryView) renderPane(p *libPane) {
|
||||
}
|
||||
placeholder := "Nothing matches the filter"
|
||||
switch {
|
||||
case notConfigured(p.err):
|
||||
placeholder = p.kind.service() + " is not configured (Config view, F6)"
|
||||
case p.err != nil && !p.loaded:
|
||||
placeholder = "Could not load, press r to retry"
|
||||
case !p.loaded:
|
||||
|
||||
Reference in New Issue
Block a user