Skip to main content

extract_declared_spawn_allow

Function extract_declared_spawn_allow 

Source
pub fn extract_declared_spawn_allow(
    artifact_name: &str,
    artifact_version: &str,
    manifest_yaml: &str,
) -> Result<Vec<String>, RuntimeError>
Expand description

The capabilities.spawn.allow a packed manifest declares, read on its own.

The sibling of extract_declared_env_allow, and narrow for the same reason: walking a spawn.allow closure means reading which capsules a child may in turn spawn, and a whole-manifest parse would demand that child’s own ${VAR} references be resolvable first.

A manifest with no capabilities: block, or none under spawn:, declares nothing and yields an empty list. Malformed YAML, or a spawn.allow that is not a list of strings, is an error naming the artifact and version.