AlistGo/alist · error
not support index: %s
Error message
not support index: %s
What it means
search.Init(mode) looks the requested mode up in searcher.NewMap and it is not a registered searcher backend, so the configured index type string is rejected. Registered names come from the compiled-in searcher registry (database, meilisearch, ...; 'none' is handled earlier with a warning).
Source
Thrown at internal/search/search.go:39
if instance.Config().Name == mode {
return nil
}
err := instance.Release(context.Background())
if err != nil {
log.Errorf("release instance err: %+v", err)
}
instance = nil
}
if Running() {
return fmt.Errorf("index is running")
}
if mode == "none" {
log.Warnf("not enable search")
return nil
}
s, ok := searcher.NewMap[mode]
if !ok {
return fmt.Errorf("not support index: %s", mode)
}
i, err := s()
if err != nil {
log.Errorf("init searcher error: %+v", err)
} else {
instance = i
}
return err
}
func Search(ctx context.Context, req model.SearchReq) ([]model.SearchNode, int64, error) {
return instance.Search(ctx, req)
}
func Index(ctx context.Context, parent string, obj model.Obj) error {
if instance == nil {
return errs.SearchNotAvailable
}View on GitHub (pinned to 843d9dc814)
Solutions
- Set the search mode to an exact registered value (check searcher.NewMap keys in your build, e.g. 'database', 'meilisearch', or 'none')
- Remove surrounding whitespace and match lowercase spelling
- If you expect a custom backend, verify the binary actually includes it
Defensive patterns
Strategy: validation
Validate before calling
var supportedSearchModes = map[string]bool{"none": true, "database": true, "meilisearch": true}
mode = strings.TrimSpace(strings.ToLower(mode))
if !supportedSearchModes[mode] {
return fmt.Errorf("unsupported search mode %q", mode)
} Prevention
- Offer search mode as a dropdown, never free text
- Validate config values at load time against searcher.NewMap keys
- Trim/case-normalize user-supplied mode strings
When it happens
Trigger: Setting the search config to a string that is not a built-in searcher name — typos like 'meilisearch ' (trailing space), 'MeiliSearch' (case), or a build where that searcher was not compiled in.
Common situations: Editing settings manually or via API with wrong casing/whitespace; using a config value carried over from a fork or plugin that this binary does not include.
Related errors
- SearchNotAvailable
- frp server address is required
- remote_port is required for tcp proxy type
- unsupported proxy type: %s
- page can't < 1
AI-assisted analysis of AlistGo/alist@843d9dc814 (2026-08-15).
Data as JSON: /api/errors/66b4bdebb78a45b3.
Report an issue: GitHub.