{"record":{"id":"b31fcab70dd1d09c","repo":"siyuan-note/siyuan","slug":"conf-language-34","errorCode":null,"errorMessage":"Conf.Language(34)","messagePattern":"Conf\\.Language\\(34\\)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"kernel/model/onboarding.go","lineNumber":109,"sourceCode":"\tonboarding := Conf.Onboarding\n\tif !onboarding.NewUser || onboarding.Dismissed {\n\t\treturn cloneOnboarding(onboarding), false, nil\n\t}\n\n\tboxes, listErr := ListNotebooks()\n\tif listErr != nil {\n\t\treturn cloneOnboarding(onboarding), false, listErr\n\t}\n\tdocumentExists := onboarding.NotebookID != \"\" && onboarding.DocumentID != \"\" && filelock.IsExist(filepath.Join(\n\t\tutil.DataDir, onboarding.NotebookID, onboarding.DocumentID+\".sy\"))\n\tif reconcileOnboarding(onboarding, boxes, documentExists) {\n\t\tConf.Save()\n\t}\n\tif !onboarding.NewUser || onboarding.State == conf.OnboardingCompleted {\n\t\treturn cloneOnboarding(onboarding), false, nil\n\t}\n\tif util.ReadOnly || Conf.Publish.Enable {\n\t\treturn cloneOnboarding(onboarding), false, errors.New(Conf.Language(34))\n\t}\n\n\tif onboarding.NotebookID == \"\" {\n\t\tif len(boxes) > 0 {\n\t\t\tif len(boxes) == 1 && boxes[0].Name == Conf.Language(342) {\n\t\t\t\tonboarding.NotebookID = boxes[0].ID\n\t\t\t\tonboarding.State = conf.OnboardingNotebookCreated\n\t\t\t\tConf.Save()\n\t\t\t} else {\n\t\t\t\tonboarding.State = conf.OnboardingCompleted\n\t\t\t\tonboarding.NewUser = false\n\t\t\t\tConf.Save()\n\t\t\t\treturn cloneOnboarding(onboarding), false, nil\n\t\t\t}\n\t\t}\n\n\t\tif onboarding.NotebookID == \"\" {\n\t\t\tonboarding.NotebookID, err = CreateBox(Conf.Language(342))","sourceCodeStart":91,"sourceCodeEnd":127,"githubUrl":"https://github.com/siyuan-note/siyuan/blob/9f775e8a12daef8255556097396f9b2739078892/kernel/model/onboarding.go#L91-L127","documentation":"EnsureOnboarding returns errors.New(Conf.Language(34)) when the workspace is read-only (util.ReadOnly) or publishing is enabled (Conf.Publish.Enable) while a new-user onboarding session still needs to run. The onboarding flow cannot safely write its state under those conditions, so it is aborted with a localized user-facing message.","triggerScenarios":"A brand-new user (onboarding.NewUser true, State != OnboardingCompleted) opens SiYuan while the workspace is mounted read-only, or while the Publish feature is enabled; the kernel refuses to run the interactive onboarding steps.","commonSituations":"Running SiYuan from read-only media or a read-only volume mount; workspace directory owned by another user; publish server mode where onboarding writes would conflict; Docker container with read-only data volume.","solutions":["Make the workspace data directory writable by the SiYuan process (fix permissions/ownership)","Disable the Publish option in Settings - Publish (or remove the publish config) so onboarding can proceed","Remount the volume read-write (e.g. remove :ro from the Docker mount)","Complete onboarding on a writable instance instead"],"exampleFix":"// environment: docker run -v siyuan-data:/data:ro ...\n// before\n$ docker run -v siyuan-data:/data:ro b3log/siyuan\n// after (read-write mount, writable user)\n$ docker run -v siyuan-data:/data b3log/siyuan","handlingStrategy":"validation","validationCode":"// Before relying on onboarding, check workspace writability\nif util.ReadOnly || conf.PublishEnabled {\n\t// onboarding will be skipped; do not depend on it\n}","typeGuard":null,"tryCatchPattern":"docs, _, err := EnsureOnboarding()\nif err != nil {\n\t// err is a localized user message; show it and skip onboarding gracefully\n}","preventionTips":["Mount the workspace data directory read-write before first launch","Disable publish mode while running initial setup","Check container volume flags (:ro vs read-write) when deploying with Docker","Fix directory ownership so the SiYuan process user can write"],"tags":["go","config","read-only","onboarding"],"backgroundTag":"invalid-config-value","analyzedSha":"9f775e8a12daef8255556097396f9b2739078892","analyzedAt":"2026-09-19T03:17:15.984Z","contentChangedAt":"2026-09-19T03:17:15.984Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}