BigPizzaV3/CodexPlusPlus · error

manifest.themeId 无效

Error message

manifest.themeId 无效

What it means

Thrown by validate_manifest when manifest.theme_id is shorter than 3 chars, longer than 64 chars, or fails the valid_theme_id charset/shape check. The offending input is the themeId string in manifest.json; this identity guard runs right after the protocol-version check and must pass before the theme can be installed or matched to theme.json.

Source

Thrown at crates/codex-plus-core/src/dream_skin_package.rs:915

    match name {
        "manifest.json" => MANIFEST_LIMIT,
        "theme.json" => THEME_LIMIT,
        "theme.css" => CSS_LIMIT,
        "LICENSE.txt" => LICENSE_LIMIT,
        "manifest.sig" => SIGNATURE_LIMIT,
        _ => IMAGE_LIMIT,
    }
}

fn validate_manifest(manifest: &DreamSkinPackageManifest, platform: &str) -> anyhow::Result<()> {
    if manifest.package_version != 1 || manifest.skin_api_version != 1 {
        bail!("不支持的 Dream Skin 主题协议版本");
    }
    if manifest.theme_id.chars().count() < 3
        || manifest.theme_id.chars().count() > 64
        || !valid_theme_id(&manifest.theme_id)
    {
        bail!("manifest.themeId 无效");
    }
    if !valid_semver(&manifest.version) || !valid_semver(&manifest.min_client_version) {
        bail!("manifest 版本号无效");
    }
    if compare_semver(&manifest.min_client_version, "1.5.12").is_gt() {
        bail!(
            "主题包需要更新版本的 Dream Skin 协议:{}",
            manifest.min_client_version
        );
    }
    if manifest.platforms.is_empty()
        || manifest.platforms.len() > 2
        || has_duplicates(&manifest.platforms)
        || manifest
            .platforms
            .iter()
            .any(|item| !matches!(item.as_str(), "macos" | "windows"))
    {

View on GitHub (pinned to f2074595a2)

Solutions

  1. 把 themeId 改为 3-64 个合法字符(字母数字及主题规范允许的符号)
  2. 检查是否有多余空格或不可见字符
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at crates/codex-plus-core/src/dream_skin_package.rs:915 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of BigPizzaV3/CodexPlusPlus@f2074595a2 (2026-08-23). Data as JSON: /api/errors/234be1c2d15f3028. Report an issue: GitHub.