)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"de0e2d15464671b610c0c40657e6841300ace305","unresolved":false,"context_lines":[{"line_number":16,"context_line":"* Display logical disk properties for a driver using"},{"line_number":17,"context_line":"  driver-raid-logical-disk-properties."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"NOTE: Client still defaults to version 1.6, so"},{"line_number":20,"context_line":"\u0027--ironic-api-version 1.12\u0027 (or above) should be added to"},{"line_number":21,"context_line":"the CLI to use the feature."},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"da6ed579_7377cb3a","line":19,"updated":"2016-01-13 03:23:12.000000000","message":"nit: default is 1.9","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":16,"context_line":"* Display logical disk properties for a driver using"},{"line_number":17,"context_line":"  driver-raid-logical-disk-properties."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"NOTE: Client still defaults to version 1.6, so"},{"line_number":20,"context_line":"\u0027--ironic-api-version 1.12\u0027 (or above) should be added to"},{"line_number":21,"context_line":"the CLI to use the feature."},{"line_number":22,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"9a68dd71_82332bf6","line":19,"in_reply_to":"da6ed579_7377cb3a","updated":"2016-01-26 19:19:27.000000000","message":"Ok","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"de0e2d15464671b610c0c40657e6841300ace305","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Implements: blueprint ironic-generic-raid-interface"},{"line_number":25,"context_line":"Depends-On: I0e34407133684e34c4ab9446b3521a24f3038f92"},{"line_number":26,"context_line":"Change-Id: Id7bb8a242838029e4cc3715d18b27fb1d5cd4dfa"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"da6ed579_d378f72d","line":25,"updated":"2016-01-13 03:23:12.000000000","message":"Wonder why do you depend on manual clean API?","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Implements: blueprint ironic-generic-raid-interface"},{"line_number":25,"context_line":"Depends-On: I0e34407133684e34c4ab9446b3521a24f3038f92"},{"line_number":26,"context_line":"Change-Id: Id7bb8a242838029e4cc3715d18b27fb1d5cd4dfa"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"9a68dd71_a230afe9","line":25,"in_reply_to":"da6ed579_d378f72d","updated":"2016-01-26 19:19:27.000000000","message":"RAID feature itself depends on manual clean.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"2e25c370b84dfeca5299dd1e0e21bae3b50bef3b","unresolved":false,"context_lines":[{"line_number":21,"context_line":"the CLI to use the feature."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Implements: blueprint ironic-generic-raid-interface"},{"line_number":25,"context_line":"Depends-On: I0e34407133684e34c4ab9446b3521a24f3038f92"},{"line_number":26,"context_line":"Change-Id: Id7bb8a242838029e4cc3715d18b27fb1d5cd4dfa"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"7af24918_19ecbcc6","line":24,"updated":"2016-03-01 13:45:03.000000000","message":"we no longer use blueprints","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"2e25c370b84dfeca5299dd1e0e21bae3b50bef3b","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Implements: blueprint ironic-generic-raid-interface"},{"line_number":25,"context_line":"Depends-On: I0e34407133684e34c4ab9446b3521a24f3038f92"},{"line_number":26,"context_line":"Change-Id: Id7bb8a242838029e4cc3715d18b27fb1d5cd4dfa"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":10,"id":"7af24918_79d180fb","line":25,"updated":"2016-03-01 13:45:03.000000000","message":"nit: dependency can be removed","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"d24503377030b4211a6823933f802a5651d66c8a","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"NOTE: Client still defaults to version 1.9, so"},{"line_number":20,"context_line":"\u0027--ironic-api-version 1.12\u0027 (or above) should be added to"},{"line_number":21,"context_line":"the CLI to use the feature."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Closes_bug: 1526400"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"7af24918_2808d290","line":21,"updated":"2016-03-02 20:09:30.000000000","message":"I wonder if we should just use 1.15 (or whatever manual clean is) because even though you can get/set the RAID config info here, you can\u0027t do anything with it w/o manual clean. (Which you could mention here.)","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"f9c30cbff5aaf15b2ba9822b4156f2428655b4ca","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"NOTE: Client still defaults to version 1.9, so"},{"line_number":20,"context_line":"\u0027--ironic-api-version 1.12\u0027 (or above) should be added to"},{"line_number":21,"context_line":"the CLI to use the feature."},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Co-Authored-By: Nisha Agarwal \u003cagarwalnisha1980@gmail.com\u003e"},{"line_number":24,"context_line":"Closes_bug: 1526400"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":11,"id":"7af24918_652dca94","line":21,"in_reply_to":"7af24918_2808d290","updated":"2016-03-03 05:31:37.000000000","message":"Ok.","commit_id":"46c374ff301d55776f67572135a53f9488398888"}],"ironicclient/tests/unit/v1/test_driver_shell.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":138,"context_line":"        print_dict_mock.assert_called_with("},{"line_number":139,"context_line":"            {\u0027foo\u0027: \u0027bar\u0027},"},{"line_number":140,"context_line":"            dict_value\u003d\u0027Description\u0027,"},{"line_number":141,"context_line":"            wrap\u003d80)"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    def test_do_driver_show(self):"},{"line_number":144,"context_line":"        client_mock \u003d self.client_mock"}],"source_content_type":"text/x-python","patch_set":13,"id":"7af24918_dd661250","line":141,"updated":"2016-03-03 17:02:09.000000000","message":"we could have just had an internal function to do the above two, where the wrap value is passed as an argument. Oh well.","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"}],"ironicclient/tests/unit/v1/test_node.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":800,"context_line":""},{"line_number":801,"context_line":"    def test_set_target_raid_config(self):"},{"line_number":802,"context_line":"        self.mgr.set_target_raid_config("},{"line_number":803,"context_line":"            NODE1[\u0027uuid\u0027], \"raid-config-file-name\")"},{"line_number":804,"context_line":""},{"line_number":805,"context_line":"        expect \u003d [(\u0027PUT\u0027, \u0027/v1/nodes/%s/states/raid\u0027 % NODE1[\u0027uuid\u0027],"},{"line_number":806,"context_line":"                  {},"}],"source_content_type":"text/x-python","patch_set":13,"id":"7af24918_7d8b7ec3","line":803,"updated":"2016-03-03 17:02:09.000000000","message":"that isn\u0027t true. Maybe s/file-name/dictionary/ ?","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"}],"ironicclient/tests/unit/v1/test_node_shell.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":369,"context_line":"        mock_file_object.read.return_value \u003d target_raid_config_string"},{"line_number":370,"context_line":""},{"line_number":371,"context_line":"        args \u003d mock.MagicMock(node\u003d\u0027node\u0027,"},{"line_number":372,"context_line":"                              target_raid_config\u003dtarget_raid_config_string)"},{"line_number":373,"context_line":"        n_shell.do_node_set_target_raid_config(client_mock, args)"},{"line_number":374,"context_line":""},{"line_number":375,"context_line":"        node_manager_mock.set_target_raid_config.assert_called_once_with("}],"source_content_type":"text/x-python","patch_set":13,"id":"7af24918_d1a719bb","line":372,"updated":"2016-03-03 17:02:09.000000000","message":"I\u0027m not convinced that this test actually tests a file with the config info. Isn\u0027t this setting the target raid config from a string?","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":386,"context_line":"        mock_file_object.read.side_effect \u003d IOError"},{"line_number":387,"context_line":"        target_raid_config_string \u003d \u0027bad\u0027"},{"line_number":388,"context_line":"        args \u003d mock.MagicMock(node\u003d\u0027node\u0027,"},{"line_number":389,"context_line":"                              target_raid_config\u003dtarget_raid_config_string)"},{"line_number":390,"context_line":"        self.assertRaises(exc.InvalidAttribute,"},{"line_number":391,"context_line":"                          n_shell.do_node_set_target_raid_config,"},{"line_number":392,"context_line":"                          client_mock, args)"}],"source_content_type":"text/x-python","patch_set":13,"id":"7af24918_f1a215ad","line":389,"updated":"2016-03-03 17:02:09.000000000","message":"I\u0027m not convinced that this test actually tests a file with the config info. Isn\u0027t this setting the target raid config from a string?","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"}],"ironicclient/v1/driver.py":[{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"5d9c96884c947e0087d012dc955fecb142bbcc66","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        if info:"},{"line_number":62,"context_line":"            return info.to_dict()"},{"line_number":63,"context_line":"        return {}"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    def vendor_passthru(self, driver_name, method, args\u003dNone,"},{"line_number":66,"context_line":"                        http_method\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa69d971_f2cb0ea2","line":63,"updated":"2016-01-07 02:46:54.000000000","message":"Not sure users will understand the meaning of empty dictionary. Should we give more hints or info about the error? \nOr not use _list(), simply run self.get(\u0027/v1/drivers/%s/raid/logical_disk_properties\u0027 % driver_name).to_dict() and will return the error to user.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":60,"context_line":""},{"line_number":61,"context_line":"        if info:"},{"line_number":62,"context_line":"            return info.to_dict()"},{"line_number":63,"context_line":"        return {}"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"    def vendor_passthru(self, driver_name, method, args\u003dNone,"},{"line_number":66,"context_line":"                        http_method\u003dNone):"}],"source_content_type":"text/x-python","patch_set":6,"id":"9a68dd71_8f4d94c6","line":63,"in_reply_to":"fa69d971_f2cb0ea2","updated":"2016-01-26 19:19:27.000000000","message":"Thanks for teh comment Tan Lin. But the suggestion doesnt work, while teh existing code works well.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"abbbe9e0982e14acf998225a44514889f38174ee","unresolved":false,"context_lines":[{"line_number":49,"context_line":"        :param driver_name: Name of the driver."},{"line_number":50,"context_line":"        :returns: A dictionary containing the properties that can be mentioned"},{"line_number":51,"context_line":"            for RAID logical disks and a textual description for them. It"},{"line_number":52,"context_line":"            returns an empty dictionary on error."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        info \u003d None"},{"line_number":55,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a5de9d1_755d7de8","line":52,"updated":"2016-01-28 09:53:02.000000000","message":"still have a concern about the error handling","commit_id":"f069ff8830653b371eebcb61c2d6c5cda18dce1a"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"6b1dd3d8b94aa6d9f6c7988d5e1014a5935a2267","unresolved":false,"context_lines":[{"line_number":49,"context_line":"        :param driver_name: Name of the driver."},{"line_number":50,"context_line":"        :returns: A dictionary containing the properties that can be mentioned"},{"line_number":51,"context_line":"            for RAID logical disks and a textual description for them. It"},{"line_number":52,"context_line":"            returns an empty dictionary on error."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        info \u003d None"},{"line_number":55,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a5de9d1_7c492430","line":52,"in_reply_to":"7a5de9d1_755d7de8","updated":"2016-02-02 08:43:50.000000000","message":"It returns empty dictionary only for the drivers who do not support raid. So that looks fine. \nThis command anyway just gives the information about the keys to be included when creating the target_raid_config.\nI dont see an issue in this.","commit_id":"f069ff8830653b371eebcb61c2d6c5cda18dce1a"}],"ironicclient/v1/driver_shell.py":[{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"5d9c96884c947e0087d012dc955fecb142bbcc66","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        obj_list.append(type(\u0027iface\u0027, (object,), data))"},{"line_number":74,"context_line":"    fields \u003d [\u0027Property\u0027, \u0027Description\u0027]"},{"line_number":75,"context_line":"    cliutils.print_list(obj_list, fields, mixed_case_fields\u003dfields)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"@cliutils.arg(\u0027driver_name\u0027,"},{"line_number":79,"context_line":"              metavar\u003d\u0027\u003cdriver\u003e\u0027,"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa69d971_2f661f51","line":76,"updated":"2016-01-07 02:46:54.000000000","message":"from L70-75 can be replaced by one command\ncliutils.print_dict(disk_properties, wrap\u003d72, dict_value\u003d\u0027Description\u0027)","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":73,"context_line":"        obj_list.append(type(\u0027iface\u0027, (object,), data))"},{"line_number":74,"context_line":"    fields \u003d [\u0027Property\u0027, \u0027Description\u0027]"},{"line_number":75,"context_line":"    cliutils.print_list(obj_list, fields, mixed_case_fields\u003dfields)"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":""},{"line_number":78,"context_line":"@cliutils.arg(\u0027driver_name\u0027,"},{"line_number":79,"context_line":"              metavar\u003d\u0027\u003cdriver\u003e\u0027,"}],"source_content_type":"text/x-python","patch_set":6,"id":"9a68dd71_ef73f0e5","line":76,"in_reply_to":"fa69d971_2f661f51","updated":"2016-01-26 19:19:27.000000000","message":"Thanks for teh comment. The suggestion doesnt work, plus i dontsee any issue with the suggested code.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"2e25c370b84dfeca5299dd1e0e21bae3b50bef3b","unresolved":false,"context_lines":[{"line_number":70,"context_line":"    obj_list \u003d []"},{"line_number":71,"context_line":"    for key, value in properties.items():"},{"line_number":72,"context_line":"        data \u003d {\u0027Property\u0027: key, \u0027Description\u0027: value}"},{"line_number":73,"context_line":"        obj_list.append(type(\u0027iface\u0027, (object,), data))"},{"line_number":74,"context_line":"    fields \u003d [\u0027Property\u0027, \u0027Description\u0027]"},{"line_number":75,"context_line":"    cliutils.print_list(obj_list, fields, mixed_case_fields\u003dfields)"},{"line_number":76,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_59ce445b","line":73,"updated":"2016-03-01 13:45:03.000000000","message":"please create a namedtuple instead","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"f3959bbc215dab33455b3ff4195f2736444e07bb","unresolved":false,"context_lines":[{"line_number":70,"context_line":"    obj_list \u003d []"},{"line_number":71,"context_line":"    for key, value in properties.items():"},{"line_number":72,"context_line":"        data \u003d {\u0027Property\u0027: key, \u0027Description\u0027: value}"},{"line_number":73,"context_line":"        obj_list.append(type(\u0027iface\u0027, (object,), data))"},{"line_number":74,"context_line":"    fields \u003d [\u0027Property\u0027, \u0027Description\u0027]"},{"line_number":75,"context_line":"    cliutils.print_list(obj_list, fields, mixed_case_fields\u003dfields)"},{"line_number":76,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_b003eb72","line":73,"in_reply_to":"7af24918_59ce445b","updated":"2016-03-02 02:54:55.000000000","message":"I still think use print_dict is a better approach for readable","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"}],"ironicclient/v1/node.py":[{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"5d9c96884c947e0087d012dc955fecb142bbcc66","unresolved":false,"context_lines":[{"line_number":284,"context_line":"                with open(target_raid_config_file, \u0027r\u0027) as f:"},{"line_number":285,"context_line":"                    target_raid_config \u003d f.read()"},{"line_number":286,"context_line":"            except Exception:"},{"line_number":287,"context_line":"                target_raid_config \u003d None"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":"        if not target_raid_config:"},{"line_number":290,"context_line":"            raise exc.InvalidAttribute("}],"source_content_type":"text/x-python","patch_set":6,"id":"fa69d971_0f155b9a","line":287,"updated":"2016-01-07 02:46:54.000000000","message":"It is possible for user to pass a simple target_raid_config json directly which only include necessary infos, like {\"logical_disks\": [{\u0027arg1\u0027: \u0027val1\u0027, \u0027raid_level\u0027: \u00272\u0027}]}\n\nRight now it has to be a file or \u0027-\u0027","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":284,"context_line":"                with open(target_raid_config_file, \u0027r\u0027) as f:"},{"line_number":285,"context_line":"                    target_raid_config \u003d f.read()"},{"line_number":286,"context_line":"            except Exception:"},{"line_number":287,"context_line":"                target_raid_config \u003d None"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":"        if not target_raid_config:"},{"line_number":290,"context_line":"            raise exc.InvalidAttribute("}],"source_content_type":"text/x-python","patch_set":6,"id":"9a68dd71_2f3fc8d7","line":287,"in_reply_to":"fa69d971_0f155b9a","updated":"2016-01-26 19:19:27.000000000","message":"If this has to be supported, it can be done as a seperate patch.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"ec6ed9284d0c4d8d4ef1ecde83ce1987364eb88e","unresolved":false,"context_lines":[{"line_number":255,"context_line":"        target \u003d {\u0027target\u0027: _power_states.get(state, state)}"},{"line_number":256,"context_line":"        return self.update(path, target, http_method\u003d\u0027PUT\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def set_target_raid_config(self, node_ident, target_raid_config_file\u003dNone):"},{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_478944ca","line":258,"updated":"2016-03-01 11:47:26.000000000","message":"Is it possible to the \"target_raid_config_file\" to be None? It feels like this parameter shouldn\u0027t have a default value.\n\n...\n\nAlso, by looking at the node_shell.py it seems that it\u0027s passing a dictionary object to this parameter (the JSON was loaded already, which I agree with). So this parameter shouldn\u0027t have *_file in the name? \n\nSame comment applies to the docstring, it should mention that this parameter expects a dictionary","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"15cfc365d3fab7b59f7c7f3551a34b4f7c929142","unresolved":false,"context_lines":[{"line_number":255,"context_line":"        target \u003d {\u0027target\u0027: _power_states.get(state, state)}"},{"line_number":256,"context_line":"        return self.update(path, target, http_method\u003d\u0027PUT\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def set_target_raid_config(self, node_ident, target_raid_config_file\u003dNone):"},{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_88b6b83b","line":258,"in_reply_to":"7af24918_33227aba","updated":"2016-03-01 13:00:27.000000000","message":"Not at this layer Nisha. The node_shell.py is the module that does convert the file or standard output to a dictionary.\n\nThis module does not, if someone open a python terminal and import the ironicclient library and call set_target_raid_config() passing a file to it, it won\u0027t work.\n\n...\n\nThink that we have 2 ways of using the ironicclient project, you either use the CLI (node_shell.py) or you use it as a library to create your own script (which this file is part of).\n\nAnd the CLI uses the library.","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"6c232f6fc1464c25c790691c0721bf279bf0e3fe","unresolved":false,"context_lines":[{"line_number":255,"context_line":"        target \u003d {\u0027target\u0027: _power_states.get(state, state)}"},{"line_number":256,"context_line":"        return self.update(path, target, http_method\u003d\u0027PUT\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def set_target_raid_config(self, node_ident, target_raid_config_file\u003dNone):"},{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_33227aba","line":258,"in_reply_to":"7af24918_478944ca","updated":"2016-03-01 12:40:52.000000000","message":"No the comment is not true, it accepts file as an input. It can accept input from file and the standard input which should be in dictionary form.","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"f3959bbc215dab33455b3ff4195f2736444e07bb","unresolved":false,"context_lines":[{"line_number":255,"context_line":"        target \u003d {\u0027target\u0027: _power_states.get(state, state)}"},{"line_number":256,"context_line":"        return self.update(path, target, http_method\u003d\u0027PUT\u0027)"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def set_target_raid_config(self, node_ident, target_raid_config_file\u003dNone):"},{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_1073bf81","line":258,"in_reply_to":"7af24918_88b6b83b","updated":"2016-03-02 02:54:55.000000000","message":"Agree, This is also why Ruby and Jim asked the updates in patch set 8. I think this is already a common agreement.","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"},{"line_number":262,"context_line":"        a file or from stdin and then sets this on node.target_raid_config."},{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        :param node_ident: Node identifier"},{"line_number":265,"context_line":"        :param target_raid_config: The target RAID configuration in"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_482d5e45","line":262,"updated":"2016-03-02 20:06:02.000000000","message":"Don\u0027t think this is true","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":259,"context_line":"        \"\"\"Sets target_raid_config for a node."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        This method reads the target raid configuration from either"},{"line_number":262,"context_line":"        a file or from stdin and then sets this on node.target_raid_config."},{"line_number":263,"context_line":""},{"line_number":264,"context_line":"        :param node_ident: Node identifier"},{"line_number":265,"context_line":"        :param target_raid_config: The target RAID configuration in"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_2202980b","line":262,"in_reply_to":"7af24918_482d5e45","updated":"2016-03-03 05:18:28.000000000","message":"hmm. the code moved to node_shell.py. i will remove this from here.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":266,"context_line":"            JSON form or an empty dictionary."},{"line_number":267,"context_line":"        :returns: status of the request"},{"line_number":268,"context_line":"        :raises: InvalidAttribute, if target RAID configuration cannot be"},{"line_number":269,"context_line":"            read from a file or it\u0027s not a proper JSON."},{"line_number":270,"context_line":"        \"\"\""},{"line_number":271,"context_line":"        path \u003d \"%s/states/raid\" % node_ident"},{"line_number":272,"context_line":"        return self.update(path, target_raid_config, http_method\u003d\u0027PUT\u0027)"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_48d43e1f","line":269,"updated":"2016-03-02 20:06:02.000000000","message":"don\u0027t think this is true either","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":266,"context_line":"            JSON form or an empty dictionary."},{"line_number":267,"context_line":"        :returns: status of the request"},{"line_number":268,"context_line":"        :raises: InvalidAttribute, if target RAID configuration cannot be"},{"line_number":269,"context_line":"            read from a file or it\u0027s not a proper JSON."},{"line_number":270,"context_line":"        \"\"\""},{"line_number":271,"context_line":"        path \u003d \"%s/states/raid\" % node_ident"},{"line_number":272,"context_line":"        return self.update(path, target_raid_config, http_method\u003d\u0027PUT\u0027)"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_65066a1e","line":269,"in_reply_to":"7af24918_48d43e1f","updated":"2016-03-03 05:18:28.000000000","message":"ditto","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":260,"context_line":""},{"line_number":261,"context_line":"        :param node_ident: Node identifier"},{"line_number":262,"context_line":"        :param target_raid_config: The target RAID configuration in"},{"line_number":263,"context_line":"            JSON form or an empty dictionary."},{"line_number":264,"context_line":"        :returns: status of the request"},{"line_number":265,"context_line":"        \"\"\""},{"line_number":266,"context_line":"        path \u003d \"%s/states/raid\" % node_ident"}],"source_content_type":"text/x-python","patch_set":13,"id":"7af24918_9d2aca8e","line":263,"updated":"2016-03-03 17:02:09.000000000","message":"is it JSON or a dictionary?","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"}],"ironicclient/v1/node_shell.py":[{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"5d9c96884c947e0087d012dc955fecb142bbcc66","unresolved":false,"context_lines":[{"line_number":381,"context_line":"    \u0027target_raid_config\u0027,"},{"line_number":382,"context_line":"    metavar\u003d\u0027\u003ctarget-raid-config\u003e\u0027,"},{"line_number":383,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":384,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input.\"))"},{"line_number":385,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":386,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":387,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"}],"source_content_type":"text/x-python","patch_set":6,"id":"fa69d971_92de52db","line":384,"updated":"2016-01-07 02:46:54.000000000","message":"This can also be empty to unset the previous one.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"bff10c50fa16473959074e3fecd9c630633cb099","unresolved":false,"context_lines":[{"line_number":381,"context_line":"    \u0027target_raid_config\u0027,"},{"line_number":382,"context_line":"    metavar\u003d\u0027\u003ctarget-raid-config\u003e\u0027,"},{"line_number":383,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":384,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input.\"))"},{"line_number":385,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":386,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":387,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"}],"source_content_type":"text/x-python","patch_set":6,"id":"9a68dd71_c2128358","line":384,"in_reply_to":"fa69d971_92de52db","updated":"2016-01-26 19:19:27.000000000","message":"No It will fail with:\nReceived invalid target RAID configuration\n while trying to read from \u0027-\u0027.","commit_id":"68bb41b9fc9472356df10a763b089ee13c3803b6"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"abbbe9e0982e14acf998225a44514889f38174ee","unresolved":false,"context_lines":[{"line_number":381,"context_line":"    \u0027target_raid_config\u0027,"},{"line_number":382,"context_line":"    metavar\u003d\u0027\u003ctarget-raid-config\u003e\u0027,"},{"line_number":383,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":384,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input.\"))"},{"line_number":385,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":386,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":387,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a5de9d1_d54b1158","line":384,"updated":"2016-01-28 09:53:02.000000000","message":"Ironic-api support unset the previous target_raid config using {}, https://github.com/openstack/ironic/blob/master/ironic/api/controllers/v1/node.py#L339-L340\nIt\u0027s fine that you don\u0027t support this in the function, but you need a function to let user unset the target_raid_config.","commit_id":"f069ff8830653b371eebcb61c2d6c5cda18dce1a"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"6b1dd3d8b94aa6d9f6c7988d5e1014a5935a2267","unresolved":false,"context_lines":[{"line_number":381,"context_line":"    \u0027target_raid_config\u0027,"},{"line_number":382,"context_line":"    metavar\u003d\u0027\u003ctarget-raid-config\u003e\u0027,"},{"line_number":383,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":384,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input.\"))"},{"line_number":385,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":386,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":387,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"}],"source_content_type":"text/x-python","patch_set":7,"id":"7a5de9d1_a1fc5372","line":384,"in_reply_to":"7a5de9d1_d54b1158","updated":"2016-02-02 08:43:50.000000000","message":"TanLin, thanks for pointing this out, i validated the empty dictionary works and clears the target raid configuration.","commit_id":"f069ff8830653b371eebcb61c2d6c5cda18dce1a"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a9dca945a82fd81a80a2778df2edf35b54a47c37","unresolved":false,"context_lines":[{"line_number":386,"context_line":"          \"clears off the current target_raid_config on the node.\"))"},{"line_number":387,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":388,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":389,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"},{"line_number":390,"context_line":""},{"line_number":391,"context_line":""},{"line_number":392,"context_line":"@cliutils.arg(\u0027node\u0027, metavar\u003d\u0027\u003cnode\u003e\u0027, help\u003d\"Name or UUID of the node.\")"}],"source_content_type":"text/x-python","patch_set":8,"id":"9aed3d3a_17263aba","line":389,"updated":"2016-02-25 22:05:52.000000000","message":"So if you look at the code that handles cleaning, the handling of file and stdin is done at this level, not at the node.py level. I think we should do a similar thing here.\n\nAlthough I don\u0027t know if the target_raid_config is more similar to the cleaning steps or the config_drive info (which is handled in node.py).","commit_id":"f26366b002018f45f66474e050ac620742755f84"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"dcfc4169ec2c3709f127235d7b7029344d7ac747","unresolved":false,"context_lines":[{"line_number":386,"context_line":"          \"clears off the current target_raid_config on the node.\"))"},{"line_number":387,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":388,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":389,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"},{"line_number":390,"context_line":""},{"line_number":391,"context_line":""},{"line_number":392,"context_line":"@cliutils.arg(\u0027node\u0027, metavar\u003d\u0027\u003cnode\u003e\u0027, help\u003d\"Name or UUID of the node.\")"}],"source_content_type":"text/x-python","patch_set":8,"id":"9aed3d3a_17375ab1","line":389,"in_reply_to":"9aed3d3a_17263aba","updated":"2016-02-25 22:11:11.000000000","message":"+1, I\u0027d prefer to do it at this level.","commit_id":"f26366b002018f45f66474e050ac620742755f84"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"ed60375298892c2505b4086da3fee9f4ef95adf3","unresolved":false,"context_lines":[{"line_number":386,"context_line":"          \"clears off the current target_raid_config on the node.\"))"},{"line_number":387,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":388,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":389,"context_line":"    cc.node.set_target_raid_config(args.node, args.target_raid_config)"},{"line_number":390,"context_line":""},{"line_number":391,"context_line":""},{"line_number":392,"context_line":"@cliutils.arg(\u0027node\u0027, metavar\u003d\u0027\u003cnode\u003e\u0027, help\u003d\"Name or UUID of the node.\")"}],"source_content_type":"text/x-python","patch_set":8,"id":"9aed3d3a_9d48a42f","line":389,"in_reply_to":"9aed3d3a_17375ab1","updated":"2016-02-26 01:46:49.000000000","message":"+1 too","commit_id":"f26366b002018f45f66474e050ac620742755f84"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a9dca945a82fd81a80a2778df2edf35b54a47c37","unresolved":false,"context_lines":[{"line_number":405,"context_line":"          \"to the configuration drive file OR the path to a directory \""},{"line_number":406,"context_line":"          \"containing the config drive files. In case it\u0027s a directory, a \""},{"line_number":407,"context_line":"          \"config drive will be generated from it. This parameter is only \""},{"line_number":408,"context_line":"          \"valid when setting provision state to \u0027active\u0027.\"))"},{"line_number":409,"context_line":"def do_node_set_provision_state(cc, args):"},{"line_number":410,"context_line":"    \"\"\"Initiate a provisioning state change for a node.\"\"\""},{"line_number":411,"context_line":"    if args.config_drive and args.provision_state !\u003d \u0027active\u0027:"}],"source_content_type":"text/x-python","patch_set":8,"id":"9aed3d3a_d4817091","line":408,"updated":"2016-02-25 22:05:52.000000000","message":"this is odd. you are missing the manual clean changes from https://review.openstack.org/#/c/251995/ (which this patch depends on).\n\nI\u0027m surprised Jenkins doesn\u0027t say that this needs to be rebased.","commit_id":"f26366b002018f45f66474e050ac620742755f84"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"2e25c370b84dfeca5299dd1e0e21bae3b50bef3b","unresolved":false,"context_lines":[{"line_number":439,"context_line":"        except Exception:"},{"line_number":440,"context_line":"            target_raid_config \u003d None"},{"line_number":441,"context_line":"    else:"},{"line_number":442,"context_line":"        # Read from file."},{"line_number":443,"context_line":"        try:"},{"line_number":444,"context_line":"            with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":445,"context_line":"                target_raid_config \u003d f.read()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_b9db081b","line":442,"updated":"2016-03-01 13:45:03.000000000","message":"+1, see cleaning for example","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"ec6ed9284d0c4d8d4ef1ecde83ce1987364eb88e","unresolved":false,"context_lines":[{"line_number":439,"context_line":"        except Exception:"},{"line_number":440,"context_line":"            target_raid_config \u003d None"},{"line_number":441,"context_line":"    else:"},{"line_number":442,"context_line":"        # Read from file."},{"line_number":443,"context_line":"        try:"},{"line_number":444,"context_line":"            with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":445,"context_line":"                target_raid_config \u003d f.read()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_52f904c8","line":442,"updated":"2016-03-01 11:47:26.000000000","message":"I feel like we should also accept to pass the raid config in a JSON format (same as manual cleaning). Not only file or stdin.\n\ne.g\n\n if target_raid_config \u003d\u003d \u0027-\u0027:\n     ... get from stdin ...\n\n if os.path.isfile(target_raid_config):\n     ... read from the file ...\n\n ...\n\n try:\n     target_raid_config \u003d json.loads(target_raid_config) \n except ValueError:\n     ...","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"808bc59627e1979b90f812bcd3dc5b84b04f4b65","unresolved":false,"context_lines":[{"line_number":439,"context_line":"        except Exception:"},{"line_number":440,"context_line":"            target_raid_config \u003d None"},{"line_number":441,"context_line":"    else:"},{"line_number":442,"context_line":"        # Read from file."},{"line_number":443,"context_line":"        try:"},{"line_number":444,"context_line":"            with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":445,"context_line":"                target_raid_config \u003d f.read()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_a54bdd58","line":442,"in_reply_to":"7af24918_52f904c8","updated":"2016-03-01 12:42:57.000000000","message":"then it will require an option to be added.","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"15cfc365d3fab7b59f7c7f3551a34b4f7c929142","unresolved":false,"context_lines":[{"line_number":439,"context_line":"        except Exception:"},{"line_number":440,"context_line":"            target_raid_config \u003d None"},{"line_number":441,"context_line":"    else:"},{"line_number":442,"context_line":"        # Read from file."},{"line_number":443,"context_line":"        try:"},{"line_number":444,"context_line":"            with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":445,"context_line":"                target_raid_config \u003d f.read()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_68c40c92","line":442,"in_reply_to":"7af24918_a54bdd58","updated":"2016-03-01 13:00:27.000000000","message":"Why?\n\nIt\u0027s the same as the manual cleaning see L494","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":13362,"name":"Tan Lin","email":"lin.tan@intel.com","username":"zero"},"change_message_id":"f3959bbc215dab33455b3ff4195f2736444e07bb","unresolved":false,"context_lines":[{"line_number":439,"context_line":"        except Exception:"},{"line_number":440,"context_line":"            target_raid_config \u003d None"},{"line_number":441,"context_line":"    else:"},{"line_number":442,"context_line":"        # Read from file."},{"line_number":443,"context_line":"        try:"},{"line_number":444,"context_line":"            with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":445,"context_line":"                target_raid_config \u003d f.read()"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_d082f7ff","line":442,"in_reply_to":"7af24918_b9db081b","updated":"2016-03-02 02:54:55.000000000","message":"+1 I asked the same question in patch set 6 :) It\u0027s better to implement this in one patch.","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"15cfc365d3fab7b59f7c7f3551a34b4f7c929142","unresolved":false,"context_lines":[{"line_number":491,"context_line":"          \"a list of clean-step dictionaries; each dictionary should have \""},{"line_number":492,"context_line":"          \"keys \u0027interface\u0027 and \u0027step\u0027, and optional key \u0027args\u0027. \""},{"line_number":493,"context_line":"          \"This argument must be specified (and is only valid) when \""},{"line_number":494,"context_line":"          \"setting provision-state to \u0027clean\u0027.\"))"},{"line_number":495,"context_line":"def do_node_set_provision_state(cc, args):"},{"line_number":496,"context_line":"    \"\"\"Initiate a provisioning state change for a node.\"\"\""},{"line_number":497,"context_line":"    if args.config_drive and args.provision_state !\u003d \u0027active\u0027:"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af24918_a85574c7","line":494,"updated":"2016-03-01 13:00:27.000000000","message":"See manual cleaning","commit_id":"58e168b0184632c220b82a813838c7da4370c5d4"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":429,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":430,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input. \""},{"line_number":431,"context_line":"          \"The file/standard input can be an empty dictionary too which \""},{"line_number":432,"context_line":"          \"unsets the target_raid_config on the node.\"))"},{"line_number":433,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":434,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":435,"context_line":"    target_raid_config \u003d args.target_raid_config"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_a864e2e4","line":432,"updated":"2016-03-02 20:06:02.000000000","message":"How about \u0027If the contents is an empty dictionary, it unsets the node\u0027s target_raid_config\u0027.\n\nWhat does it mean to unset it? No RAID is applied?","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":429,"context_line":"    help\u003d(\"A file containing JSON data of the desired RAID configuration. \""},{"line_number":430,"context_line":"          \"Use \u0027-\u0027 to read the contents from standard input. \""},{"line_number":431,"context_line":"          \"The file/standard input can be an empty dictionary too which \""},{"line_number":432,"context_line":"          \"unsets the target_raid_config on the node.\"))"},{"line_number":433,"context_line":"def do_node_set_target_raid_config(cc, args):"},{"line_number":434,"context_line":"    \"\"\"Set target RAID config on a node.\"\"\""},{"line_number":435,"context_line":"    target_raid_config \u003d args.target_raid_config"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_62f5c055","line":432,"in_reply_to":"7af24918_a864e2e4","updated":"2016-03-03 05:18:28.000000000","message":"Looks better. Will change it as suggested.\n\nFor second ques:\nwe apply node.target_raid_config using this method. \nlets assume user had set the value of node.target_raid_config which is a valid json and non-empty json. SO the node.target_raid_config shows some value.\nNow suppose user feels that the node.target_raid_config needs to be changed or he doesnt want to run RAID on that node, he can choose to clear the node.target_raid_config.\nTo achieve above, user can issue following command line:\n\nironic --ironic-api-version latest node-set-provision-state $NODE \u0027{}\u0027\n\nThis will be shown as :\n| target_raid_config     | {}         |\n\nin node-show.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":446,"context_line":"                    target_raid_config \u003d f.read()"},{"line_number":447,"context_line":"            except Exception:"},{"line_number":448,"context_line":"                target_raid_config \u003d None"},{"line_number":449,"context_line":"    if target_raid_config is not None:"},{"line_number":450,"context_line":"        try:"},{"line_number":451,"context_line":"            target_raid_config \u003d json.loads(target_raid_config)"},{"line_number":452,"context_line":"        except ValueError:"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_28d45245","line":449,"updated":"2016-03-02 20:06:02.000000000","message":"You are also allowing the user to specify the actual target raid config too? Should you? (You can get here even if target-raid-config is not \u0027-\u0027 or a file, but the help doesn\u0027t indicate this.)","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":446,"context_line":"                    target_raid_config \u003d f.read()"},{"line_number":447,"context_line":"            except Exception:"},{"line_number":448,"context_line":"                target_raid_config \u003d None"},{"line_number":449,"context_line":"    if target_raid_config is not None:"},{"line_number":450,"context_line":"        try:"},{"line_number":451,"context_line":"            target_raid_config \u003d json.loads(target_raid_config)"},{"line_number":452,"context_line":"        except ValueError:"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_028cbcd8","line":449,"in_reply_to":"7af24918_28d45245","updated":"2016-03-03 05:18:28.000000000","message":"yes that was a comment in previous patch. i will update the help message.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":452,"context_line":"        except ValueError:"},{"line_number":453,"context_line":"            raise exc.InvalidAttribute("},{"line_number":454,"context_line":"                _(\"Received invalid target RAID configuration \""},{"line_number":455,"context_line":"                  \"%(target_raid_config)s .\") %"},{"line_number":456,"context_line":"                {\u0027target_raid_config\u0027: target_raid_config})"},{"line_number":457,"context_line":"    else:"},{"line_number":458,"context_line":"        raise exc.InvalidAttribute("}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_685c9aed","line":455,"updated":"2016-03-02 20:06:02.000000000","message":"unnecessary space before the period.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":452,"context_line":"        except ValueError:"},{"line_number":453,"context_line":"            raise exc.InvalidAttribute("},{"line_number":454,"context_line":"                _(\"Received invalid target RAID configuration \""},{"line_number":455,"context_line":"                  \"%(target_raid_config)s .\") %"},{"line_number":456,"context_line":"                {\u0027target_raid_config\u0027: target_raid_config})"},{"line_number":457,"context_line":"    else:"},{"line_number":458,"context_line":"        raise exc.InvalidAttribute("}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_e288b0c7","line":455,"in_reply_to":"7af24918_685c9aed","updated":"2016-03-03 05:18:28.000000000","message":":)","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"ad9cbf6a8b2ddf21e3a1b590578516bdef41c78d","unresolved":false,"context_lines":[{"line_number":438,"context_line":"    if target_raid_config \u003d\u003d \u0027-\u0027:"},{"line_number":439,"context_line":"        try:"},{"line_number":440,"context_line":"            target_raid_config \u003d _get_from_stdin(\u0027target_raid_config\u0027)"},{"line_number":441,"context_line":"        except Exception:"},{"line_number":442,"context_line":"            target_raid_config \u003d None"},{"line_number":443,"context_line":"    else:"},{"line_number":444,"context_line":"        if os.path.isfile(target_raid_config):"}],"source_content_type":"text/x-python","patch_set":12,"id":"7af24918_cd24bc61","line":441,"updated":"2016-03-03 09:49:10.000000000","message":"This try...except can be removed, _get_from_stdin() is raising an exception telling the user that we couldn\u0027t read the RAID configuration from stdin.\n\nOtherwise we omit this error and then we are going to return from L460 saying \"target RAID configuration not provided\" when it was provided.","commit_id":"b62c03c3ed7f1f9625a5f37babeab89617b03430"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"ad9cbf6a8b2ddf21e3a1b590578516bdef41c78d","unresolved":false,"context_lines":[{"line_number":446,"context_line":"            try:"},{"line_number":447,"context_line":"                with open(target_raid_config, \u0027r\u0027) as f:"},{"line_number":448,"context_line":"                    target_raid_config \u003d f.read()"},{"line_number":449,"context_line":"            except Exception:"},{"line_number":450,"context_line":"                target_raid_config \u003d None"},{"line_number":451,"context_line":"    if target_raid_config is not None:"},{"line_number":452,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":12,"id":"7af24918_edcd3886","line":449,"updated":"2016-03-03 09:49:10.000000000","message":"ditto, we should tell the user why we couldn\u0027t read from the file.\n\nWe could refactor the _handle_clean_steps_arg() function to handle the raid config as well.","commit_id":"b62c03c3ed7f1f9625a5f37babeab89617b03430"}],"ironicclient/v1/resource_fields.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":162,"context_line":"        \u0027driver_internal_info\u0027,"},{"line_number":163,"context_line":"        \u0027extra\u0027,"},{"line_number":164,"context_line":"        \u0027instance_info\u0027,"},{"line_number":165,"context_line":"        \u0027properties\u0027,"},{"line_number":166,"context_line":"    ])"},{"line_number":167,"context_line":"NODE_RESOURCE \u003d Resource("},{"line_number":168,"context_line":"    [\u0027uuid\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_65ba0370","line":165,"updated":"2016-03-02 20:06:02.000000000","message":"Shouldn\u0027t we add raid_config \u0026 target_raid_config here? I don\u0027t think it makes sense to sort on those fields.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":162,"context_line":"        \u0027driver_internal_info\u0027,"},{"line_number":163,"context_line":"        \u0027extra\u0027,"},{"line_number":164,"context_line":"        \u0027instance_info\u0027,"},{"line_number":165,"context_line":"        \u0027properties\u0027,"},{"line_number":166,"context_line":"    ])"},{"line_number":167,"context_line":"NODE_RESOURCE \u003d Resource("},{"line_number":168,"context_line":"    [\u0027uuid\u0027,"}],"source_content_type":"text/x-python","patch_set":11,"id":"7af24918_e25d5048","line":165,"in_reply_to":"7af24918_65ba0370","updated":"2016-03-03 05:18:28.000000000","message":"Ok will add them here too.","commit_id":"46c374ff301d55776f67572135a53f9488398888"}],"releasenotes/notes/raid_CLI_support-7e816ccd0fb31d2b.yaml":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    This patch enables RAID functionality."},{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - The ironic-client support for RAID functionality."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"7af24918_05833f99","line":3,"updated":"2016-03-02 20:06:02.000000000","message":"I\u0027m not sure what the prelude part is; I suspect this isn\u0027t needed here but maybe someone else knows.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    This patch enables RAID functionality."},{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - The ironic-client support for RAID functionality."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"7af24918_422ec4a5","line":3,"in_reply_to":"7af24918_05833f99","updated":"2016-03-03 05:18:28.000000000","message":"The prelude text showed that we can add text for the features in prelude section hence i kept that section.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e871bbd3186a938aa41700736508eccef4870b9b","unresolved":false,"context_lines":[{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    This patch enables RAID functionality."},{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - The ironic-client support for RAID functionality."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"7af24918_2803b20e","line":5,"updated":"2016-03-02 20:06:02.000000000","message":"I think it makes sense to mention what ironic API version is useful with this. I\u0027d also like more details, sort of what is in the commit msg. eg, the actual ironic CLIs, new node fields.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":11297,"name":"Nisha Agarwal","email":"agarwalnisha1980@gmail.com","username":"Nisha"},"change_message_id":"92d578638e9915892bfa7a6b25d4d2ccea807d21","unresolved":false,"context_lines":[{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    This patch enables RAID functionality."},{"line_number":4,"context_line":"features:"},{"line_number":5,"context_line":"  - The ironic-client support for RAID functionality."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"7af24918_02283c99","line":5,"in_reply_to":"7af24918_2803b20e","updated":"2016-03-03 05:18:28.000000000","message":"Ok.","commit_id":"46c374ff301d55776f67572135a53f9488398888"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fd02de6df521fe1b8afbb49a780cbc6d3e137bc8","unresolved":false,"context_lines":[{"line_number":12,"context_line":"    * Displays logical disk properties for a driver using"},{"line_number":13,"context_line":"      driver-raid-logical-disk-properties."},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"    API version 1.15 should be used with this features, as"},{"line_number":16,"context_line":"    RAID configuration was added in 1.12 and manual cleaning"},{"line_number":17,"context_line":"    (used to trigger RAID configuration) was added in 1.15."}],"source_content_type":"text/x-yaml","patch_set":13,"id":"7af24918_d6f42f5c","line":15,"updated":"2016-03-03 17:02:09.000000000","message":"s/this/these/","commit_id":"b978b078c2393f37f85967387787d9d5477eda99"}]}
