HOT get_attr returning empty string if there is no value breaks validation

Bug #1287397 reported by Randall Burt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Fix Released
High
Randall Burt

Bug Description

The get_attr HOT intrinsic function returns an empty string in cases where it cannot reconcile a value. However, for LIST properties (and probably MAP as well), this results in validation failure during initial stack-create if you map a LIST property's value to an attribute of another resource that returns a list. This seems to have cropped up when get_attr was modified to allow traversing complex attribute values.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to heat (master)

Fix proposed to branch: master
Review: https://review.openstack.org/77713

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to heat (master)

Reviewed: https://review.openstack.org/77713
Committed: https://git.openstack.org/cgit/openstack/heat/commit/?id=f5fcfb45cfc79405e5cc5628047720ac0ce418a8
Submitter: Jenkins
Branch: master

commit f5fcfb45cfc79405e5cc5628047720ac0ce418a8
Author: Randall Burt <email address hidden>
Date: Mon Mar 3 16:18:17 2014 -0600

    Return None when get_attr cannot resolve a value

    To prevent validation failures prior to resource creation, get_attr
    returns None if the attribute or the sub-value cannot be resolved.
    This returns this function to consistency with prior behavior and allows
    non-string attribute values to be resolved to their proper default
    "empty" data types during initial template validation.

    Change-Id: I0e02174c43be65a647358a2047da8213635f85d8
    Closes-Bug: 1287397

Changed in heat:
status: In Progress → Fix Committed
Changed in heat:
importance: Undecided → High
Thierry Carrez (ttx)
Changed in heat:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in heat:
milestone: icehouse-rc1 → 2014.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.