attribute_spec
attribute_spec
evo.compute.tasks.common.source_target.attribute_spec
Convert a typed attribute object to a create or update specification.
Existing attributes become an update operation referencing the attribute; pending attributes become a create operation carrying the attribute name. Any other value is passed through untouched so that already-constructed specifications (or dicts) validate normally.
Args: attr: A typed attribute object, or an already-constructed specification.
Returns: A :class:CreateAttribute or :class:UpdateAttribute for typed attributes, otherwise attr unchanged.