)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"760ec9a891cfdaa3656a3cba6215c2bafe1d6f6d","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2014-09-23 18:40:58 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Do not assume order of tags list elements"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This fixes the l2gateway unit test that breaks with a randomized PYTHONHASHSEED"},{"line_number":10,"context_line":"(see the bug report)."},{"line_number":11,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"da9df570_464fabbd","line":8,"updated":"2014-09-23 17:32:04.000000000","message":"commit message will need to be updated now that the fix is to order the tags","commit_id":"0deab650f7f8bb4517e6f6ee0db99b23e84cc7a5"}],"neutron/plugins/vmware/common/utils.py":[{"author":{"_account_id":7787,"name":"Kevin Benton","email":"kevin@benton.pub","username":"blak111"},"change_message_id":"687e393d3b274234fffee2b9a17c34a19355b369","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    tags \u003d ([dict(tag\u003dvalue, scope\u003dkey)"},{"line_number":41,"context_line":"            for key, value in kwargs.iteritems()])"},{"line_number":42,"context_line":"    tags.append({\"tag\": NEUTRON_VERSION, \"scope\": \"quantum\"})"},{"line_number":43,"context_line":"    return sorted(tags)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"def device_id_to_vm_id(device_id, obfuscate\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":5,"id":"da9df570_2452dfdd","line":43,"updated":"2014-09-21 07:42:33.000000000","message":"It sucks to change code just for a unit test, but if that\u0027s the only way to work around this problem, I\u0027m okay with it.","commit_id":"f513a2b971a38681bd6c721a8de87be93dde76c7"},{"author":{"_account_id":12737,"name":"Jacek Swiderski","email":"jacek.swiderski@codilime.com","username":"Altran"},"change_message_id":"570463b6633723bdc94f6b766eb247c44c2ef7b0","unresolved":false,"context_lines":[{"line_number":40,"context_line":"    tags \u003d ([dict(tag\u003dvalue, scope\u003dkey)"},{"line_number":41,"context_line":"            for key, value in kwargs.iteritems()])"},{"line_number":42,"context_line":"    tags.append({\"tag\": NEUTRON_VERSION, \"scope\": \"quantum\"})"},{"line_number":43,"context_line":"    return sorted(tags)"},{"line_number":44,"context_line":""},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"def device_id_to_vm_id(device_id, obfuscate\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":5,"id":"da9df570_481a8c18","line":43,"in_reply_to":"da9df570_2452dfdd","updated":"2014-09-22 08:51:20.000000000","message":"I\u0027ll upload my try to fix it by modifying only tests code (but it doesn\u0027t look pretty so maybe someone will have some better idea)","commit_id":"f513a2b971a38681bd6c721a8de87be93dde76c7"}],"neutron/plugins/vmware/nsxlib/l2gateway.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"6cdb708866824719fe66e5a549148504180359d4","unresolved":false,"context_lines":[{"line_number":126,"context_line":"            \"tags\": utils.get_tags(os_tid\u003dtenant_id,"},{"line_number":127,"context_line":"                                   q_gw_dev_id\u003dneutron_id),"},{"line_number":128,"context_line":"            \"admin_status_enabled\": True}"},{"line_number":129,"context_line":"    body.get(\"tags\").sort()"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"    if connector_ip and nsx_connector_type:"},{"line_number":132,"context_line":"        body[\"transport_connectors\"] \u003d ["}],"source_content_type":"text/x-python","patch_set":3,"id":"baada198_ed0dfc93","line":129,"updated":"2014-08-06 14:09:57.000000000","message":"wouldn\u0027t it be better to sort the tags at the source, ie. in get_tags?","commit_id":"69787a053898708314e7bc302f65d1047f898dcd"}],"neutron/tests/unit/vmware/nsxlib/test_l2gateway.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"099b481d0db3f6f3b9daec7341bee640e2e39ac7","unresolved":false,"context_lines":[{"line_number":193,"context_line":"                \"/ws.v1/transport-node\","},{"line_number":194,"context_line":"                mock.ANY,"},{"line_number":195,"context_line":"                cluster\u003dself.fake_cluster)"},{"line_number":196,"context_line":"            self.assertOrderedEqual(expected_req_body,"},{"line_number":197,"context_line":"                jsonutils.loads(request_mock.mock_calls[0][1][2]))"},{"line_number":198,"context_line":""},{"line_number":199,"context_line":"    def test_update_gw_device(self):"}],"source_content_type":"text/x-python","patch_set":6,"id":"da9df570_81b9a630","line":196,"updated":"2014-09-22 16:23:55.000000000","message":"it looks like the problem lies with self._create_expected_req_body, which can be rectified to return a predictable request body. I suspect the order that changes is in the tags, so you could follow a fix similar to the one made here:\n\nhttps://review.openstack.org/#/c/111809","commit_id":"560f56557c04deb10903254f2cbf3f0fdacef594"},{"author":{"_account_id":12737,"name":"Jacek Swiderski","email":"jacek.swiderski@codilime.com","username":"Altran"},"change_message_id":"ac4d122ab8cb320307cac59d552b6e30075775d9","unresolved":false,"context_lines":[{"line_number":193,"context_line":"                \"/ws.v1/transport-node\","},{"line_number":194,"context_line":"                mock.ANY,"},{"line_number":195,"context_line":"                cluster\u003dself.fake_cluster)"},{"line_number":196,"context_line":"            self.assertOrderedEqual(expected_req_body,"},{"line_number":197,"context_line":"                jsonutils.loads(request_mock.mock_calls[0][1][2]))"},{"line_number":198,"context_line":""},{"line_number":199,"context_line":"    def test_update_gw_device(self):"}],"source_content_type":"text/x-python","patch_set":6,"id":"da9df570_878603b8","line":196,"in_reply_to":"da9df570_81b9a630","updated":"2014-09-23 07:24:15.000000000","message":"both self._create_expected_req_body and the code that generates argument for do_request have unpredictable order of output - it can be fixed by assuring predictable output in both places but it requires change in non test code - which isn\u0027t really liked by some developers as commented here and also in some other reviews related to this bug (although review you linked did just that), this patchset is my try to fix the problem while only modifying test code - but I can go back to previous way if you think that was the correct way of handling it.","commit_id":"560f56557c04deb10903254f2cbf3f0fdacef594"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"d6d5dfa2654f29e766dc9298ab4ef9a8ccd55c77","unresolved":false,"context_lines":[{"line_number":193,"context_line":"                \"/ws.v1/transport-node\","},{"line_number":194,"context_line":"                mock.ANY,"},{"line_number":195,"context_line":"                cluster\u003dself.fake_cluster)"},{"line_number":196,"context_line":"            self.assertOrderedEqual(expected_req_body,"},{"line_number":197,"context_line":"                jsonutils.loads(request_mock.mock_calls[0][1][2]))"},{"line_number":198,"context_line":""},{"line_number":199,"context_line":"    def test_update_gw_device(self):"}],"source_content_type":"text/x-python","patch_set":6,"id":"da9df570_928c7537","line":196,"in_reply_to":"da9df570_878603b8","updated":"2014-09-23 15:34:11.000000000","message":"ok, a few points here:\n\n- the testcase relies on code that in itself increases the attack surface. Ideally that shouldn\u0027t happen, but that\u0027s not really your fault, and we may need to live with it;\n- arranging the test assertion like done here is not very intuitive, and poorly readable; also if another test gets added and it doesn\u0027t follow this convention, we\u0027ll end up re-introducing the failure.\n- I am not sure I understand the argument for not changing non-test code; isn\u0027t this fix about making the behavior of certain components predictable? I\u0027d favor that in face of weird conditions that could occur (granted they shouldn\u0027t, but hey!)","commit_id":"560f56557c04deb10903254f2cbf3f0fdacef594"}]}
