read_envelope_hugr_str¶
- hugr.envelope.read_envelope_hugr_str(envelope: str, resolve_from: ExtensionRegistry | None = None) Hugr[source]¶
Decode a HUGR from an envelope.
- Parameters:
envelope – The string representing a Hugr envelope.
resolve_from – If not None, an extension registry to resolve the custom operations and types.
- Returns:
The deserialized Hugr object.
- Raises:
ValueError – If the envelope does not contain a single module.