siyuan-note/siyuan · error
invalid display name
Error message
invalid display name
What it means
Thrown by validateBootAppearanceDisplayName when any displayName entry violates the field constraints: empty/blank language key or value, language key longer than 32 bytes, value longer than 128 bytes, or value containing NUL/CR/LF. It enforces sane, single-line display names.
Source
Thrown at kernel/model/boot_appearance.go:684
info, lstatErr := os.Lstat(current)
if lstatErr != nil {
return lstatErr
}
if info.Mode()&os.ModeSymlink != 0 {
return ErrBootAppearanceAssetForbidden
}
}
return nil
}
func validateBootAppearanceDisplayName(displayName map[string]string) error {
if strings.TrimSpace(displayName["default"]) == "" {
return errors.New("displayName.default is required")
}
for lang, value := range displayName {
if strings.TrimSpace(lang) == "" || strings.TrimSpace(value) == "" || len(lang) > 32 || len(value) > 128 ||
strings.ContainsAny(value, "\x00\r\n") {
return errors.New("invalid display name")
}
}
return nil
}
func normalizeBootAppearanceFrontends(manifestFrontends, pluginFrontends []string) ([]string, error) {
candidates := manifestFrontends
if len(candidates) == 0 {
candidates = pluginFrontends
}
frontends := []string{}
seen := map[string]bool{}
for _, frontend := range candidates {
if frontend == "all" && len(manifestFrontends) == 0 {
for _, normalized := range []string{"desktop", "mobile"} {
if !seen[normalized] {
seen[normalized] = true
frontends = append(frontends, normalized)View on GitHub (pinned to 8641553a1f)
Solutions
- Ensure every displayName key is a non-empty locale tag of at most 32 characters.
- Ensure every value is non-blank, at most 128 characters, and contains no newlines/CR/NUL.
- Collapse multi-line names into a single line and move descriptions elsewhere.
Example fix
// before
"displayName": {"": "My Boot\nSplash"}
// after
"displayName": {"default": "My Boot Splash"} Defensive patterns
Strategy: validation
Validate before calling
function validDisplayNames(dn) { return Object.entries(dn || {}).every(([lang, v]) => lang.trim() !== "" && typeof v === "string" && v.trim() !== "" && lang.length <= 32 && v.length <= 128 && !/[\u0000\r\n]/.test(v)); } Try / catch
try { await installBootAppearance(pkg); } catch (e) { if (String(e).includes("invalid display name")) { /* fix offending displayName entry */ } else throw e; } Prevention
- Validate displayName against length and charset rules in packaging CI
- Strip newlines from generated names
- Keep locale keys under 32 chars
When it happens
Trigger: A manifest displayName entry like "": "Name", "en_US": " ", an over-long name (>128 chars), or a name with embedded "\n"; hit while loading the package.
Common situations: Pasting multi-line marketing text as the name, generating manifests programmatically with empty keys, or very long product names.
Understand the failure class
Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.
Related errors
- 199
- invalid marketplace package manifest
- too many layers: %d
- invalid or duplicate layer ID
- unsupported layer type [%s]
AI-assisted analysis of siyuan-note/siyuan@8641553a1f (2026-09-11).
Data as JSON: /api/errors/54199b7ac1dce996.
Report an issue: GitHub.