)]}'
{"etc/ironic/ironic.conf.sample":[{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":2511,"context_line":"# enable_periodic_tasks\u003dTrue. (integer value)"},{"line_number":2512,"context_line":"#periodic_check_interval \u003d 300"},{"line_number":2513,"context_line":""},{"line_number":2514,"context_line":"[openbmc]"},{"line_number":2515,"context_line":"#"},{"line_number":2516,"context_line":"# From ironic"},{"line_number":2517,"context_line":"#"}],"source_content_type":"application/octet-stream","patch_set":6,"id":"1f485f77_f1468f7c","line":2514,"updated":"2017-11-14 21:40:54.000000000","message":"So where is this coming from?\n\nI would assume there is some file in ironic/config/ that is setting this. But I don\u0027t see one.","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":2511,"context_line":"# enable_periodic_tasks\u003dTrue. (integer value)"},{"line_number":2512,"context_line":"#periodic_check_interval \u003d 300"},{"line_number":2513,"context_line":""},{"line_number":2514,"context_line":"[openbmc]"},{"line_number":2515,"context_line":"#"},{"line_number":2516,"context_line":"# From ironic"},{"line_number":2517,"context_line":"#"}],"source_content_type":"application/octet-stream","patch_set":6,"id":"1f485f77_847276e2","line":2514,"in_reply_to":"1f485f77_f1468f7c","updated":"2017-11-15 01:49:45.000000000","message":"+1","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":2512,"context_line":"#periodic_check_interval \u003d 300"},{"line_number":2513,"context_line":""},{"line_number":2514,"context_line":"[openbmc]"},{"line_number":2515,"context_line":"#"},{"line_number":2516,"context_line":"# From ironic"},{"line_number":2517,"context_line":"#"},{"line_number":2518,"context_line":""},{"line_number":2519,"context_line":"# Retry timeout for power functions. TODO(mjturek): better description"},{"line_number":2520,"context_line":"#retry_timeout \u003d 60"}],"source_content_type":"application/octet-stream","patch_set":6,"id":"1f485f77_845b9652","line":2517,"range":{"start_line":2515,"start_character":0,"end_line":2517,"end_character":1},"updated":"2017-11-15 01:49:45.000000000","message":"Do we need add information from Ironic when ironic.conf","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"}],"ironic/conf/openbmc.py":[{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":23,"context_line":"opts \u003d ["},{"line_number":24,"context_line":"    cfg.IntOpt(\u0027retry_timeout\u0027,"},{"line_number":25,"context_line":"               default\u003d60,"},{"line_number":26,"context_line":"               help\u003d_(\u0027Max time to wait for changing power state in seconds\u0027)),"},{"line_number":27,"context_line":"]"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_ddef1b1c","line":26,"range":{"start_line":26,"start_character":1,"end_line":26,"end_character":79},"updated":"2017-09-14 11:17:37.000000000","message":"Need to re-generate ironic.conf.sample.","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"}],"ironic/drivers/agent.py":[{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"29e94a197f934d1d445d072b89d72095d68475bc","unresolved":false,"context_lines":[{"line_number":88,"context_line":"    TODO: Description of driver"},{"line_number":89,"context_line":"    \"\"\""},{"line_number":90,"context_line":""},{"line_number":91,"context_line":"    supported \u003d False"},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"    def __init__(self):"},{"line_number":94,"context_line":"        self.power \u003d openbmc_power.OpenBMCPower()"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_a04e3b35","line":91,"range":{"start_line":91,"start_character":4,"end_line":91,"end_character":21},"updated":"2017-09-15 23:47:34.000000000","message":"not sure the purpose of this, can we have a comment here?","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"}],"ironic/drivers/modules/openbmc/common.py":[{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"29e94a197f934d1d445d072b89d72095d68475bc","unresolved":false,"context_lines":[{"line_number":38,"context_line":"import requests"},{"line_number":39,"context_line":"import six.moves.urllib.parse as urlparse"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"from ironic.common import exception"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"# Sadly a way to fit the line into 78 characters mainly"},{"line_number":44,"context_line":"JSON_HEADERS \u003d {\"Content-Type\": \"application/json\"}"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_603df38d","line":41,"range":{"start_line":41,"start_character":0,"end_line":41,"end_character":35},"updated":"2017-09-15 23:47:34.000000000","message":"nit: not related? I think this should be above as it was, because we include the modules alphabetically.","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":54,"context_line":""},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"def parse_driver_info(node):"},{"line_number":57,"context_line":"    \"\"\"Gets the parameters required to login to OpenBMC, as well as node UUID"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"    :param node: the Node of interest."},{"line_number":60,"context_line":"    :returns: dict of parameters required to login to OpenBMC."}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_e7848c0e","line":57,"range":{"start_line":57,"start_character":6,"end_line":57,"end_character":77},"updated":"2017-11-15 01:49:45.000000000","message":"We don\u0027t need to specify where this function used because it it commmon funtions. \n/s /\"\"\"Gets the driver specific Node info. /","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"}],"ironic/drivers/modules/openbmc/management.py":[{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":37,"context_line":"}"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"def _get_boot_device(driver_info, request_info):"},{"line_number":41,"context_line":"    obmc \u003d openbmc_common.OpenBMC(hostname\u003ddriver_info[\u0027openbmc_address\u0027],"},{"line_number":42,"context_line":"                                  user\u003ddriver_info[\u0027openbmc_username\u0027],"},{"line_number":43,"context_line":"                                  password\u003ddriver_info[\u0027openbmc_password\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_4c09dddc","line":40,"range":{"start_line":40,"start_character":34,"end_line":40,"end_character":46},"updated":"2017-03-09 06:59:27.000000000","message":"Arg \u0027request_info\u0027 is not used.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":37,"context_line":"}"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"def _get_boot_device(driver_info, request_info):"},{"line_number":41,"context_line":"    obmc \u003d openbmc_common.OpenBMC(hostname\u003ddriver_info[\u0027openbmc_address\u0027],"},{"line_number":42,"context_line":"                                  user\u003ddriver_info[\u0027openbmc_username\u0027],"},{"line_number":43,"context_line":"                                  password\u003ddriver_info[\u0027openbmc_password\u0027])"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_ccf85bc6","line":40,"range":{"start_line":40,"start_character":34,"end_line":40,"end_character":46},"in_reply_to":"9a30ddce_4c09dddc","updated":"2017-03-09 15:37:15.000000000","message":"Done","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    @METRICS.timer(\u0027OpenBMCMangement.get_boot_device\u0027)"},{"line_number":69,"context_line":"    def get_boot_device(self, task):"},{"line_number":70,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":71,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":72,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027presistent\u0027: False}"},{"line_number":73,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":74,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_4c30fd9e","line":71,"range":{"start_line":71,"start_character":22,"end_line":71,"end_character":51},"updated":"2017-03-09 06:59:27.000000000","message":"Mismatch in number of args for this method.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    @METRICS.timer(\u0027OpenBMCMangement.get_boot_device\u0027)"},{"line_number":69,"context_line":"    def get_boot_device(self, task):"},{"line_number":70,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":71,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":72,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027presistent\u0027: False}"},{"line_number":73,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":74,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_2cbc97db","line":71,"range":{"start_line":71,"start_character":22,"end_line":71,"end_character":51},"in_reply_to":"9a30ddce_4c30fd9e","updated":"2017-03-09 15:37:15.000000000","message":"ahhh right because I left request_info in (gone in next revision). Thanks!","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":69,"context_line":"    def get_boot_device(self, task):"},{"line_number":70,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":71,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":72,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027presistent\u0027: False}"},{"line_number":73,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":74,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"},{"line_number":75,"context_line":"        elif boot_device \u003d\u003d \u0027disk\u0027:"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_ac96d949","line":72,"range":{"start_line":72,"start_character":41,"end_line":72,"end_character":60},"updated":"2017-03-09 06:59:27.000000000","message":"s/\u0027presistent\u0027 /\u0027persistent\u0027 /","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":69,"context_line":"    def get_boot_device(self, task):"},{"line_number":70,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":71,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":72,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027presistent\u0027: False}"},{"line_number":73,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":74,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"},{"line_number":75,"context_line":"        elif boot_device \u003d\u003d \u0027disk\u0027:"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_cce69b14","line":72,"range":{"start_line":72,"start_character":41,"end_line":72,"end_character":60},"in_reply_to":"9a30ddce_ac96d949","updated":"2017-03-09 15:37:15.000000000","message":"Done","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":80,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.BIOS"},{"line_number":81,"context_line":"        elif boot_device \u003d\u003d \u0027safe\u0027:"},{"line_number":82,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.safe"},{"line_number":83,"context_line":"        return response"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.set_boot_device\u0027)"},{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_0c9c4568","line":83,"range":{"start_line":83,"start_character":15,"end_line":83,"end_character":23},"updated":"2017-03-09 06:59:27.000000000","message":"Isn\u0027t OpenBMC Rest support retrieve \u0027persistent\u0027 settings related to boot device? Its being hard-coded to \u0027False\u0027 here.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":80,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.BIOS"},{"line_number":81,"context_line":"        elif boot_device \u003d\u003d \u0027safe\u0027:"},{"line_number":82,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.safe"},{"line_number":83,"context_line":"        return response"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.set_boot_device\u0027)"},{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_009eb762","line":83,"range":{"start_line":83,"start_character":15,"end_line":83,"end_character":23},"in_reply_to":"9a30ddce_0c9c4568","updated":"2017-03-09 15:37:15.000000000","message":"I\u0027ll need to look into this more. A typical JSON response for the boot_flags (where I would think this info would be) looks like this:\n\n{u\u0027status\u0027: u\u0027ok\u0027, u\u0027message\u0027: u\u0027200 OK\u0027, u\u0027data\u0027: {u\u0027data\u0027: u\u0027network\u0027}}\n\nMaybe there\u0027s another location for this.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":85,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.set_boot_device\u0027)"},{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"},{"line_number":87,"context_line":"        if device not in self.get_supported_boot_devices(task):"},{"line_number":88,"context_line":"            raise exception.InvalidParameterValue(_("},{"line_number":89,"context_line":"                \"Invalid boot device %s specified.\") % device)"},{"line_number":90,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":91,"context_line":"        boot_device \u003d BOOT_DEVICE_MAP[device]"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_9713de0c","line":88,"range":{"start_line":88,"start_character":12,"end_line":88,"end_character":44},"updated":"2017-03-09 06:59:27.000000000","message":"Log a error message as well.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":85,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.set_boot_device\u0027)"},{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"},{"line_number":87,"context_line":"        if device not in self.get_supported_boot_devices(task):"},{"line_number":88,"context_line":"            raise exception.InvalidParameterValue(_("},{"line_number":89,"context_line":"                \"Invalid boot device %s specified.\") % device)"},{"line_number":90,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":91,"context_line":"        boot_device \u003d BOOT_DEVICE_MAP[device]"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_16199d79","line":88,"range":{"start_line":88,"start_character":12,"end_line":88,"end_character":44},"in_reply_to":"9a30ddce_9713de0c","updated":"2017-03-09 15:37:15.000000000","message":"Not sure I agree with this one. Both the ipmitool management interface and OneView management interface don\u0027t log messages here. I\u0027ll wait for some more opinions if that\u0027s okay!","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"},{"line_number":87,"context_line":"        if device not in self.get_supported_boot_devices(task):"},{"line_number":88,"context_line":"            raise exception.InvalidParameterValue(_("},{"line_number":89,"context_line":"                \"Invalid boot device %s specified.\") % device)"},{"line_number":90,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":91,"context_line":"        boot_device \u003d BOOT_DEVICE_MAP[device]"},{"line_number":92,"context_line":"        request_info \u003d {\u0027data\u0027: {\u0027data\u0027: boot_device}}"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_1700cea9","line":89,"range":{"start_line":89,"start_character":17,"end_line":89,"end_character":50},"updated":"2017-03-09 06:59:27.000000000","message":"Add node uuid in the message.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":86,"context_line":"    def set_boot_device(self, task, device, persistent\u003dFalse):"},{"line_number":87,"context_line":"        if device not in self.get_supported_boot_devices(task):"},{"line_number":88,"context_line":"            raise exception.InvalidParameterValue(_("},{"line_number":89,"context_line":"                \"Invalid boot device %s specified.\") % device)"},{"line_number":90,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":91,"context_line":"        boot_device \u003d BOOT_DEVICE_MAP[device]"},{"line_number":92,"context_line":"        request_info \u003d {\u0027data\u0027: {\u0027data\u0027: boot_device}}"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_c0fadf74","line":89,"range":{"start_line":89,"start_character":17,"end_line":89,"end_character":50},"in_reply_to":"9a30ddce_1700cea9","updated":"2017-03-09 15:37:15.000000000","message":"Done","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"29e94a197f934d1d445d072b89d72095d68475bc","unresolved":false,"context_lines":[{"line_number":38,"context_line":"}"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"def _get_boot_device(driver_info):"},{"line_number":42,"context_line":"    obmc \u003d openbmc_common.OpenBMC(hostname\u003ddriver_info[\u0027openbmc_address\u0027],"},{"line_number":43,"context_line":"                                  user\u003ddriver_info[\u0027openbmc_username\u0027],"},{"line_number":44,"context_line":"                                  password\u003ddriver_info[\u0027openbmc_password\u0027])"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_609bb317","line":41,"range":{"start_line":41,"start_character":0,"end_line":41,"end_character":33},"updated":"2017-09-15 23:47:34.000000000","message":"nit: doc string is missing","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":57,"context_line":"class OpenBMCManagement(base.ManagementInterface):"},{"line_number":58,"context_line":""},{"line_number":59,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.validate\u0027)"},{"line_number":60,"context_line":"    def validate(self, task):"},{"line_number":61,"context_line":"        openbmc_common.parse_driver_info(task.node)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def get_properties(self):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_7d4ca741","line":60,"range":{"start_line":60,"start_character":4,"end_line":60,"end_character":29},"updated":"2017-09-14 11:17:37.000000000","message":"Add docstring","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":60,"context_line":"    def validate(self, task):"},{"line_number":61,"context_line":"        openbmc_common.parse_driver_info(task.node)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def get_properties(self):"},{"line_number":64,"context_line":"        return MANAGEMENT_PROPERTIES"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"    def get_supported_boot_devices(self, task):"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_5d49eb2e","line":63,"range":{"start_line":63,"start_character":3,"end_line":63,"end_character":29},"updated":"2017-09-14 11:17:37.000000000","message":"ditto","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":63,"context_line":"    def get_properties(self):"},{"line_number":64,"context_line":"        return MANAGEMENT_PROPERTIES"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"    def get_supported_boot_devices(self, task):"},{"line_number":67,"context_line":"        return list(BOOT_DEVICE_MAP)"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"    @METRICS.timer(\u0027OpenBMCMangement.get_boot_device\u0027)"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_1d4fe334","line":66,"range":{"start_line":66,"start_character":4,"end_line":66,"end_character":47},"updated":"2017-09-14 11:17:37.000000000","message":"ditto","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":67,"context_line":"        return list(BOOT_DEVICE_MAP)"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"    @METRICS.timer(\u0027OpenBMCMangement.get_boot_device\u0027)"},{"line_number":70,"context_line":"    def get_boot_device(self, task):"},{"line_number":71,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":72,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":73,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027persistent\u0027: False}"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_9d5cf3ed","line":70,"range":{"start_line":70,"start_character":8,"end_line":70,"end_character":36},"updated":"2017-09-14 11:17:37.000000000","message":"ditto","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from oslo_log import log as logging"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"from ironic.common import boot_devices"},{"line_number":21,"context_line":"from ironic.common import exception as exception"},{"line_number":22,"context_line":"from ironic.common.i18n import _"},{"line_number":23,"context_line":"from ironic.drivers import base"},{"line_number":24,"context_line":"from ironic.drivers.modules.openbmc import common as openbmc_common"}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_9809c032","line":21,"range":{"start_line":21,"start_character":35,"end_line":21,"end_character":48},"updated":"2017-11-14 21:40:54.000000000","message":"Why this? Seems unneeded","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from oslo_log import log as logging"},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"from ironic.common import boot_devices"},{"line_number":21,"context_line":"from ironic.common import exception as exception"},{"line_number":22,"context_line":"from ironic.common.i18n import _"},{"line_number":23,"context_line":"from ironic.drivers import base"},{"line_number":24,"context_line":"from ironic.drivers.modules.openbmc import common as openbmc_common"}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_07932851","line":21,"range":{"start_line":21,"start_character":35,"end_line":21,"end_character":48},"in_reply_to":"1f485f77_9809c032","updated":"2017-11-15 01:49:45.000000000","message":"+1","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":28,"context_line":"METRICS \u003d metrics_utils.get_metrics_logger(__name__)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"BOOT_DEVICE_MAP \u003d {"},{"line_number":31,"context_line":"    boot_devices.PXE: \u0027network\u0027,"},{"line_number":32,"context_line":"    boot_devices.DISK: \u0027disk\u0027,"},{"line_number":33,"context_line":"    boot_devices.CDROM: \u0027cdrom\u0027,"},{"line_number":34,"context_line":"    boot_devices.BIOS: \u0027setup\u0027,"},{"line_number":35,"context_line":"    boot_devices.SAFE: \u0027safe\u0027"},{"line_number":36,"context_line":"}"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_3b008601","line":35,"range":{"start_line":31,"start_character":0,"end_line":35,"end_character":29},"updated":"2017-11-14 21:40:54.000000000","message":"nit: can this be sorted?\n\nAlso add trailing comma please.","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":28,"context_line":"METRICS \u003d metrics_utils.get_metrics_logger(__name__)"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":"BOOT_DEVICE_MAP \u003d {"},{"line_number":31,"context_line":"    boot_devices.PXE: \u0027network\u0027,"},{"line_number":32,"context_line":"    boot_devices.DISK: \u0027disk\u0027,"},{"line_number":33,"context_line":"    boot_devices.CDROM: \u0027cdrom\u0027,"},{"line_number":34,"context_line":"    boot_devices.BIOS: \u0027setup\u0027,"},{"line_number":35,"context_line":"    boot_devices.SAFE: \u0027safe\u0027"},{"line_number":36,"context_line":"}"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_070a0889","line":35,"range":{"start_line":31,"start_character":0,"end_line":35,"end_character":29},"in_reply_to":"1f485f77_3b008601","updated":"2017-11-15 01:49:45.000000000","message":"+1","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":34,"context_line":"    boot_devices.BIOS: \u0027setup\u0027,"},{"line_number":35,"context_line":"    boot_devices.SAFE: \u0027safe\u0027"},{"line_number":36,"context_line":"}"},{"line_number":37,"context_line":""},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"def _get_boot_device(driver_info):"},{"line_number":40,"context_line":"    \"\"\"Gets boot device for the node who provided driver_info."}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_d1f6f3f9","line":37,"updated":"2017-11-14 21:40:54.000000000","message":"I notice in other drivers they do something like:\n\nBOOT_DEVICE_MAP_REV \u003d {\n    v: k for k, v in BOOT_DEVICE_MAP.items()}\n\nIf did that then it could be used down in line 188 to simplify things.","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":106,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":107,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027persistent\u0027: False}"},{"line_number":108,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":109,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"},{"line_number":110,"context_line":"        elif boot_device \u003d\u003d \u0027disk\u0027:"},{"line_number":111,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.DISK"}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_f1cc4fbd","line":108,"updated":"2017-11-14 21:40:54.000000000","message":"If have a BOOT_DEVICE_MAP_REV can do:\n\n response[\u0027boot_device\u0027] \u003d BOOT_DEVICE_MAP_REV[boot_device]","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":22255,"name":"Tuan","email":"tuanla@vn.fujitsu.com","username":"Tuan"},"change_message_id":"b4f93a59393a6017654829bfc8dbe4755d8843be","unresolved":false,"context_lines":[{"line_number":105,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":106,"context_line":"        boot_device \u003d _get_boot_device(driver_info)"},{"line_number":107,"context_line":"        response \u003d {\u0027boot_device\u0027: None, \u0027persistent\u0027: False}"},{"line_number":108,"context_line":"        if boot_device \u003d\u003d \u0027network\u0027:"},{"line_number":109,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.PXE"},{"line_number":110,"context_line":"        elif boot_device \u003d\u003d \u0027disk\u0027:"},{"line_number":111,"context_line":"            response[\u0027boot_device\u0027] \u003d boot_devices.DISK"}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_471da0bb","line":108,"in_reply_to":"1f485f77_f1cc4fbd","updated":"2017-11-15 01:49:45.000000000","message":"+1","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"c746e13c07282a5c48467a468962c9e2aa740631","unresolved":false,"context_lines":[{"line_number":66,"context_line":"    return obmc.set_boot_device(boot_device)"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"class OpenBMCManagement(base.ManagementInterface):"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    @METRICS.timer(\u0027OpenBMCManagement.validate\u0027)"},{"line_number":72,"context_line":"    def validate(self, task):"}],"source_content_type":"text/x-python","patch_set":7,"id":"5f7c97a3_4d76620e","line":69,"updated":"2018-07-21 21:45:24.000000000","message":"We\u0027ve since moved boot mode logic in. I wonder if we can control that. Maybe a later patch.","commit_id":"1ed0681e6a059b58ea59a7d38c9980588289c7a3"}],"ironic/drivers/modules/openbmc/power.py":[{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        power_cmd \u003d _power_off"},{"line_number":43,"context_line":"    else:"},{"line_number":44,"context_line":"        raise exception.InvalidParameterValue("},{"line_number":45,"context_line":"            _(\"_set_power_and_wait was called with invalid \""},{"line_number":46,"context_line":"              \"power state %s\") % target_state)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _wait(mutable):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_b721c24f","line":45,"range":{"start_line":45,"start_character":16,"end_line":45,"end_character":58},"updated":"2017-03-09 06:59:27.000000000","message":"Add node uuid into message.","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        power_cmd \u003d _power_off"},{"line_number":43,"context_line":"    else:"},{"line_number":44,"context_line":"        raise exception.InvalidParameterValue("},{"line_number":45,"context_line":"            _(\"_set_power_and_wait was called with invalid \""},{"line_number":46,"context_line":"              \"power state %s\") % target_state)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _wait(mutable):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_ac740768","line":45,"range":{"start_line":45,"start_character":16,"end_line":45,"end_character":58},"in_reply_to":"9a30ddce_b721c24f","updated":"2017-03-09 15:37:15.000000000","message":"Done","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"da2f7e01deded0cf8ed566c0ecfd0bb450ff27bc","unresolved":false,"context_lines":[{"line_number":119,"context_line":"    except exception.OpenBMCError:"},{"line_number":120,"context_line":"        return states.POWER_ERROR"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    return states.POWER_ON"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"class OpenBMCPower(base.PowerInterface):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_b7cf027e","line":122,"range":{"start_line":122,"start_character":11,"end_line":122,"end_character":26},"updated":"2017-03-09 06:59:27.000000000","message":"You mean states.POWER_OFF here?","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11929,"name":"Michael Turek","email":"mjturek@linux.vnet.ibm.com","username":"mjturek"},"change_message_id":"113806d19036984cd0d5545c0d9b9c793036d319","unresolved":false,"context_lines":[{"line_number":119,"context_line":"    except exception.OpenBMCError:"},{"line_number":120,"context_line":"        return states.POWER_ERROR"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    return states.POWER_ON"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"class OpenBMCPower(base.PowerInterface):"}],"source_content_type":"text/x-python","patch_set":3,"id":"9a30ddce_2c9d77bc","line":122,"range":{"start_line":122,"start_character":11,"end_line":122,"end_character":26},"in_reply_to":"9a30ddce_b7cf027e","updated":"2017-03-09 15:37:15.000000000","message":"whoops! fixed","commit_id":"a4b139120014913b8d5662d6bf78522d7a208ac4"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":88,"context_line":"    \"\"\"Gets the power status for the node who provided driver_info."},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"    :param driver_info: dict containing the access parameters for node."},{"line_number":91,"context_line":"    :returns: one of ironic.common.states POWER_OFF, POWER_ON, or ERROR."},{"line_number":92,"context_line":"    \"\"\""},{"line_number":93,"context_line":"    obmc \u003d openbmc_common.OpenBMC(hostname\u003ddriver_info[\u0027openbmc_address\u0027],"},{"line_number":94,"context_line":"                                  user\u003ddriver_info[\u0027openbmc_username\u0027],"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_3daa9f70","line":91,"range":{"start_line":91,"start_character":4,"end_line":91,"end_character":13},"updated":"2017-09-14 11:17:37.000000000","message":"Can raise OpenBMCError","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":104,"context_line":"        return states.ERROR"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"def _power_on(driver_info):"},{"line_number":108,"context_line":""},{"line_number":109,"context_line":"    obmc \u003d openbmc_common.OpenBMC(hostname\u003ddriver_info[\u0027openbmc_address\u0027],"},{"line_number":110,"context_line":"                                  user\u003ddriver_info[\u0027openbmc_username\u0027],"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_ddbefbb2","line":107,"range":{"start_line":107,"start_character":0,"end_line":107,"end_character":27},"updated":"2017-09-14 11:17:37.000000000","message":"Add doc string to all methods.","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":160,"context_line":"        \"\"\"Return the power state of the task\u0027s node."},{"line_number":161,"context_line":""},{"line_number":162,"context_line":"        :param task: a TaskManager instance containing the node to act on."},{"line_number":163,"context_line":"        :raises: MissingParameterValue if a required parameter is missing."},{"line_number":164,"context_line":"        :returns: a power state. One of :mod:`ironic.common.states`."},{"line_number":165,"context_line":"        \"\"\""},{"line_number":166,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_bdafaf7b","line":163,"range":{"start_line":163,"start_character":8,"end_line":163,"end_character":17},"updated":"2017-09-14 11:17:37.000000000","message":"Can raise OpenBMCError","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":172,"context_line":""},{"line_number":173,"context_line":"        :param task: a TaskManager instance containing the node to act on."},{"line_number":174,"context_line":"        :param power_state: Any power state from :mod:`ironic.common.states`."},{"line_number":175,"context_line":"        :raises: MissingParameterValue if a required parameter is missing."},{"line_number":176,"context_line":"        \"\"\""},{"line_number":177,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":178,"context_line":"        state \u003d _set_power_and_wait(power_state, driver_info)"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_3d75ff32","line":175,"range":{"start_line":175,"start_character":9,"end_line":175,"end_character":38},"updated":"2017-09-14 11:17:37.000000000","message":"Also PowerStateFailure","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":11076,"name":"Shivanand Tendulker","email":"stendulker@gmail.com","username":"stendulker"},"change_message_id":"dd139b44643245f34d21a59e10f3af743e7019c5","unresolved":false,"context_lines":[{"line_number":187,"context_line":"        by powering it on."},{"line_number":188,"context_line":""},{"line_number":189,"context_line":"        :param task: a TaskManager instance containing the node to act on."},{"line_number":190,"context_line":"        :raises: MissingParameterValue if a required parameter is missing."},{"line_number":191,"context_line":"        \"\"\""},{"line_number":192,"context_line":"        driver_info \u003d openbmc_common.parse_driver_info(task.node)"},{"line_number":193,"context_line":"        intermediate_state \u003d _set_power_and_wait(states.POWER_OFF,"}],"source_content_type":"text/x-python","patch_set":5,"id":"5f2577a7_5dca0b4e","line":190,"range":{"start_line":190,"start_character":8,"end_line":190,"end_character":16},"updated":"2017-09-14 11:17:37.000000000","message":"Also PowerStateFailure","commit_id":"b0f843e993345e59e5993da38dcc51017c3aa607"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":81,"context_line":"                       \u0027node_id\u0027: driver_info[\u0027uuid\u0027]})"},{"line_number":82,"context_line":"            mutable[\u0027power\u0027] \u003d states.ERROR"},{"line_number":83,"context_line":"            raise loopingcall.LoopingCallDone()"},{"line_number":84,"context_line":"        else:"},{"line_number":85,"context_line":"            mutable[\u0027total_time\u0027] +\u003d sleep_time"},{"line_number":86,"context_line":"            return sleep_time"},{"line_number":87,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_11f48b5a","line":84,"updated":"2017-11-14 21:40:54.000000000","message":"nit: else doesn\u0027t seem like it is needed.","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":112,"context_line":"        return states.POWER_OFF"},{"line_number":113,"context_line":"    elif power_info[\u0027state\u0027] \u003d\u003d 1:"},{"line_number":114,"context_line":"        return states.POWER_ON"},{"line_number":115,"context_line":"    else:"},{"line_number":116,"context_line":"        return states.ERROR"},{"line_number":117,"context_line":""},{"line_number":118,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_7193bffb","line":115,"updated":"2017-11-14 21:40:54.000000000","message":"Seems like a logging of this case would be good.","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":128,"context_line":"    try:"},{"line_number":129,"context_line":"        obmc.power_on()"},{"line_number":130,"context_line":"    except exception.OpenBMCError:"},{"line_number":131,"context_line":"        return states.POWER_ERROR"},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"    return states.POWER_ON"},{"line_number":134,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_f1b8cf76","line":131,"updated":"2017-11-14 21:40:54.000000000","message":"Do we want to log the error?","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"537508c10ef1d865f72e8ede98bb036b5622cc17","unresolved":false,"context_lines":[{"line_number":145,"context_line":"    try:"},{"line_number":146,"context_line":"        obmc.power_off()"},{"line_number":147,"context_line":"    except exception.OpenBMCError:"},{"line_number":148,"context_line":"        return states.POWER_ERROR"},{"line_number":149,"context_line":""},{"line_number":150,"context_line":"    return states.POWER_OFF"},{"line_number":151,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"1f485f77_d1bb936f","line":148,"updated":"2017-11-14 21:40:54.000000000","message":"Do we want to log the error?","commit_id":"4c2b1225f072b1b261f2aa369a644e2ce6e1d18f"},{"author":{"_account_id":6637,"name":"Sam Betts","email":"sam@code-smash.net","username":"sambetts"},"change_message_id":"2f20c036390a90d6cf341bdb7ddd4254f1517099","unresolved":false,"context_lines":[{"line_number":35,"context_line":"POWER_PROPERTIES \u003d openbmc_common.REQUIRED_PROPERTIES.copy()"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"def _set_power_and_wait(target_state, driver_info):"},{"line_number":39,"context_line":"    \"\"\"Set the power state and wait for the node\u0027s power state to match"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    Calls _power_on or _power_off depending on target_state. Waits"},{"line_number":42,"context_line":"    for _power_status to match the target state in exponentially increasing"},{"line_number":43,"context_line":"    time intervals less than the retry_timeout."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    :param target_state: desired ironic.power.state"},{"line_number":46,"context_line":"    :param driver_info: dict containing access parameters for the node"},{"line_number":47,"context_line":"    :returns: resulting ironic.power.state from the node"},{"line_number":48,"context_line":"    \"\"\""},{"line_number":49,"context_line":"    if target_state \u003d\u003d states.POWER_ON:"},{"line_number":50,"context_line":"        power_cmd \u003d _power_on"},{"line_number":51,"context_line":"    elif target_state \u003d\u003d states.POWER_OFF:"},{"line_number":52,"context_line":"        power_cmd \u003d _power_off"},{"line_number":53,"context_line":"    else:"},{"line_number":54,"context_line":"        raise exception.InvalidParameterValue("},{"line_number":55,"context_line":"            _(\"_set_power_and_wait was called with \""},{"line_number":56,"context_line":"              \"power state %(target_state)s on node %(node_uuid)s.\") %"},{"line_number":57,"context_line":"            {\u0027target_state\u0027: target_state,"},{"line_number":58,"context_line":"             \u0027node_uuid\u0027: driver_info[\u0027uuid\u0027]})"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    def _wait(mutable):"},{"line_number":61,"context_line":"        # Only issue power change command once"},{"line_number":62,"context_line":"        if mutable[\u0027iter\u0027] \u003c 0:"},{"line_number":63,"context_line":"            power_cmd(driver_info)"},{"line_number":64,"context_line":"        else:"},{"line_number":65,"context_line":"            mutable[\u0027power\u0027] \u003d _power_status(driver_info)"},{"line_number":66,"context_line":"        mutable[\u0027iter\u0027] +\u003d 1"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        if mutable[\u0027power\u0027] \u003d\u003d target_state:"},{"line_number":69,"context_line":"            raise loopingcall.LoopingCallDone()"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # At this point we\u0027re going to loop, so update sleep time for checking"},{"line_number":72,"context_line":"        if mutable[\u0027iter\u0027] \u003c\u003d 1:"},{"line_number":73,"context_line":"            sleep_time \u003d 1"},{"line_number":74,"context_line":"        else:"},{"line_number":75,"context_line":"            sleep_time \u003d mutable[\u0027iter\u0027] ** 2"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"        if (sleep_time + mutable[\u0027total_time\u0027]) \u003e CONF.openbmc.retry_timeout:"},{"line_number":78,"context_line":"            LOG.error(_(\u0027OpenBMC %(state)s timed out after \u0027"},{"line_number":79,"context_line":"                        \u0027%(tries)s retries on node %(node_id)s.\u0027),"},{"line_number":80,"context_line":"                      {\u0027state\u0027: target_state, \u0027tries\u0027: mutable[\u0027iter\u0027],"},{"line_number":81,"context_line":"                       \u0027node_id\u0027: driver_info[\u0027uuid\u0027]})"},{"line_number":82,"context_line":"            mutable[\u0027power\u0027] \u003d states.ERROR"},{"line_number":83,"context_line":"            raise loopingcall.LoopingCallDone()"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"        mutable[\u0027total_time\u0027] +\u003d sleep_time"},{"line_number":86,"context_line":"        return sleep_time"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"    # Use mutable objects so the looped method can change them."},{"line_number":89,"context_line":"    # Start \u0027iter\u0027 from -1 so that the first two checks are one second apart."},{"line_number":90,"context_line":"    status \u003d {\u0027power\u0027: None, \u0027iter\u0027: -1, \u0027total_time\u0027: 0}"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    timer \u003d loopingcall.DynamicLoopingCall(_wait, status)"},{"line_number":93,"context_line":"    timer.start().wait()"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"    return status[\u0027power\u0027]"},{"line_number":96,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"df7087c5_b741110e","line":93,"range":{"start_line":38,"start_character":0,"end_line":93,"end_character":24},"updated":"2018-03-12 18:00:56.000000000","message":"This logic seems to have been pulled out of the old ipmitool driver which has since been improved and standardised by a utility function cond_utils.node_wait_for_power_state(...) please use that instead of reimplementing this.","commit_id":"1ed0681e6a059b58ea59a7d38c9980588289c7a3"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"c746e13c07282a5c48467a468962c9e2aa740631","unresolved":false,"context_lines":[{"line_number":35,"context_line":"POWER_PROPERTIES \u003d openbmc_common.REQUIRED_PROPERTIES.copy()"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"def _set_power_and_wait(target_state, driver_info):"},{"line_number":39,"context_line":"    \"\"\"Set the power state and wait for the node\u0027s power state to match"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    Calls _power_on or _power_off depending on target_state. Waits"},{"line_number":42,"context_line":"    for _power_status to match the target state in exponentially increasing"},{"line_number":43,"context_line":"    time intervals less than the retry_timeout."},{"line_number":44,"context_line":""},{"line_number":45,"context_line":"    :param target_state: desired ironic.power.state"},{"line_number":46,"context_line":"    :param driver_info: dict containing access parameters for the node"},{"line_number":47,"context_line":"    :returns: resulting ironic.power.state from the node"},{"line_number":48,"context_line":"    \"\"\""},{"line_number":49,"context_line":"    if target_state \u003d\u003d states.POWER_ON:"},{"line_number":50,"context_line":"        power_cmd \u003d _power_on"},{"line_number":51,"context_line":"    elif target_state \u003d\u003d states.POWER_OFF:"},{"line_number":52,"context_line":"        power_cmd \u003d _power_off"},{"line_number":53,"context_line":"    else:"},{"line_number":54,"context_line":"        raise exception.InvalidParameterValue("},{"line_number":55,"context_line":"            _(\"_set_power_and_wait was called with \""},{"line_number":56,"context_line":"              \"power state %(target_state)s on node %(node_uuid)s.\") %"},{"line_number":57,"context_line":"            {\u0027target_state\u0027: target_state,"},{"line_number":58,"context_line":"             \u0027node_uuid\u0027: driver_info[\u0027uuid\u0027]})"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    def _wait(mutable):"},{"line_number":61,"context_line":"        # Only issue power change command once"},{"line_number":62,"context_line":"        if mutable[\u0027iter\u0027] \u003c 0:"},{"line_number":63,"context_line":"            power_cmd(driver_info)"},{"line_number":64,"context_line":"        else:"},{"line_number":65,"context_line":"            mutable[\u0027power\u0027] \u003d _power_status(driver_info)"},{"line_number":66,"context_line":"        mutable[\u0027iter\u0027] +\u003d 1"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"        if mutable[\u0027power\u0027] \u003d\u003d target_state:"},{"line_number":69,"context_line":"            raise loopingcall.LoopingCallDone()"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"        # At this point we\u0027re going to loop, so update sleep time for checking"},{"line_number":72,"context_line":"        if mutable[\u0027iter\u0027] \u003c\u003d 1:"},{"line_number":73,"context_line":"            sleep_time \u003d 1"},{"line_number":74,"context_line":"        else:"},{"line_number":75,"context_line":"            sleep_time \u003d mutable[\u0027iter\u0027] ** 2"},{"line_number":76,"context_line":""},{"line_number":77,"context_line":"        if (sleep_time + mutable[\u0027total_time\u0027]) \u003e CONF.openbmc.retry_timeout:"},{"line_number":78,"context_line":"            LOG.error(_(\u0027OpenBMC %(state)s timed out after \u0027"},{"line_number":79,"context_line":"                        \u0027%(tries)s retries on node %(node_id)s.\u0027),"},{"line_number":80,"context_line":"                      {\u0027state\u0027: target_state, \u0027tries\u0027: mutable[\u0027iter\u0027],"},{"line_number":81,"context_line":"                       \u0027node_id\u0027: driver_info[\u0027uuid\u0027]})"},{"line_number":82,"context_line":"            mutable[\u0027power\u0027] \u003d states.ERROR"},{"line_number":83,"context_line":"            raise loopingcall.LoopingCallDone()"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"        mutable[\u0027total_time\u0027] +\u003d sleep_time"},{"line_number":86,"context_line":"        return sleep_time"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"    # Use mutable objects so the looped method can change them."},{"line_number":89,"context_line":"    # Start \u0027iter\u0027 from -1 so that the first two checks are one second apart."},{"line_number":90,"context_line":"    status \u003d {\u0027power\u0027: None, \u0027iter\u0027: -1, \u0027total_time\u0027: 0}"},{"line_number":91,"context_line":""},{"line_number":92,"context_line":"    timer \u003d loopingcall.DynamicLoopingCall(_wait, status)"},{"line_number":93,"context_line":"    timer.start().wait()"},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"    return status[\u0027power\u0027]"},{"line_number":96,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"5f7c97a3_ad15b696","line":93,"range":{"start_line":38,"start_character":0,"end_line":93,"end_character":24},"in_reply_to":"df7087c5_b741110e","updated":"2018-07-21 21:45:24.000000000","message":"+1 to not, but it doesn\u0027t need to be perfect to land. I\u0027m fine with landing it as-is and letting it be iterated upon.","commit_id":"1ed0681e6a059b58ea59a7d38c9980588289c7a3"}],"ironic/tests/unit/drivers/modules/openbmc/test_common.py":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"c746e13c07282a5c48467a468962c9e2aa740631","unresolved":false,"context_lines":[{"line_number":50,"context_line":"    def test_parse_driver_info_fail(self):"},{"line_number":51,"context_line":"        bad_node \u003d obj_utils.create_test_node("},{"line_number":52,"context_line":"            self.context, uuid\u003duuidutils.generate_uuid(), id\u003d999,"},{"line_number":53,"context_line":"            driver\u003d\u0027fake_openbmc\u0027,"},{"line_number":54,"context_line":"            driver_info\u003ddb_utils.get_test_openbmc_driver_info())"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"        bad_node.driver_info.pop(\u0027openbmc_address\u0027)"}],"source_content_type":"text/x-python","patch_set":7,"id":"5f7c97a3_0d7ceae7","line":53,"range":{"start_line":53,"start_character":12,"end_line":53,"end_character":34},"updated":"2018-07-21 21:45:24.000000000","message":"Lets use fake-hardware, and then load the required interfaes up for testing.","commit_id":"1ed0681e6a059b58ea59a7d38c9980588289c7a3"}]}
