)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Convert port to str when validate console port"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The port type must be str type in nova-serialproxy side as we convert to str"},{"line_number":10,"context_line":"forcefully before rpc validate_console to compute service[1]. But on the"},{"line_number":11,"context_line":"compute side, the drive may be return int type like ironic serial console[2]."},{"line_number":12,"context_line":"So the validate_console_port may always return False as type inconsistence[3]."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_9dfa1d40","line":10,"range":{"start_line":10,"start_character":57,"end_line":10,"end_character":60},"updated":"2019-01-22 15:44:49.000000000","message":"And in this case, port is an IntegerField right? Which should get coerced to an int primitive.","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The port type must be str type in nova-serialproxy side as we convert to str"},{"line_number":10,"context_line":"forcefully before rpc validate_console to compute service[1]. But on the"},{"line_number":11,"context_line":"compute side, the drive may be return int type like ironic serial console[2]."},{"line_number":12,"context_line":"So the validate_console_port may always return False as type inconsistence[3]."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"[1] https://github.com/openstack/nova/blob/master/nova/console/websocketproxy.py#L123-L125"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_dd8505af","line":11,"range":{"start_line":11,"start_character":18,"end_line":11,"end_character":23},"updated":"2019-01-22 15:44:49.000000000","message":"driver","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bce68827cf7428f29b267c6068e0a2ec88df93bf","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The port type must be str type in nova-serialproxy side as we convert to str"},{"line_number":10,"context_line":"forcefully before rpc validate_console to compute service[1]. But on the"},{"line_number":11,"context_line":"compute side, the drive may be return int type like ironic serial console[2]."},{"line_number":12,"context_line":"So the validate_console_port may always return False as type inconsistence[3]."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"[1] https://github.com/openstack/nova/blob/master/nova/console/websocketproxy.py#L123-L125"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_e0f5c2cc","line":11,"range":{"start_line":11,"start_character":18,"end_line":11,"end_character":23},"in_reply_to":"9fdfeff1_dd8505af","updated":"2019-01-22 15:53:36.000000000","message":"Done","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":11,"context_line":"compute side, the drive may be return int type like ironic serial console[2]."},{"line_number":12,"context_line":"So the validate_console_port may always return False as type inconsistence[3]."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"[1] https://github.com/openstack/nova/blob/master/nova/console/websocketproxy.py#L123-L125"},{"line_number":15,"context_line":"[2] https://github.com/openstack/nova/blob/master/nova/virt/ironic/driver.py#L1819"},{"line_number":16,"context_line":"[3] https://github.com/openstack/nova/blob/master/nova/compute/manager.py#L5369"},{"line_number":17,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_5df59556","line":14,"range":{"start_line":14,"start_character":43,"end_line":14,"end_character":49},"updated":"2019-01-22 15:44:49.000000000","message":"Use a git hash or tag because these links will be out of date very quickly.","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bce68827cf7428f29b267c6068e0a2ec88df93bf","unresolved":false,"context_lines":[{"line_number":11,"context_line":"compute side, the drive may be return int type like ironic serial console[2]."},{"line_number":12,"context_line":"So the validate_console_port may always return False as type inconsistence[3]."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"[1] https://github.com/openstack/nova/blob/master/nova/console/websocketproxy.py#L123-L125"},{"line_number":15,"context_line":"[2] https://github.com/openstack/nova/blob/master/nova/virt/ironic/driver.py#L1819"},{"line_number":16,"context_line":"[3] https://github.com/openstack/nova/blob/master/nova/compute/manager.py#L5369"},{"line_number":17,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_8002b6b3","line":14,"range":{"start_line":14,"start_character":43,"end_line":14,"end_character":49},"in_reply_to":"9fdfeff1_5df59556","updated":"2019-01-22 15:53:36.000000000","message":"Done","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":13,"context_line":""},{"line_number":14,"context_line":"[1] https://github.com/openstack/nova/blob/master/nova/console/websocketproxy.py#L123-L125"},{"line_number":15,"context_line":"[2] https://github.com/openstack/nova/blob/master/nova/virt/ironic/driver.py#L1819"},{"line_number":16,"context_line":"[3] https://github.com/openstack/nova/blob/master/nova/compute/manager.py#L5369"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Closes-Bug: 1809418"},{"line_number":19,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_5dc355ee","line":16,"range":{"start_line":16,"start_character":4,"end_line":16,"end_character":79},"updated":"2019-01-22 15:44:49.000000000","message":"This no longer links to anything useful because the link isn\u0027t using a git hash or tag.\n\n--\n\nSo in this case, the ironic driver get_serial_console method returns a ConsoleSerial object with an int port and the ComputeManager.validate_console_port method is comparing the int port (from the driver) to the str port (passed in over the RPC API).","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"}],"nova/compute/manager.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":5354,"context_line":"                                   exception.InstanceNotFound)"},{"line_number":5355,"context_line":"    @wrap_exception()"},{"line_number":5356,"context_line":"    @wrap_instance_fault"},{"line_number":5357,"context_line":"    def validate_console_port(self, ctxt, instance, port, console_type):"},{"line_number":5358,"context_line":"        if console_type \u003d\u003d \"spice-html5\":"},{"line_number":5359,"context_line":"            console_info \u003d self.driver.get_spice_console(ctxt, instance)"},{"line_number":5360,"context_line":"        elif console_type \u003d\u003d \"rdp-html5\":"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_7d2e59a6","line":5357,"range":{"start_line":5357,"start_character":8,"end_line":5357,"end_character":29},"updated":"2019-01-22 15:44:49.000000000","message":"A docstring on this method would be nice to call out that the port is a string. I don\u0027t see any documention on the console.type.Console* objects about what those fields should be.","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4b10d8d8640c90fdf6b2cb8a7b33587c1547dd77","unresolved":false,"context_lines":[{"line_number":5366,"context_line":"        else:"},{"line_number":5367,"context_line":"            console_info \u003d self.driver.get_vnc_console(ctxt, instance)"},{"line_number":5368,"context_line":""},{"line_number":5369,"context_line":"        return str(console_info.port) \u003d\u003d port"},{"line_number":5370,"context_line":""},{"line_number":5371,"context_line":"    @wrap_exception()"},{"line_number":5372,"context_line":"    @reverts_task_state"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_002246a5","line":5369,"updated":"2019-01-22 15:44:49.000000000","message":"A comment here would also be nice, e.g. \"Some drivers may return an int on console_info.port but the port variable in this method is a string, so cast to be sure we are comparing the correct types.\"","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bce68827cf7428f29b267c6068e0a2ec88df93bf","unresolved":false,"context_lines":[{"line_number":5366,"context_line":"        else:"},{"line_number":5367,"context_line":"            console_info \u003d self.driver.get_vnc_console(ctxt, instance)"},{"line_number":5368,"context_line":""},{"line_number":5369,"context_line":"        return str(console_info.port) \u003d\u003d port"},{"line_number":5370,"context_line":""},{"line_number":5371,"context_line":"    @wrap_exception()"},{"line_number":5372,"context_line":"    @reverts_task_state"}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_603c7293","line":5369,"in_reply_to":"9fdfeff1_002246a5","updated":"2019-01-22 15:53:36.000000000","message":"Done","commit_id":"9d5e805009a7f773eac9b696ea8162a04ff73b0e"}]}
