BigPizzaV3/CodexPlusPlus · error · anyhow::Error
Dream Skin image is not managed by Codex++
Error message
Dream Skin image is not managed by Codex++
What it means
Dream Skin image backup/restore only accepts image files that codex_plus_core::dream_skin::is_managed_dream_skin_image recognizes as managed by Codex++ (located/tracked relative to the state_dir). Any other path passed to managed_dream_skin_image_backup is rejected to prevent backing up or restoring unrelated files.
Solutions
- Point the operation at the original Dream Skin image path inside the managed state directory
- Reinstall/re-apply the Dream Skin asset so it is re-registered as managed, then retry
- Verify the state_dir passed to the command matches the one used when the image was installed
Example fix
// before
backup_image(userPickedPath);
// after
if (!isManagedDreamSkinImage(p, stateDir)) throw new Error("choose the managed dream skin image");
backup_image(p); Defensive patterns
Strategy: validation
Validate before calling
if (!isManagedDreamSkinImagePath(path, stateDir)) throw new Error('path is not a managed dream skin image'); Try / catch
try { await invoke('dream_skin_backup_image', { path }) } catch (e) { if (String(e).includes('not managed')) showManagedPathHint(); } Prevention
- Only pass paths previously returned by the Dream Skin install API
- Keep state_dir consistent across sessions
- Never let users browse arbitrary images for managed operations
When it happens
Trigger: Calling the Dream Skin image backup command (commands.rs ~2389) with a path where is_managed_dream_skin_image(path, state_dir) returns false — path outside the managed Dream Skin state directory or not matching managed naming.
Common situations: User picked an arbitrary image from disk; the state_dir was moved or changed so the path no longer resolves as managed; a renamed/moved managed image no longer matches the expected layout.
Understand the failure class
Background: 'Could not be found', 'does not exist', 'not found in database': the resource-not-found family when an ID, slug, key, or URI lookup comes back empty — this error's family across 20 libraries.
Related errors
- 主题包必须是 32 MiB 以内的普通 ZIP 文件
- 请填写 API 的模型名称
- 官方混合 API 不应在 auth.json 中保存 OPENAI_API_KEY。请清理此供应商的…
- 请填写 API 的模型名称
- API 地址须使用 HTTPS,且不含账号、密码、查询参数或片段
AI-assisted analysis of BigPizzaV3/CodexPlusPlus@b1ed92e5e4 (2026-09-19).
Data as JSON: /api/errors/0d14b955961f3719.
Report an issue: GitHub.
Appendix: source
Thrown at apps/codex-plus-manager/src-tauri/src/commands.rs:2389
runtime: codex_plus_core::dream_skin_runtime::dream_skin_status(debug_port).await,
saved_for_next_launch: false,
}
}
fn empty_dream_skin_image_payload() -> DreamSkinImagePayload {
DreamSkinImagePayload {
path: String::new(),
content_type: String::new(),
size_bytes: 0,
}
}
fn managed_dream_skin_image_backup(
path: &Path,
state_dir: &Path,
) -> anyhow::Result<ManagedDreamSkinImageBackup> {
if !codex_plus_core::dream_skin::is_managed_dream_skin_image(path, state_dir) {
anyhow::bail!("Dream Skin image is not managed by Codex++");
}
Ok(ManagedDreamSkinImageBackup {
path: path.to_path_buf(),
bytes: fs::read(path)?,
})
}
fn restore_managed_dream_skin_image_backup(
backup: ManagedDreamSkinImageBackup,
) -> anyhow::Result<()> {
codex_plus_core::settings::atomic_write(&backup.path, &backup.bytes)
}
fn dream_skin_content_type(path: &Path) -> &'static str {
match path
.extension()
.and_then(|extension| extension.to_str())
.map(str::to_ascii_lowercase)View on GitHub (pinned to b1ed92e5e4)