)]}'
{"setup.cfg":[{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"8af95b9b66be964411d7f5e2598e32eebf3921bd","unresolved":false,"context_lines":[{"line_number":58,"context_line":"    tripleo.create_plan \u003d tripleo_common.actions.plan:CreatePlanAction"},{"line_number":59,"context_line":"    tripleo.register_nodes \u003d tripleo_common.actions.baremetal:RegisterNodesAction"},{"line_number":60,"context_line":"    tripleo.create_node_role_patch \u003d tripleo_common.actions.nodes:CreateNodeRolePatchAction"},{"line_number":61,"context_line":"    tripleo.get_lowest_hardware_node \u003d tripleo_common.actions.nodes:GetLowestHardwareNodeAction"}],"source_content_type":"text/x-ttcn-cfg","patch_set":12,"id":"9abb7d3a_1c074f1e","line":61,"range":{"start_line":61,"start_character":68,"end_line":61,"end_character":95},"updated":"2016-06-03 11:24:00.000000000","message":"this line needs to be removed.","commit_id":"2bfd52c24308124c581b2a6c6625ce9ec9ae9a29"}],"tripleo_common/actions/nodes.py":[{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"ac25078ec8ca721d7a941600491506db84d9c7e0","unresolved":false,"context_lines":[{"line_number":12,"context_line":"# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the"},{"line_number":13,"context_line":"# License for the specific language governing permissions and limitations"},{"line_number":14,"context_line":"# under the License."},{"line_number":15,"context_line":"import json"},{"line_number":16,"context_line":"import logging"},{"line_number":17,"context_line":"import re"},{"line_number":18,"context_line":"import yaml"}],"source_content_type":"text/x-python","patch_set":2,"id":"bab6814e_62f7fbf5","line":15,"range":{"start_line":15,"start_character":0,"end_line":15,"end_character":6},"updated":"2016-05-24 13:58:29.000000000","message":"check your unused imports, will fail pep8","commit_id":"a0affa8b8265901d63d6d502b556914918f8a655"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"ac25078ec8ca721d7a941600491506db84d9c7e0","unresolved":false,"context_lines":[{"line_number":18,"context_line":"import yaml"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"from tripleo_common.actions import base"},{"line_number":21,"context_line":"from tripleo_common.core import constants"},{"line_number":22,"context_line":"from tripleo_common.core import exception"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":2,"id":"bab6814e_42cf57b3","line":21,"range":{"start_line":21,"start_character":32,"end_line":21,"end_character":41},"updated":"2016-05-24 13:58:29.000000000","message":"constants and exception imports unused","commit_id":"a0affa8b8265901d63d6d502b556914918f8a655"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"ac25078ec8ca721d7a941600491506db84d9c7e0","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        return result[0]"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"class GetNodeRoleAction(base.TripleOAction):"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"    def __init__(self, node):"},{"line_number":39,"context_line":"        super(GetNodeRoleAction, self).__init__()"}],"source_content_type":"text/x-python","patch_set":2,"id":"bab6814e_6748ad88","line":36,"range":{"start_line":36,"start_character":0,"end_line":36,"end_character":5},"updated":"2016-05-24 13:58:29.000000000","message":"missing docs e.g.\n\"\"\"Gets Role For Node\n\n:param node: \n:return:\n\"\"\"","commit_id":"a0affa8b8265901d63d6d502b556914918f8a655"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":23,"context_line":"ROLE_RE \u003d re.compile(r\u0027profile:([\\-\\w]+)\u0027)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def get_role_from_capabilities_string(capabilities):"},{"line_number":27,"context_line":"    result \u003d ROLE_RE.findall(capabilities)"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    if result:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_642286bb","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":37},"updated":"2016-05-27 12:52:42.000000000","message":"is this intended to be a public member of this module?  maybe consider adding the underscore prefix.","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"3903a7813750454c5786313b34e8887ee830388f","unresolved":false,"context_lines":[{"line_number":23,"context_line":"ROLE_RE \u003d re.compile(r\u0027profile:([\\-\\w]+)\u0027)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def get_role_from_capabilities_string(capabilities):"},{"line_number":27,"context_line":"    result \u003d ROLE_RE.findall(capabilities)"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    if result:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_0a4aa183","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":37},"in_reply_to":"9abb7d3a_642286bb","updated":"2016-05-27 13:09:53.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":23,"context_line":"ROLE_RE \u003d re.compile(r\u0027profile:([\\-\\w]+)\u0027)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def get_role_from_capabilities_string(capabilities):"},{"line_number":27,"context_line":"    result \u003d ROLE_RE.findall(capabilities)"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    if result:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_4ab4a9f1","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":37},"in_reply_to":"9abb7d3a_642286bb","updated":"2016-05-27 13:07:28.000000000","message":"also please use the following snippet instead of regexes: https://github.com/openstack/python-tripleoclient/blob/master/tripleoclient/utils.py#L626-L630","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        return result[0]"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"def minimal_hardware_spec_reducer(a, b):"},{"line_number":34,"context_line":"    # NOTE(hpokorny): This is a very simplistic algorithm."},{"line_number":35,"context_line":"    # How can we improve it?"},{"line_number":36,"context_line":"    if a[\u0027properties\u0027][\u0027memory_mb\u0027] \u003e b[\u0027properties\u0027][\u0027memory_mb\u0027]:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_2417de52","line":33,"range":{"start_line":33,"start_character":4,"end_line":33,"end_character":33},"updated":"2016-05-27 12:52:42.000000000","message":"public?","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"3903a7813750454c5786313b34e8887ee830388f","unresolved":false,"context_lines":[{"line_number":30,"context_line":"        return result[0]"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"def minimal_hardware_spec_reducer(a, b):"},{"line_number":34,"context_line":"    # NOTE(hpokorny): This is a very simplistic algorithm."},{"line_number":35,"context_line":"    # How can we improve it?"},{"line_number":36,"context_line":"    if a[\u0027properties\u0027][\u0027memory_mb\u0027] \u003e b[\u0027properties\u0027][\u0027memory_mb\u0027]:"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_ea4e3d95","line":33,"range":{"start_line":33,"start_character":4,"end_line":33,"end_character":33},"in_reply_to":"9abb7d3a_2417de52","updated":"2016-05-27 13:09:53.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"def node_has_role(role, node):"},{"line_number":43,"context_line":"    capabilities \u003d node[\u0027properties\u0027][\u0027capabilities\u0027]"},{"line_number":44,"context_line":"    return role \u003d\u003d get_role_from_capabilities_string(capabilities)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_0aa101aa","line":43,"updated":"2016-05-27 13:07:28.000000000","message":"capabilities is not a mandatory field, you should expect KeyError here","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"1f54f5561fdfdf6d3867ebedd0b93b3ac0afbfad","unresolved":false,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"def node_has_role(role, node):"},{"line_number":43,"context_line":"    capabilities \u003d node[\u0027properties\u0027][\u0027capabilities\u0027]"},{"line_number":44,"context_line":"    return role \u003d\u003d get_role_from_capabilities_string(capabilities)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_00e04228","line":43,"in_reply_to":"9abb7d3a_0aa101aa","updated":"2016-05-31 14:12:39.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":44,"context_line":"    return role \u003d\u003d get_role_from_capabilities_string(capabilities)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"class CreateNodeRolePatchAction(base.TripleOAction):"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def __init__(self, node, role):"},{"line_number":50,"context_line":"        super(CreateNodeRolePatchAction, self).__init__()"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_641d660f","line":47,"range":{"start_line":47,"start_character":6,"end_line":47,"end_character":31},"updated":"2016-05-27 12:52:42.000000000","message":"missing docs","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"3903a7813750454c5786313b34e8887ee830388f","unresolved":false,"context_lines":[{"line_number":44,"context_line":"    return role \u003d\u003d get_role_from_capabilities_string(capabilities)"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"class CreateNodeRolePatchAction(base.TripleOAction):"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":"    def __init__(self, node, role):"},{"line_number":50,"context_line":"        super(CreateNodeRolePatchAction, self).__init__()"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_4a44a973","line":47,"range":{"start_line":47,"start_character":6,"end_line":47,"end_character":31},"in_reply_to":"9abb7d3a_641d660f","updated":"2016-05-27 13:09:53.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":59,"context_line":"            capabilities \u003d re.sub(ROLE_RE, \u0027profile:{}\u0027.format(self.role),"},{"line_number":60,"context_line":"                                  capabilities)"},{"line_number":61,"context_line":"        else:"},{"line_number":62,"context_line":"            if capabilities:"},{"line_number":63,"context_line":"                capabilities +\u003d \u0027,profile:{}\u0027.format(self.role)"},{"line_number":64,"context_line":"            else:"},{"line_number":65,"context_line":"                capabilities \u003d \u0027profile:{}\u0027.format(self.role)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        return [{"},{"line_number":68,"context_line":"            \"op\": \"replace\","}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_8a7cd121","line":65,"range":{"start_line":62,"start_character":12,"end_line":65,"end_character":61},"updated":"2016-05-27 13:07:28.000000000","message":"please use https://github.com/openstack/python-tripleoclient/blob/master/tripleoclient/utils.py#L633-L637","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"1f54f5561fdfdf6d3867ebedd0b93b3ac0afbfad","unresolved":false,"context_lines":[{"line_number":59,"context_line":"            capabilities \u003d re.sub(ROLE_RE, \u0027profile:{}\u0027.format(self.role),"},{"line_number":60,"context_line":"                                  capabilities)"},{"line_number":61,"context_line":"        else:"},{"line_number":62,"context_line":"            if capabilities:"},{"line_number":63,"context_line":"                capabilities +\u003d \u0027,profile:{}\u0027.format(self.role)"},{"line_number":64,"context_line":"            else:"},{"line_number":65,"context_line":"                capabilities \u003d \u0027profile:{}\u0027.format(self.role)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        return [{"},{"line_number":68,"context_line":"            \"op\": \"replace\","}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_40e6ca44","line":65,"range":{"start_line":62,"start_character":12,"end_line":65,"end_character":61},"in_reply_to":"9abb7d3a_8a7cd121","updated":"2016-05-31 14:12:39.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":64,"context_line":"            else:"},{"line_number":65,"context_line":"                capabilities \u003d \u0027profile:{}\u0027.format(self.role)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        return [{"},{"line_number":68,"context_line":"            \"op\": \"replace\","},{"line_number":69,"context_line":"            \"path\": \"/properties/capabilities\","},{"line_number":70,"context_line":"            \"value\": capabilities"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_e4e156d2","line":67,"range":{"start_line":67,"start_character":15,"end_line":67,"end_character":17},"updated":"2016-05-27 12:52:42.000000000","message":"is the list necessary here for a specific reason?","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"1f54f5561fdfdf6d3867ebedd0b93b3ac0afbfad","unresolved":false,"context_lines":[{"line_number":64,"context_line":"            else:"},{"line_number":65,"context_line":"                capabilities \u003d \u0027profile:{}\u0027.format(self.role)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        return [{"},{"line_number":68,"context_line":"            \"op\": \"replace\","},{"line_number":69,"context_line":"            \"path\": \"/properties/capabilities\","},{"line_number":70,"context_line":"            \"value\": capabilities"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_80d2725a","line":67,"range":{"start_line":67,"start_character":15,"end_line":67,"end_character":17},"in_reply_to":"9abb7d3a_0a8f4124","updated":"2016-05-31 14:12:39.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":64,"context_line":"            else:"},{"line_number":65,"context_line":"                capabilities \u003d \u0027profile:{}\u0027.format(self.role)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"        return [{"},{"line_number":68,"context_line":"            \"op\": \"replace\","},{"line_number":69,"context_line":"            \"path\": \"/properties/capabilities\","},{"line_number":70,"context_line":"            \"value\": capabilities"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_0a8f4124","line":67,"range":{"start_line":67,"start_character":15,"end_line":67,"end_character":17},"in_reply_to":"9abb7d3a_e4e156d2","updated":"2016-05-27 13:07:28.000000000","message":"yeah, it\u0027s expected by ironic","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":71,"context_line":"        }]"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"class GetLowestHardwareNodeAction(base.TripleOAction):"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def __init__(self, nodes, role):"},{"line_number":77,"context_line":"        super(GetLowestHardwareNodeAction, self).__init__()"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_e4d79621","line":74,"range":{"start_line":74,"start_character":6,"end_line":74,"end_character":33},"updated":"2016-05-27 12:52:42.000000000","message":"missing docs","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"3903a7813750454c5786313b34e8887ee830388f","unresolved":false,"context_lines":[{"line_number":71,"context_line":"        }]"},{"line_number":72,"context_line":""},{"line_number":73,"context_line":""},{"line_number":74,"context_line":"class GetLowestHardwareNodeAction(base.TripleOAction):"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def __init__(self, nodes, role):"},{"line_number":77,"context_line":"        super(GetLowestHardwareNodeAction, self).__init__()"}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_0a31010c","line":74,"range":{"start_line":74,"start_character":6,"end_line":74,"end_character":33},"in_reply_to":"9abb7d3a_e4d79621","updated":"2016-05-27 13:09:53.000000000","message":"Done","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"660e6d17d2f2c53bb8876ecffb8f236bd3ad753c","unresolved":false,"context_lines":[{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def _get_role_from_capabilities_string(capabilities):"},{"line_number":27,"context_line":"    capabilities \u003d capabilities_to_dict(capabilities)"},{"line_number":28,"context_line":"    return capabilities.get(\u0027profile\u0027, None)"},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_78728c12","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":38},"updated":"2016-06-01 03:05:18.000000000","message":"Is this method really necessary anymore?  Please see comment in node_has_role.","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"b193effb4729cf7111515145dd8cff7f0dcaf055","unresolved":false,"context_lines":[{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def _get_role_from_capabilities_string(capabilities):"},{"line_number":27,"context_line":"    capabilities \u003d capabilities_to_dict(capabilities)"},{"line_number":28,"context_line":"    return capabilities.get(\u0027profile\u0027, None)"},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_e76186d4","line":26,"range":{"start_line":26,"start_character":4,"end_line":26,"end_character":38},"in_reply_to":"9abb7d3a_78728c12","updated":"2016-06-01 18:21:59.000000000","message":"Done","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"660e6d17d2f2c53bb8876ecffb8f236bd3ad753c","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    return capabilities.get(\u0027profile\u0027, None)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"def _minimal_hardware_spec_reducer(a, b):"},{"line_number":32,"context_line":"    # NOTE(hpokorny): This is a very simplistic algorithm."},{"line_number":33,"context_line":"    # How can we improve it?"},{"line_number":34,"context_line":"    if a[\u0027properties\u0027][\u0027memory_mb\u0027] \u003e b[\u0027properties\u0027][\u0027memory_mb\u0027]:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_d832980f","line":31,"range":{"start_line":31,"start_character":4,"end_line":31,"end_character":34},"updated":"2016-06-01 03:05:18.000000000","message":"Could this method be replaced by max?\n\nhttps://docs.python.org/2/library/functions.html#max","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"b193effb4729cf7111515145dd8cff7f0dcaf055","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    return capabilities.get(\u0027profile\u0027, None)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"def _minimal_hardware_spec_reducer(a, b):"},{"line_number":32,"context_line":"    # NOTE(hpokorny): This is a very simplistic algorithm."},{"line_number":33,"context_line":"    # How can we improve it?"},{"line_number":34,"context_line":"    if a[\u0027properties\u0027][\u0027memory_mb\u0027] \u003e b[\u0027properties\u0027][\u0027memory_mb\u0027]:"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_c7b8c213","line":31,"range":{"start_line":31,"start_character":4,"end_line":31,"end_character":34},"in_reply_to":"9abb7d3a_d832980f","updated":"2016-06-01 18:21:59.000000000","message":"I used the reduce here because I figured there would be a more complex business logic here to determine which node is the weakest of the bunch.  Presumably, we want to take into account cpu count, disk space, etc.","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"660e6d17d2f2c53bb8876ecffb8f236bd3ad753c","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"def node_has_role(role, node):"},{"line_number":41,"context_line":"    capabilities \u003d node[\u0027properties\u0027].get(\u0027capabilities\u0027, None)"},{"line_number":42,"context_line":"    return role \u003d\u003d _get_role_from_capabilities_string(capabilities)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"class CreateNodeRolePatchAction(base.TripleOAction):"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_f8eafc72","line":42,"range":{"start_line":42,"start_character":11,"end_line":42,"end_character":15},"updated":"2016-06-01 03:05:18.000000000","message":"The _get_role_from_capabilities_string method calls capabilities_to_dict.  Could we just shorten that to:\n\nreturn role \u003d\u003d capabilities_to_dict(capabilities).get(\u0027profile\u0027, None)","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"b193effb4729cf7111515145dd8cff7f0dcaf055","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"def node_has_role(role, node):"},{"line_number":41,"context_line":"    capabilities \u003d node[\u0027properties\u0027].get(\u0027capabilities\u0027, None)"},{"line_number":42,"context_line":"    return role \u003d\u003d _get_role_from_capabilities_string(capabilities)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"class CreateNodeRolePatchAction(base.TripleOAction):"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_e7b8662c","line":42,"range":{"start_line":42,"start_character":11,"end_line":42,"end_character":15},"in_reply_to":"9abb7d3a_f8eafc72","updated":"2016-06-01 18:21:59.000000000","message":"Done","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"660e6d17d2f2c53bb8876ecffb8f236bd3ad753c","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    def run(self):"},{"line_number":94,"context_line":"        filter_role \u003d functools.partial(node_has_role, self.role)"},{"line_number":95,"context_line":"        nodes \u003d filter(filter_role, self.nodes)"},{"line_number":96,"context_line":"        return functools.reduce(_minimal_hardware_spec_reducer, nodes)"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_3cf62ff9","line":96,"range":{"start_line":96,"start_character":64,"end_line":96,"end_character":69},"updated":"2016-06-01 03:05:18.000000000","message":"Is there a chance that nodes will ever be passed as an empty list?  I get a TypeError here if nodes \u003d\u003d [].  To capture the error in the output, you would need to use the mistral.workflows.utils.Result class.","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"b193effb4729cf7111515145dd8cff7f0dcaf055","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    def run(self):"},{"line_number":94,"context_line":"        filter_role \u003d functools.partial(node_has_role, self.role)"},{"line_number":95,"context_line":"        nodes \u003d filter(filter_role, self.nodes)"},{"line_number":96,"context_line":"        return functools.reduce(_minimal_hardware_spec_reducer, nodes)"}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_07880a70","line":96,"range":{"start_line":96,"start_character":64,"end_line":96,"end_character":69},"in_reply_to":"9abb7d3a_3cf62ff9","updated":"2016-06-01 18:21:59.000000000","message":"Done","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":9712,"name":"Dougal Matthews","email":"dougal.matthews@canonical.com","username":"dougal"},"change_message_id":"01a628010ccf74252d78c9374dfa1e1c8b238c92","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from tripleo_common.actions import base"},{"line_number":19,"context_line":"from tripleo_common.utils.nodes import capabilities_to_dict"},{"line_number":20,"context_line":"from tripleo_common.utils.nodes import dict_to_capabilities"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_b3a0eea6","line":20,"updated":"2016-06-03 13:13:07.000000000","message":"nit: Hacking really wants us to import modules only, not functions. The fact that it doesn\u0027t complain here is probably a bug. I personally don\u0027t care much for that rule, so I\u0027d be happy for it to stay like this ;-)","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":9712,"name":"Dougal Matthews","email":"dougal.matthews@canonical.com","username":"dougal"},"change_message_id":"01a628010ccf74252d78c9374dfa1e1c8b238c92","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    :param node: The node to update"},{"line_number":32,"context_line":"    :param role: The new role for the node"},{"line_number":33,"context_line":"    :returns: list"},{"line_number":34,"context_line":"    :returns: JSON patch list"},{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_13773a3c","line":33,"updated":"2016-06-03 13:13:07.000000000","message":"Why do we return a single item list? Would it make more sense to just return a dict? I guess I am missing something here.","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"2bef6689618fb2427947b8685d2588fb9ddb3829","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    :param node: The node to update"},{"line_number":32,"context_line":"    :param role: The new role for the node"},{"line_number":33,"context_line":"    :returns: list"},{"line_number":34,"context_line":"    :returns: JSON patch list"},{"line_number":35,"context_line":"    \"\"\""},{"line_number":36,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_025b65f7","line":33,"in_reply_to":"9abb7d3a_13773a3c","updated":"2016-06-03 13:19:55.000000000","message":"This was pointed out and answered previously in the review. This is the correct JSON patch format, and ironic expects it. Maybe I will add a comment.","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"9a51d9f319e5ca7da7ca2e410edcc79961e9631e","unresolved":false,"context_lines":[{"line_number":39,"context_line":"        self.role \u003d role"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def run(self):"},{"line_number":42,"context_line":"        capabilities \u003d self.node[\u0027properties\u0027].get(\u0027capabilities\u0027, None)"},{"line_number":43,"context_line":"        capabilities_dict \u003d nodes.capabilities_to_dict(capabilities)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"        capabilities_dict[\u0027profile\u0027] \u003d self.role"}],"source_content_type":"text/x-python","patch_set":15,"id":"7aa08908_93c29083","line":42,"range":{"start_line":42,"start_character":65,"end_line":42,"end_character":71},"updated":"2016-06-08 15:46:28.000000000","message":"nit: \",None\" is redundant","commit_id":"2bda41a99ccc03f562b972bf3cf3bbc70fa130e4"}],"tripleo_common/tests/actions/test_nodes.py":[{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"2bdf3b6c8e0dad1a8d3a41f1b86ca0fae7633732","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        self.assertEqual(\u0027option:true,profile:compute\u0027, result[0][\u0027value\u0027])"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"class GetLowestHardwareNodeActionTest(base.TestCase):"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    def test_run(self):"},{"line_number":57,"context_line":"        node_list \u003d ["}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_47ab048a","line":54,"range":{"start_line":54,"start_character":6,"end_line":54,"end_character":37},"updated":"2016-05-27 12:52:42.000000000","message":"missing setUp method.  Following the chain of calls down to oslotest there is a setting set in that method.","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"3903a7813750454c5786313b34e8887ee830388f","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        self.assertEqual(\u0027option:true,profile:compute\u0027, result[0][\u0027value\u0027])"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"class GetLowestHardwareNodeActionTest(base.TestCase):"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    def test_run(self):"},{"line_number":57,"context_line":"        node_list \u003d ["}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_aa2c35ac","line":54,"range":{"start_line":54,"start_character":6,"end_line":54,"end_character":37},"in_reply_to":"9abb7d3a_47ab048a","updated":"2016-05-27 13:09:53.000000000","message":"Why have the setUp here if I\u0027m not overriding anything?","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"e13199bd9676d74a5d17033254794a9f473c1f17","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        self.assertEqual(\u0027option:true,profile:compute\u0027, result[0][\u0027value\u0027])"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"class GetLowestHardwareNodeActionTest(base.TestCase):"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"    def test_run(self):"},{"line_number":57,"context_line":"        node_list \u003d ["}],"source_content_type":"text/x-python","patch_set":4,"id":"9abb7d3a_db6229ad","line":54,"range":{"start_line":54,"start_character":6,"end_line":54,"end_character":37},"in_reply_to":"9abb7d3a_aa2c35ac","updated":"2016-05-27 13:49:09.000000000","message":"You\u0027re right.  Maybe remove the other instance of setup then?","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"660e6d17d2f2c53bb8876ecffb8f236bd3ad753c","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        self.assertTrue(\u0027profile:compute\u0027 in result[0][\u0027value\u0027])"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"class GetLowestHardwareNodeActionTest(base.TestCase):"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def test_run(self):"},{"line_number":54,"context_line":"        node_list \u003d ["}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_5cc853a8","line":51,"range":{"start_line":51,"start_character":6,"end_line":51,"end_character":37},"updated":"2016-06-01 03:05:18.000000000","message":"soft: if you edit the GetLowestHardwareNodeAction to handle the empty node list case, add the unit test here testing for that condition.","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"b193effb4729cf7111515145dd8cff7f0dcaf055","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        self.assertTrue(\u0027profile:compute\u0027 in result[0][\u0027value\u0027])"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"class GetLowestHardwareNodeActionTest(base.TestCase):"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def test_run(self):"},{"line_number":54,"context_line":"        node_list \u003d ["}],"source_content_type":"text/x-python","patch_set":10,"id":"9abb7d3a_87499a33","line":51,"range":{"start_line":51,"start_character":6,"end_line":51,"end_character":37},"in_reply_to":"9abb7d3a_5cc853a8","updated":"2016-06-01 18:21:59.000000000","message":"Done","commit_id":"575766bbe603fed62c5c4492ff98fe02fead8604"}],"tripleo_common/utils/nodes.py":[{"author":{"_account_id":9712,"name":"Dougal Matthews","email":"dougal.matthews@canonical.com","username":"dougal"},"change_message_id":"01a628010ccf74252d78c9374dfa1e1c8b238c92","unresolved":false,"context_lines":[{"line_number":518,"context_line":"    \"\"\"Convert the Node\u0027s capabilities into a dictionary.\"\"\""},{"line_number":519,"context_line":"    if not caps:"},{"line_number":520,"context_line":"        return {}"},{"line_number":521,"context_line":"    return dict([key.split(\u0027:\u0027, 1) for key in caps.split(\u0027,\u0027)])"},{"line_number":522,"context_line":""},{"line_number":523,"context_line":""},{"line_number":524,"context_line":"def dict_to_capabilities(caps_dict):"}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_13729ae3","line":521,"updated":"2016-06-03 13:13:07.000000000","message":"nit: the square brackets are redundant.","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"2bef6689618fb2427947b8685d2588fb9ddb3829","unresolved":false,"context_lines":[{"line_number":518,"context_line":"    \"\"\"Convert the Node\u0027s capabilities into a dictionary.\"\"\""},{"line_number":519,"context_line":"    if not caps:"},{"line_number":520,"context_line":"        return {}"},{"line_number":521,"context_line":"    return dict([key.split(\u0027:\u0027, 1) for key in caps.split(\u0027,\u0027)])"},{"line_number":522,"context_line":""},{"line_number":523,"context_line":""},{"line_number":524,"context_line":"def dict_to_capabilities(caps_dict):"}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_e22bc131","line":521,"in_reply_to":"9abb7d3a_13729ae3","updated":"2016-06-03 13:19:55.000000000","message":"This is a copy and paste job from tripleoclient. https://github.com/openstack/python-tripleoclient/blob/master/tripleoclient/utils.py#L631","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":9712,"name":"Dougal Matthews","email":"dougal.matthews@canonical.com","username":"dougal"},"change_message_id":"01a628010ccf74252d78c9374dfa1e1c8b238c92","unresolved":false,"context_lines":[{"line_number":523,"context_line":""},{"line_number":524,"context_line":"def dict_to_capabilities(caps_dict):"},{"line_number":525,"context_line":"    \"\"\"Convert a dictionary into a string with the capabilities syntax.\"\"\""},{"line_number":526,"context_line":"    return \u0027,\u0027.join([\"%s:%s\" % (key, value)"},{"line_number":527,"context_line":"                     for key, value in caps_dict.items()"},{"line_number":528,"context_line":"                     if value is not None])"}],"source_content_type":"text/x-python","patch_set":13,"id":"9abb7d3a_934cca9e","line":526,"updated":"2016-06-03 13:13:07.000000000","message":"nit: as above.","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"}],"workbooks/baremetal.yaml":[{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"6a096cfa09be77842bb8357542d9ad4e378896b4","unresolved":false,"context_lines":[{"line_number":193,"context_line":"              data:"},{"line_number":194,"context_line":"                status: SUCCESS"},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"  assign_node:"},{"line_number":197,"context_line":"    type: direct"},{"line_number":198,"context_line":"    input:"},{"line_number":199,"context_line":"      - node_id"}],"source_content_type":"text/x-yaml","patch_set":1,"id":"bab6814e_27ba25c1","line":196,"range":{"start_line":196,"start_character":2,"end_line":196,"end_character":13},"updated":"2016-05-24 13:52:15.000000000","message":"maybe you could add a comment above like the other workflows to describe what this workflow is for?","commit_id":"36ed5782443a796d507e605d78b8634cf572d053"},{"author":{"_account_id":8532,"name":"Ryan Brady","email":"rbrady@redhat.com","username":"rbrady"},"change_message_id":"6a096cfa09be77842bb8357542d9ad4e378896b4","unresolved":false,"context_lines":[{"line_number":209,"context_line":""},{"line_number":210,"context_line":"      get_role_name:"},{"line_number":211,"context_line":"        on-success: get_flavor"},{"line_number":212,"context_line":"        action: tripleo.get_node_role node\u003d\u003c% $.node %\u003e"},{"line_number":213,"context_line":"        publish:"},{"line_number":214,"context_line":"          role: \u003c% task(get_role_name).result %\u003e"},{"line_number":215,"context_line":""}],"source_content_type":"text/x-yaml","patch_set":1,"id":"bab6814e_8798316c","line":212,"range":{"start_line":212,"start_character":24,"end_line":212,"end_character":37},"updated":"2016-05-24 13:52:15.000000000","message":"missing the action and setup.cfg changes o this patch?","commit_id":"36ed5782443a796d507e605d78b8634cf572d053"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":217,"context_line":"        publish:"},{"line_number":218,"context_line":"          node: \u003c% task(get_node).result %\u003e"},{"line_number":219,"context_line":""},{"line_number":220,"context_line":"      get_node_patch:"},{"line_number":221,"context_line":"        on-success: update_node"},{"line_number":222,"context_line":"        action: tripleo.create_node_role_patch node\u003d\u003c% $.node %\u003e role\u003d\u003c% $.role_name %\u003e"},{"line_number":223,"context_line":"        publish:"},{"line_number":224,"context_line":"          patch: \u003c% task(get_node_patch).result %\u003e"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"      update_node:"},{"line_number":227,"context_line":"        on-success: get_nodes"},{"line_number":228,"context_line":"        action: ironic.node_update node_id\u003d\u003c% $.node_id %\u003e patch\u003d\u003c% $.patch %\u003e"},{"line_number":229,"context_line":"        publish:"},{"line_number":230,"context_line":"          node: \u003c% task(update_node).result %\u003e"},{"line_number":231,"context_line":""},{"line_number":232,"context_line":"      get_nodes:"},{"line_number":233,"context_line":"        on-success: get_lowest_node"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"9abb7d3a_0ac74113","line":230,"range":{"start_line":220,"start_character":0,"end_line":230,"end_character":46},"updated":"2016-05-27 13:07:28.000000000","message":"I\u0027d prefer this being encapsulated into something like update_node_capabilities name\u003dprofile value\u003d\u003c% $.role_name %\u003e","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"173b45708c073cdc26dfbb702037706859891c8a","unresolved":false,"context_lines":[{"line_number":241,"context_line":"        publish:"},{"line_number":242,"context_line":"          lowest_node: \u003c% task(get_lowest_node).result %\u003e"},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"      get_flavor:"},{"line_number":245,"context_line":"        on-success: delete_flavor"},{"line_number":246,"context_line":"        action: nova.flavors_find name\u003d\u003c% $.role_name %\u003e"},{"line_number":247,"context_line":"        publish:"},{"line_number":248,"context_line":"          flavor: \u003c% task(get_flavor).result %\u003e"},{"line_number":249,"context_line":""},{"line_number":250,"context_line":"      delete_flavor:"},{"line_number":251,"context_line":"        on-success: create_flavor"},{"line_number":252,"context_line":"        action: nova.flavors_delete flavor\u003d\u003c% $.flavor.id %\u003e"},{"line_number":253,"context_line":""},{"line_number":254,"context_line":"      create_flavor:"},{"line_number":255,"context_line":"        on-success: send_message"},{"line_number":256,"context_line":"        action: nova.flavors_create name\u003d\u003c% $.role_name %\u003e ram\u003d\u003c% $.lowest_node.properties.memory_mb %\u003e vcpus\u003d\u003c% $.lowest_node.properties.cpus %\u003e disk\u003d\u003c% $.lowest_node.properties.local_gb %\u003e"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"      send_message:"},{"line_number":259,"context_line":"        action: zaqar.queue_post"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"9abb7d3a_ea7d9de8","line":256,"range":{"start_line":244,"start_character":0,"end_line":256,"end_character":190},"updated":"2016-05-27 13:07:28.000000000","message":"we should really expose flavor updating and use it here","commit_id":"6978dd6ab24bdc071890c9530f002f69658944d0"},{"author":{"_account_id":360,"name":"Dan Prince","email":"dprince@redhat.com","username":"dan-prince"},"change_message_id":"fc6247cf83e02c2593922cfa4a3b29179cf15888","unresolved":false,"context_lines":[{"line_number":236,"context_line":"          nodes: \u003c% task(get_nodes).result %\u003e"},{"line_number":237,"context_line":""},{"line_number":238,"context_line":"      get_lowest_node:"},{"line_number":239,"context_line":"        on-success: get_flavor"},{"line_number":240,"context_line":"        action: tripleo.get_lowest_hardware_node nodes\u003d\u003c% $.nodes %\u003e role\u003d\u003c% $.role_name %\u003e"},{"line_number":241,"context_line":"        publish:"},{"line_number":242,"context_line":"          lowest_node: \u003c% task(get_lowest_node).result %\u003e"}],"source_content_type":"text/x-yaml","patch_set":7,"id":"9abb7d3a_f1da9277","line":239,"updated":"2016-05-28 11:29:49.000000000","message":"On any of these tasks (but just using this one as an example) I think we\u0027ll want to have on-error: conditions set too such that a Zaqar message with a status FAILURE is sent back.\n\nIn cases where a more meaningful error is needed you may need specific tasks for this. Or you could just use task_defaults: and create one error handler for all of them.\n\nThe goal is to notify the Zaqar queue regardless of success or error. Rbrady about potentially adding a few new Mistral features to make managing and defaulting to this type of Zaqar queue error handling nicer, but I think we\u0027ve got what we need to proceed for now.","commit_id":"5c5f9d6f798462dcaaa382235d746cb69a336afb"},{"author":{"_account_id":9712,"name":"Dougal Matthews","email":"dougal.matthews@canonical.com","username":"dougal"},"change_message_id":"01a628010ccf74252d78c9374dfa1e1c8b238c92","unresolved":false,"context_lines":[{"line_number":270,"context_line":""},{"line_number":271,"context_line":"  # assign_node workflow:"},{"line_number":272,"context_line":"  #"},{"line_number":273,"context_line":"  # Given a node_id and a role_name (compute, swift-storage, etc),"},{"line_number":274,"context_line":"  # 1.  Retrieve the node\u0027s details using ironic"},{"line_number":275,"context_line":"  # 2.  Create a JSON patch object to update the node\u0027s capabilities"},{"line_number":276,"context_line":"  # 3.  Update the node with the new capabilities"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"9abb7d3a_626871bb","line":273,"updated":"2016-06-03 13:13:07.000000000","message":"What happens if the role_name is invalid?","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"},{"author":{"_account_id":20970,"name":"Honza Pokorny","email":"honza@redhat.com","username":"hpokorny"},"change_message_id":"2bef6689618fb2427947b8685d2588fb9ddb3829","unresolved":false,"context_lines":[{"line_number":270,"context_line":""},{"line_number":271,"context_line":"  # assign_node workflow:"},{"line_number":272,"context_line":"  #"},{"line_number":273,"context_line":"  # Given a node_id and a role_name (compute, swift-storage, etc),"},{"line_number":274,"context_line":"  # 1.  Retrieve the node\u0027s details using ironic"},{"line_number":275,"context_line":"  # 2.  Create a JSON patch object to update the node\u0027s capabilities"},{"line_number":276,"context_line":"  # 3.  Update the node with the new capabilities"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"9abb7d3a_e2b581d0","line":273,"in_reply_to":"9abb7d3a_626871bb","updated":"2016-06-03 13:19:55.000000000","message":"It\u0027ll be inserted as is.  This is the current behavior of the GUI.  The JS client creates the JSON patch in the same manner.","commit_id":"d74596cd8b66e4f0da1b170511dd8874ecfc38d2"}]}
