DioxusLabs/dioxus · error · anyhow::Error

base64 --decode failed

Error message

base64 --decode failed: {}

What it means

The bundler piped the base64-encoded signing certificate through `base64 --decode` and the decoder exited non-zero (malformed input or missing tooling). The decode failure message includes the command's stderr so the certificate secret can be checked.

Solutions

  1. The base64 value could not be decoded. Ensure the API key environment variable contains valid base64.
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at packages/cli/src/bundler/macos.rs:935 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of DioxusLabs/dioxus@24f6a829df (2026-08-23). Data as JSON: /api/errors/543b3884b3c8d913. Report an issue: GitHub.

Appendix: source

Thrown at packages/cli/src/bundler/macos.rs:935

        .stdout(Stdio::piped())
        .stderr(Stdio::piped())
        .spawn()
        .context("Failed to decode base64 certificate")?;

    if let Some(mut stdin) = child.stdin.take() {
        stdin
            .write_all(input.as_bytes())
            .await
            .context("Failed writing base64 certificate to decoder stdin")?;
    }

    let output = child
        .wait_with_output()
        .await
        .context("Failed to decode base64 certificate")?;

    if !output.status.success() {
        bail!(
            "base64 --decode failed: {}",
            String::from_utf8_lossy(&output.stderr)
        );
    }

    Ok(output.stdout)
}

/// The result of DMG bundling, which may include both the `.dmg` and `.app` outputs.
pub(crate) struct DmgBundled {
    /// Paths to the generated `.dmg` file(s).
    pub dmg: Vec<PathBuf>,
    /// Paths to the generated `.app` bundle(s) (if the `.app` was built as a dependency).
    pub app: Vec<PathBuf>,
}

/// A target to be code-signed.
struct SignTarget {

View on GitHub (pinned to 24f6a829df)