{"record":{"id":"86867d4de4618fc9","repo":"siyuan-note/siyuan","slug":"update-package-is-unavailable-for-the-current-plat","errorCode":null,"errorMessage":"update package is unavailable for the current platform","messagePattern":"update package is unavailable for the current platform","errorType":"exception","errorClass":"errUpdatePackageUnavailable","httpStatus":null,"severity":"error","filePath":"kernel/model/updater.go","lineNumber":119,"sourceCode":"\t} else {\n\t\tutil.PushUpdateMsg(\"update-pkg-downloading\", Conf.Language(104), 7000)\n\t}\n}\n\nfunc getUpdatePkg() (downloadPkgURLs []string, checksum string, err error) {\n\trelease, err := getUpdateRelease(false)\n\tif err != nil {\n\t\treturn\n\t}\n\n\tif isVersionUpToDate(release.Version) {\n\t\terr = fmt.Errorf(\"version is up to date\")\n\t\treturn\n\t}\n\n\tpkgName := currentInstallPackageName(release.Version)\n\tif \"\" == pkgName {\n\t\terr = fmt.Errorf(\"%w for the current platform\", errUpdatePackageUnavailable)\n\t\treturn\n\t}\n\tpkg := release.Packages[pkgName]\n\tif nil == pkg || 0 == len(pkg.URLs) {\n\t\terr = fmt.Errorf(\"%w: [%s]\", errUpdatePackageUnavailable, pkgName)\n\t\treturn\n\t}\n\tif \"\" == pkg.Checksum {\n\t\terr = fmt.Errorf(\"%w: [%s] checksum is unavailable\", errUpdatePackageUnavailable, pkgName)\n\t\treturn\n\t}\n\tdownloadPkgURLs = append(downloadPkgURLs, pkg.URLs...)\n\tchecksum = pkg.Checksum\n\treturn\n}\n\nfunc downloadInstallPkg(pkgURL, checksum string) (err error) {\n\tif \"\" == pkgURL || \"\" == checksum {","sourceCodeStart":101,"sourceCodeEnd":137,"githubUrl":"https://github.com/siyuan-note/siyuan/blob/251596fc0de2f9528c00c224252fd073a99973f4/kernel/model/updater.go#L101-L137","documentation":"Returned by getUpdatePkg() when currentInstallPackageName(release.Version) returns an empty string. currentInstallPackageSuffix() returns \"\" for any OS that is not Windows or macOS, and for GOARCH values other than amd64/arm64 on those two OSes. This is a wrapped form of errUpdatePackageUnavailable, so errors.Is(err, errUpdatePackageUnavailable) matches it.","triggerScenarios":"Running on Linux (the updater produces no Linux binary — Linux users install via distro packages). Running on Windows/macOS with an unsupported GOARCH (e.g. 386, mips). Running a custom build compiled with an unusual runtime.GOARCH.","commonSituations":"Self-compiled Linux desktop build expecting the in-app auto-updater to work. Running under WSL where gulu.OS.IsWindows() may be false. Containerized deployment (though skipNewVerInstallPkg usually short-circuits first for containers).","solutions":["On Linux, use your distribution's package manager or the official AppImage/tarball; the in-app updater cannot self-update on Linux.","Verify runtime.GOARCH is amd64 or arm64; rebuild with GOARCH=amd64 if you compiled for an exotic arch.","Suppress the in-app download UI on unsupported platforms (Conf.System.DownloadInstallPkg / skipNewVerInstallPkg)."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Check platform support before invoking the updater pipeline.\nif currentInstallPackageSuffix() == \"\" {\n    // No installable package for this OS/arch (e.g. Linux, 32-bit).\n    return // skip download UI entirely\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["On Linux, document that updates come from the distro/AppImage, not the in-app updater.","Gate the download UI on currentInstallPackageSuffix() != \"\".","Confirm runtime.GOARCH is amd64 or arm64 at build time for Windows/macOS targets."],"tags":["update","platform","linux","package","architecture"],"backgroundTag":null,"analyzedSha":"251596fc0de2f9528c00c224252fd073a99973f4","analyzedAt":"2026-08-12T21:18:37.123Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}