)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":13997,"name":"SHIGEMATSU Mitsuhiro","email":"shigematsu.mitsuhiro@lab.ntt.co.jp","username":"pshige"},"change_message_id":"34326777bdba2994b9882d4d6d6afaefec804c55","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The \u0027node_uuid\u0027 is an invalid sort key in port list command, as"},{"line_number":10,"context_line":"well as \u0027chassis_uuid\u0027 in node list command."},{"line_number":11,"context_line":"Remove them from sort keys in coressponding list commands."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: I10caf5d99d9c8cc7b03dedc9b5cf0546351c6657"},{"line_number":14,"context_line":"Closes-Bug: #1443003"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"bab921fb_40d24d5d","line":11,"updated":"2015-04-26 16:48:41.000000000","message":"s/coressponding/corresponding/","commit_id":"88fdec5dd4c384782990a8e8f17ab2319c889418"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"25f85806896b1945f063362d7c0bc4f5b39c64dd","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The \u0027node_uuid\u0027 is an invalid sort key in port list command, as"},{"line_number":10,"context_line":"well as \u0027chassis_uuid\u0027 in node list command."},{"line_number":11,"context_line":"Remove them from sort keys in coressponding list commands."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: I10caf5d99d9c8cc7b03dedc9b5cf0546351c6657"},{"line_number":14,"context_line":"Closes-Bug: #1443003"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"bab921fb_16c37bee","line":11,"in_reply_to":"bab921fb_40d24d5d","updated":"2015-04-27 01:42:38.000000000","message":"Thanks, SHIGEMATSU. Good catch finding this spelling error.","commit_id":"88fdec5dd4c384782990a8e8f17ab2319c889418"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The \u0027node_uuid\u0027 is an invalid sort key in port list command, as"},{"line_number":10,"context_line":"well as \u0027chassis_uuid\u0027 in node list command."},{"line_number":11,"context_line":"Remove them from sort keys in corressponding list commands."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: I10caf5d99d9c8cc7b03dedc9b5cf0546351c6657"},{"line_number":14,"context_line":"Closes-Bug: #1443003"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"3acd31a7_e5c56b5b","line":11,"updated":"2015-04-30 20:03:49.000000000","message":"if you push another revision, s/corressponding/corresponding/","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The \u0027node_uuid\u0027 is an invalid sort key in port list command, as"},{"line_number":10,"context_line":"well as \u0027chassis_uuid\u0027 in node list command."},{"line_number":11,"context_line":"Remove them from sort keys in corressponding list commands."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: I10caf5d99d9c8cc7b03dedc9b5cf0546351c6657"},{"line_number":14,"context_line":"Closes-Bug: #1443003"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"3acd31a7_a7be2dd2","line":11,"in_reply_to":"3acd31a7_e5c56b5b","updated":"2015-05-04 03:47:09.000000000","message":"Good catch. I will update it in the next patch, thanks.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"}],"ironicclient/tests/unit/v1/test_node_shell.py":[{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":434,"context_line":"    def test_do_node_list(self):"},{"line_number":435,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":436,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":437,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":438,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":439,"context_line":"        args.associated \u003d None"},{"line_number":440,"context_line":"        args.maintenance \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_1daa3371","line":437,"updated":"2015-04-27 09:27:49.000000000","message":"client_mock variable being set twice","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"e5cbbb209291400dde09f0f01cc259769f3c473c","unresolved":false,"context_lines":[{"line_number":435,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":436,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":437,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":438,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":439,"context_line":"        args.associated \u003d None"},{"line_number":440,"context_line":"        args.maintenance \u003d None"},{"line_number":441,"context_line":"        args.marker \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_dd671b24","line":438,"updated":"2015-04-27 09:28:17.000000000","message":"args is being set twice here too","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":442,"context_line":"        args.limit \u003d None"},{"line_number":443,"context_line":"        args.sort_dir \u003d None"},{"line_number":444,"context_line":"        args.sort_key \u003d None"},{"line_number":445,"context_line":"        args.detail \u003d False"},{"line_number":446,"context_line":""},{"line_number":447,"context_line":"        n_shell.do_node_list(client_mock, args)"},{"line_number":448,"context_line":"        client_mock.node.list.assert_called_once_with(detail\u003dFalse)"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_fd877f10","line":445,"updated":"2015-04-27 09:27:49.000000000","message":"Do we need to set all the fields to None? It looks hard to read and duplicates a lot of code.\n\nIf we have to set to None let\u0027s create a helper function for it:\n\n def _get_client_mock_args(self, associated\u003dNone, maintenance\u003dNone, marker\u003dNone,\n                           limit\u003dNone, sort_dit\u003dNone, sort_key\u003dNone, detail\u003dFalse):\n     args \u003d mock.MagicMock()\n     args.associated \u003d associated\n     ...\n     return args","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":451,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":452,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":453,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":454,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":455,"context_line":"        args.associated \u003d None"},{"line_number":456,"context_line":"        args.maintenance \u003d None"},{"line_number":457,"context_line":"        args.marker \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_9debe3b0","line":454,"updated":"2015-04-27 09:27:49.000000000","message":"client_mock and args variables being set twice","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":482,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":483,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":484,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":485,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":486,"context_line":"        args.associated \u003d None"},{"line_number":487,"context_line":"        args.maintenance \u003d None"},{"line_number":488,"context_line":"        args.marker \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_7dd12ffb","line":485,"updated":"2015-04-27 09:27:49.000000000","message":"client_mock and args variables being set twice","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":499,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":500,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":501,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":502,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":503,"context_line":"        args.associated \u003d None"},{"line_number":504,"context_line":"        args.maintenance \u003d None"},{"line_number":505,"context_line":"        args.marker \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_5dce6b5b","line":502,"updated":"2015-04-27 09:27:49.000000000","message":"client_mock and args variables being set twice","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":516,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":517,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":518,"context_line":"        client_mock \u003d mock.MagicMock()"},{"line_number":519,"context_line":"        args \u003d mock.MagicMock()"},{"line_number":520,"context_line":"        args.associated \u003d None"},{"line_number":521,"context_line":"        args.maintenance \u003d None"},{"line_number":522,"context_line":"        args.marker \u003d None"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_dd083b94","line":519,"updated":"2015-04-27 09:27:49.000000000","message":"client_mock and args variables being set twice","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":475,"context_line":""},{"line_number":476,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":477,"context_line":"                          n_shell.do_node_list,"},{"line_number":478,"context_line":"                          client_mock, args)"},{"line_number":479,"context_line":""},{"line_number":480,"context_line":"    def test_do_node_list_detail_sort_key(self):"},{"line_number":481,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_80ca25a0","line":478,"updated":"2015-04-30 20:03:49.000000000","message":"I think it is still good to check if client_mock was called or not.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":475,"context_line":""},{"line_number":476,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":477,"context_line":"                          n_shell.do_node_list,"},{"line_number":478,"context_line":"                          client_mock, args)"},{"line_number":479,"context_line":""},{"line_number":480,"context_line":"    def test_do_node_list_detail_sort_key(self):"},{"line_number":481,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_c77a49f1","line":478,"in_reply_to":"3acd31a7_80ca25a0","updated":"2015-05-04 03:47:09.000000000","message":"Tired with the following code:\n\nself.assertRaises(exceptions.CommandError,\n\t          n_shell.do_node_list,\n\t\t  client_mock, args)\nn_shell.do_node_list(client_mock, args)\nclient_mock.node.list.assert_called_once_with(sort_key\u003d\u0027chassis_uuid\u0027)\n\nAnd get error like:\nironicclient.openstack.common.apiclient.exceptions.CommandError: chassis_uuid is an invalid field for sorting, valid values for --sort-key are: [\u0027provision_state\u0027, \u0027Name\u0027, \u0027uuid\u0027, \u0027Instance UUID\u0027, \u0027power_state\u0027, \u0027Power State\u0027, \u0027Maintenance\u0027, \u0027instance_uuid\u0027, \u0027UUID\u0027, \u0027Provisioning State\u0027, \u0027maintenance\u0027, \u0027name\u0027]\nRan 234 tests in 0.337s (-0.008s)\nFAILED (id\u003d110, failures\u003d1)\nerror: testr failed (1)\n\nI think this is correct for the sort key is wrong here.\n\nAlso tried with these code:\n\nself.assertRaises(exceptions.CommandError,\n\t\t  n_shell.do_node_list,\n\t\t  client_mock, args)\nclient_mock.node.list.assert_called_once_with(sort_key\u003d\u0027chassis_uuid\u0027)\n\nAnd get error:\nAssertionError: Expected to be called once. Called 0 times.\nRan 234 tests in 0.351s (+0.015s)\nFAILED (id\u003d111, failures\u003d1)\nerror: testr failed (1)\n\nNot sure whether this is because the function is called in \u0027self.assertRaises\u0027 so the \u0027assert_called_once_with\u0027 here returns false, or the \u0027n_shell.do_node_list(client_mock, args)\u0027 is not executed so the \u0027assert_called_once_with\u0027 is wrong.\nI find an example like this \u0027assertRaises\u0027: https://github.com/openstack/python-ironicclient/blob/master/ironicclient/tests/unit/v1/test_node_shell.py#L180\nThe example also does not check that. Any suggestions?","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"fc84fbba3af9137aac0e98f17164a60c1c17d03d","unresolved":false,"context_lines":[{"line_number":475,"context_line":""},{"line_number":476,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":477,"context_line":"                          n_shell.do_node_list,"},{"line_number":478,"context_line":"                          client_mock, args)"},{"line_number":479,"context_line":""},{"line_number":480,"context_line":"    def test_do_node_list_detail_sort_key(self):"},{"line_number":481,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_f90f1a2c","line":478,"in_reply_to":"3acd31a7_c77a49f1","updated":"2015-05-04 15:50:11.000000000","message":"Kan, I\u0027m not totally sure I understand your comment. It may be that you don\u0027t understand what is happening.\n\nThe self.assertRaises() call actually causes \u0027n_shell.do_node_list(client_mock, args)\u0027 to be invoked. It checks that the call raises exceptions.CommandError.\n\nIf your code change works properly, client_mode.node.list should NOT have been called. So this would \u0027prove\u0027 that (and that\u0027s what I meant in my original comment):\n    self.assertFalse(client_mock.node.list.called)","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"e17c7b83459af19bf536cffa8bf986ea6551574b","unresolved":false,"context_lines":[{"line_number":475,"context_line":""},{"line_number":476,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":477,"context_line":"                          n_shell.do_node_list,"},{"line_number":478,"context_line":"                          client_mock, args)"},{"line_number":479,"context_line":""},{"line_number":480,"context_line":"    def test_do_node_list_detail_sort_key(self):"},{"line_number":481,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_c49103f3","line":478,"in_reply_to":"3acd31a7_f90f1a2c","updated":"2015-05-05 05:09:16.000000000","message":"Oops, indeed I made a mistake in understanding your comment before. Will update in the next patch, thanks.:)","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":493,"context_line":""},{"line_number":494,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":495,"context_line":"                          n_shell.do_node_list,"},{"line_number":496,"context_line":"                          client_mock, args)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_807c6573","line":496,"updated":"2015-04-30 20:03:49.000000000","message":"What\u0027s the difference between this test and the one at line 471 (test_do_node_list_wrong_sort_key())?","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":493,"context_line":""},{"line_number":494,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":495,"context_line":"                          n_shell.do_node_list,"},{"line_number":496,"context_line":"                          client_mock, args)"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_27e45d0b","line":496,"in_reply_to":"3acd31a7_807c6573","updated":"2015-05-04 03:47:09.000000000","message":"The test at line 471 should be \u0027detail\u003dFalse\u0027. I will update it in the next patch, thanks.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"}],"ironicclient/tests/unit/v1/test_port_shell.py":[{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"20e5f20a549eb51f3879031b5fbcb4bc31d53b55","unresolved":false,"context_lines":[{"line_number":93,"context_line":"        args.marker \u003d None"},{"line_number":94,"context_line":"        args.sort_key \u003d None"},{"line_number":95,"context_line":"        args.sort_dir \u003d None"},{"line_number":96,"context_line":"        args.detail \u003d False"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"        p_shell.do_port_list(client_mock, args)"},{"line_number":99,"context_line":"        client_mock.port.list.assert_called_once_with(detail\u003dFalse)"}],"source_content_type":"text/x-python","patch_set":6,"id":"9abe1de1_dd16fba6","line":96,"updated":"2015-04-27 09:27:49.000000000","message":"ditto re. hard to read with all this things being set to None. We need a helper function if it\u0027s need to set everything to None","commit_id":"9b5aee9801af2ed43283eae3172a1e4d4cfe21d1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":127,"context_line":"                          p_shell.do_port_list,"},{"line_number":128,"context_line":"                          client_mock, args)"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    def test_do_port_list_detail_sort_key(self):"},{"line_number":131,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_a00ac1d0","line":128,"updated":"2015-04-30 20:03:49.000000000","message":"I want to make sure I understand what you\u0027re testing for here. detail\u003dFalse, right?\n\nWould be good to check client_mock, to see if it was called or not.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        self.assertRaises(exceptions.CommandError,"},{"line_number":127,"context_line":"                          p_shell.do_port_list,"},{"line_number":128,"context_line":"                          client_mock, args)"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    def test_do_port_list_detail_sort_key(self):"},{"line_number":131,"context_line":"        client_mock \u003d mock.MagicMock()"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_271d7d0f","line":128,"in_reply_to":"3acd31a7_a00ac1d0","updated":"2015-05-04 03:47:09.000000000","message":"Yes, it is. The sort keys are different now between \u0027detail\u003dFalse\u0027 and \u0027detail\u003dTrue\u0027, so I add these two of them to cover this situation.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"}],"ironicclient/v1/node_shell.py":[{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"87885136d4f56764ec30629d749f59e5dad1b5bc","unresolved":false,"context_lines":[{"line_number":107,"context_line":"    # Remove \u0027chassis_uuid\u0027 from the sort keys for it is not stored in"},{"line_number":108,"context_line":"    # table nodes and is got from table chassis by \u0027chassis_id\u0027. See"},{"line_number":109,"context_line":"    # bug #1443003 for more details."},{"line_number":110,"context_line":"    import copy"},{"line_number":111,"context_line":"    sort_fields \u003d copy.deepcopy(fields)"},{"line_number":112,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":113,"context_line":"    if args.detail:"}],"source_content_type":"text/x-python","patch_set":3,"id":"dac4157f_1244dd47","line":110,"updated":"2015-04-22 16:05:01.000000000","message":"imports should be at the top of the file with the other imports.","commit_id":"5851ede00eb887f4627d9763991fe859b358d53a"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    # Remove \u0027chassis_uuid\u0027 from the sort keys for it is not stored in"},{"line_number":108,"context_line":"    # table nodes and is got from table chassis by \u0027chassis_id\u0027. See"},{"line_number":109,"context_line":"    # bug #1443003 for more details."},{"line_number":110,"context_line":"    sort_fields \u003d copy.deepcopy(fields)"},{"line_number":111,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":112,"context_line":"    if args.detail:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_c04dbd73","line":109,"updated":"2015-04-30 20:03:49.000000000","message":"How about \u0027The server cannot sort on \"chassis_uuid\" because that isn\u0027t a column in the \"nodes\" db table. \"chassis_id\" is stored, but that is internal to ironic.\u0027","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":106,"context_line":""},{"line_number":107,"context_line":"    # Remove \u0027chassis_uuid\u0027 from the sort keys for it is not stored in"},{"line_number":108,"context_line":"    # table nodes and is got from table chassis by \u0027chassis_id\u0027. See"},{"line_number":109,"context_line":"    # bug #1443003 for more details."},{"line_number":110,"context_line":"    sort_fields \u003d copy.deepcopy(fields)"},{"line_number":111,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":112,"context_line":"    if args.detail:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_a7a50db6","line":109,"in_reply_to":"3acd31a7_c04dbd73","updated":"2015-05-04 03:47:09.000000000","message":"More clearer than before, will update in the next patch, thanks.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":111,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":112,"context_line":"    if args.detail:"},{"line_number":113,"context_line":"        sort_fields.remove(\u0027chassis_uuid\u0027)"},{"line_number":114,"context_line":"        sort_field_labels.remove(\u0027Chassis UUID\u0027)"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"    params.update(utils.common_params_for_list(args,"},{"line_number":117,"context_line":"                                               sort_fields,"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_0582a794","line":114,"updated":"2015-04-30 20:03:49.000000000","message":"Hmm, I\u0027d actually prefer if we used static lists because we know ahead of time, what the lists are. Anyway, generating the list at run time is probably fine for now. But I\u0027d like to see this only done when needed, so instead of your changes from line 107, I think they can be incorporated in the if line starting at line 100.\n\n    if args.detail:\n        fields \u003d ...\n        field_labels \u003d ...\n        sort_fields \u003d copy.deepcopy(fields)\n        sort_field_labels \u003d copy.deepcopy(field_labels)\n        sort_fields.remove...\n        sort_field_labels.remove...\n    else:\n         fields \u003d ...\n         field_labels \u003d ...\n         sort_fields \u003d fields\n         sort_field_labels \u003d field_labels","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":111,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":112,"context_line":"    if args.detail:"},{"line_number":113,"context_line":"        sort_fields.remove(\u0027chassis_uuid\u0027)"},{"line_number":114,"context_line":"        sort_field_labels.remove(\u0027Chassis UUID\u0027)"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"    params.update(utils.common_params_for_list(args,"},{"line_number":117,"context_line":"                                               sort_fields,"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_47d0791f","line":114,"in_reply_to":"3acd31a7_0582a794","updated":"2015-05-04 03:47:09.000000000","message":"Will update in the next patch, thanks.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"91c13803fb632f76d0a1ddc7ba0dea1433440955","unresolved":false,"context_lines":[{"line_number":99,"context_line":""},{"line_number":100,"context_line":"    # The server cannot sort on \"chassis_uuid\" because it isn\u0027t a"},{"line_number":101,"context_line":"    # column in the \"nodes\" database table. \"chassis_id\" is stored,"},{"line_number":102,"context_line":"    # but it is internal to ironic. See bug #1443003 for more details."},{"line_number":103,"context_line":"    if args.detail:"},{"line_number":104,"context_line":"        fields \u003d res_fields.NODE_FIELDS"},{"line_number":105,"context_line":"        field_labels \u003d res_fields.NODE_FIELD_LABELS"}],"source_content_type":"text/x-python","patch_set":8,"id":"3acd31a7_0ce4b2a9","line":102,"updated":"2015-05-05 15:02:33.000000000","message":"This comment only pertains to the code in \u0027if args.detail\u0027, so it makes more sense to move it there, but I suppose this is fine.","commit_id":"b776e47d3cc3d7cedd127b5592055e3d11242b53"}],"ironicclient/v1/port_shell.py":[{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"87885136d4f56764ec30629d749f59e5dad1b5bc","unresolved":false,"context_lines":[{"line_number":93,"context_line":"    # Remove \u0027node_uuid\u0027 from the sort keys for it is not stored in"},{"line_number":94,"context_line":"    # table ports and is got from table nodes by \u0027node_id\u0027. See bug"},{"line_number":95,"context_line":"    # #1443003 for more details."},{"line_number":96,"context_line":"    import copy"},{"line_number":97,"context_line":"    sort_fields \u003d copy.deepcopy(fields)"},{"line_number":98,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":99,"context_line":"    if args.detail:"}],"source_content_type":"text/x-python","patch_set":3,"id":"dac4157f_12161d4c","line":96,"updated":"2015-04-22 16:05:01.000000000","message":"The import should be at the top of the file.   With the other imports.","commit_id":"5851ede00eb887f4627d9763991fe859b358d53a"},{"author":{"_account_id":13762,"name":"jiangfei","email":"jiangfei0622@huawei.com","username":"jiangfei"},"change_message_id":"c503b667d4c97cd929666a3ae51c3053ff484aaa","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":99,"context_line":"    if args.detail:"},{"line_number":100,"context_line":"        sort_fields.remove(\u0027node_uuid\u0027)"},{"line_number":101,"context_line":"        sort_field_labels.remove(\u0027Node UUID\u0027)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"    params.update(utils.common_params_for_list(args,"},{"line_number":104,"context_line":"                                               sort_fields,"}],"source_content_type":"text/x-python","patch_set":3,"id":"bab921fb_5b04e5be","line":101,"updated":"2015-04-24 06:45:13.000000000","message":"table ports  have field node_id, why can\u0027t sort by node_id","commit_id":"5851ede00eb887f4627d9763991fe859b358d53a"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"02adb3e9275cd03966a84c046f1177c2980d11d4","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":99,"context_line":"    if args.detail:"},{"line_number":100,"context_line":"        sort_fields.remove(\u0027node_uuid\u0027)"},{"line_number":101,"context_line":"        sort_field_labels.remove(\u0027Node UUID\u0027)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"    params.update(utils.common_params_for_list(args,"},{"line_number":104,"context_line":"                                               sort_fields,"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_65495b8b","line":101,"updated":"2015-04-30 20:03:49.000000000","message":"ditto","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"},{"author":{"_account_id":14810,"name":"Kan","email":"sofaopenstack@gmail.com","username":"Kan"},"change_message_id":"153cb81158707f6cf776eba097552a42ad689b0e","unresolved":false,"context_lines":[{"line_number":98,"context_line":"    sort_field_labels \u003d copy.deepcopy(field_labels)"},{"line_number":99,"context_line":"    if args.detail:"},{"line_number":100,"context_line":"        sort_fields.remove(\u0027node_uuid\u0027)"},{"line_number":101,"context_line":"        sort_field_labels.remove(\u0027Node UUID\u0027)"},{"line_number":102,"context_line":""},{"line_number":103,"context_line":"    params.update(utils.common_params_for_list(args,"},{"line_number":104,"context_line":"                                               sort_fields,"}],"source_content_type":"text/x-python","patch_set":7,"id":"3acd31a7_07ca816d","line":101,"in_reply_to":"3acd31a7_65495b8b","updated":"2015-05-04 03:47:09.000000000","message":"Will update in the next patch, thanks.","commit_id":"dd07a8c3af5e51d44499dfb5c4a29b44b67a929d"}]}
