BoundaryML/baml · error · ManifestError

{path}: `[dependencies]` is not supported in a project manif

Error message

{path}: `[dependencies]` is not supported in a project manifest yet: package imports are pending a design pass. Remove the table; a project reaches the standard library implicitly.

What it means

A `ManifestError` variant. The manifest contains a `[dependencies]` table, which project manifests do not support yet: package imports are pending a design pass. Projects reach the standard library implicitly and cannot declare external dependencies for now.

Source

Thrown at baml_language/crates/baml_db/src/manifest.rs:191

}

/// Parse `baml.toml` text into the typed manifest.
pub fn parse(content: &str) -> Result<BamlToml, toml::de::Error> {
    toml::from_str(content)
}

/// Why a manifest's `[package].name` could not be resolved.
#[derive(Debug, Clone, PartialEq, Eq, thiserror::Error)]
pub enum ManifestError {
    #[error(
        "{path}: missing `[package]` table.\nAdd:\n\n    [package]\n    name = \"<your-project-name>\"\n"
    )]
    MissingPackageTable { path: std::path::PathBuf },
    #[error("{path}: `[package]` is missing `name = \"<your-project-name>\"`.")]
    MissingPackageName { path: std::path::PathBuf },
    #[error("{path}: `[package].name` cannot be empty.")]
    EmptyPackageName { path: std::path::PathBuf },
    #[error(
        "{path}: `[dependencies]` is not supported in a project manifest yet: package imports are \
         pending a design pass. Remove the table; a project reaches the standard library implicitly."
    )]
    DependenciesUnsupported { path: std::path::PathBuf },
    #[error(
        "{path}: `[package].prelude` is reserved for the standard library's own manifests. Remove it."
    )]
    PreludeUnsupported { path: std::path::PathBuf },
}

/// Refuse the manifest tables only the standard library's own manifests may
/// carry. Package imports are not user surface area until they get a design
/// pass, so a project manifest with `[dependencies]` (or the stdlib-only
/// `[package].prelude`) is an error, not a silently ignored table.
pub fn reject_stdlib_only_tables(
    manifest: &BamlToml,
    toml_path: &std::path::Path,
) -> Result<(), ManifestError> {

View on GitHub (pinned to bd85ce9dee)

Solutions

  1. Remove the `[dependencies]` table from the manifest; the standard library is available implicitly.
  2. Do not attempt to declare cross-package dependencies until package imports are designed.
  3. If you need shared code, keep it within the single project for now.

Example fix

// before
[package]
name = "my-project"

[dependencies]
foo = "1.0"
// after
[package]
name = "my-project"
Defensive patterns

Strategy: try-catch

Validate before calling

fn manifest_has_no_dependencies(raw: &str) -> bool {
    raw.parse::<toml::Value>().map(|v| v.get("dependencies").is_none()).unwrap_or(true)
}

Try / catch

match load_manifest(path) {
    Err(ManifestError::DependenciesUnsupported { path }) => eprintln!("{path:?}: remove [dependencies]; stdlib is implicit"),
    Err(e) => eprintln!("manifest error: {e}"),
    Ok(m) => m,
}

Prevention

When it happens

Trigger: Loading a project manifest that includes any `[dependencies]` table (with or without entries), e.g. `baml.toml` with `[dependencies]\nfoo = "1.0"`.

Common situations: Copying dependency syntax from Cargo/npm conventions into a BAML project manifest; attempting to import another user package before the package-imports feature ships.

Understand the failure class

Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.

Related errors


AI-assisted analysis of BoundaryML/baml@bd85ce9dee (2026-09-12). Data as JSON: /api/errors/f8afd560afa19d36. Report an issue: GitHub.