jdx/mise · error · eyre::Report

managed system files require owner

Error message

managed system files require owner '{owner}', but that bootstrap user is absent

What it means

The bootstrap accounts config declares the owner user referenced by a managed file/directory with state = "absent". Since the file must be owned by that user (state present), owning it via an account the same bootstrap run deletes is contradictory, so validation fails up front. This prevents mid-run ownership resolution failures.

Solutions

  1. Remove the `owner = "x"` key from the file/directory entries that reference the absent user.
  2. Change the user's state back to present if the files genuinely need that owner.
  3. Reassign ownership to a user that exists or is declared present (e.g. "root").

Example fix

# before
[bootstrap.users.oldsvc]
state = "absent"

[bootstrap.files.appconf]
path = "/etc/myapp/app.conf"
owner = "oldsvc"

# after
[bootstrap.users.oldsvc]
state = "absent"

[bootstrap.files.appconf]
path = "/etc/myapp/app.conf"
owner = "root"
Defensive patterns

Strategy: validation

Validate before calling

// lint your TOML: no file entry may reference an owner whose user state is "absent"
fn owner_not_absent(files: &[Entry], users: &HashMap<String, UserState>) -> Result<()> {
    for f in files {
        if let Some(o) = &f.owner {
            if users.get(o) == Some(&UserState::Absent) {
                bail!("file {} references absent owner {}", f.path, o);
            }
        }
    }
    Ok(())
}

Prevention

When it happens

Trigger: `validate_principals` runs during bootstrap planning; a [bootstrap.files]/[bootstrap.directories] entry has `owner = "x"` with state present, while [bootstrap.users] (or accounts config) declares user x with state = "absent".

Common situations: Copy-pasted account blocks where the user was later marked absent but file entries still reference them; pruning old users without updating file ownership declarations.

Understand the failure class

Background: Conflicting config options: "cannot be used together" — configuration validation errors across open-source libraries — this error's family across 162 libraries.

Related errors


AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17). Data as JSON: /api/errors/832717913f6810e4. Report an issue: GitHub.

Appendix: source

Thrown at src/system/managed_files.rs:927

    accounts: Option<&super::accounts::AccountRequests>,
    allow_pending_accounts: bool,
) -> Result<()> {
    for (owner, group) in files
        .iter()
        .filter(|request| request.state == ManagedState::Present)
        .map(|request| (request.owner.as_deref(), request.group.as_deref()))
        .chain(
            directories
                .iter()
                .filter(|request| request.state == ManagedState::Present)
                .map(|request| (request.owner.as_deref(), request.group.as_deref())),
        )
    {
        if let Some(owner) = owner {
            match accounts
                .and_then(|accounts| accounts.users.iter().find(|request| request.name == owner))
            {
                Some(request) if request.state == super::accounts::AccountState::Absent => bail!(
                    "managed system files require owner '{owner}', but that bootstrap user is absent"
                ),
                Some(request)
                    if allow_pending_accounts
                        && request.plan().action == ResourceAction::Unknown =>
                {
                    bail!(
                        "managed system files require owner '{owner}', but that bootstrap user cannot be safely converged"
                    )
                }
                Some(_) if allow_pending_accounts => {}
                Some(_) | None => {
                    resolve_user(owner)?;
                }
            }
        }
        if let Some(group) = group {
            match accounts

View on GitHub (pinned to 533346cc37)