make_url validation errors can be unclear

Bug #1693490 reported by Steven Hardy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Fix Released
Medium
Zane Bitter

Bug Description

I hit an error where make_url fails to validate the port like:

2017-05-25 10:24:48Z [undercloud]: CREATE_FAILED Resource CREATE failed: Error in 13 output role_data: resources.UndercloudServiceChain.resources.PuppetServices.Error in HeatBase output role_data: Invalid URL port ""

Which is fine, only the template referenced includes three make_url calls and this doesn't help me know which one is wrong.

Adding the args the function was called with to the output would help identify the faulty one I think, when debugging I added the args to the output so it looks like:

2017-05-25 11:46:00Z [undercloud.UndercloudServiceChain.PuppetServices]: CREATE_FAILED Resource CREATE failed: Error in 13 output role_data: Error in HeatBase output role_data: Invalid URL port "" for make_url called with args {u'path': u'/v1/waitcondition', u'host': '', u'scheme': '', u'port': ''}

This shows more clearly which call isn't working so I can fix it

Steven Hardy (shardy)
Changed in heat:
milestone: none → pike-2
status: New → Triaged
assignee: nobody → Steven Hardy (shardy)
importance: Undecided → Medium
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/468017

Changed in heat:
status: Triaged → In Progress
Changed in heat:
assignee: Steven Hardy (shardy) → Zane Bitter (zaneb)
Revision history for this message
Zane Bitter (zaneb) wrote :

Note that this is a single instance of a larger problem: when a function fails at validation time, we print out the path that will allow you to locate it in the template. But if it passes validation and later fails when we try to resolve it (due to one of the arguments being an intrinsic function, so we don't know the value at validation time) then there's no such mechanism.

Rico Lin (rico-lin)
Changed in heat:
milestone: pike-2 → pike-3
Rico Lin (rico-lin)
Changed in heat:
milestone: pike-3 → pike-rc1
Rabi Mishra (rabi)
Changed in heat:
milestone: pike-rc1 → pike-rc2
Rico Lin (rico-lin)
Changed in heat:
milestone: pike-rc2 → queens-1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to heat (master)

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

commit d887f34c9b5b8412291752e2004943fa1cc7959c
Author: Steven Hardy <email address hidden>
Date: Thu May 25 12:34:47 2017 +0100

    Clarify make_url validation errors

    The current output can be a little confusing in the case where
    you have multiple make_url calls in one template - adding the
    args to the output gives you a better chance to debug as you
    can e.g compare the path with the template.

    Change-Id: I73a0ffa8ee7d6a7f7a210548c966eb9faf6f5f5b
    Closes-Bug: #1693490

Changed in heat:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/heat 10.0.0.0b1

This issue was fixed in the openstack/heat 10.0.0.0b1 development milestone.

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.