)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"68350f88ff252750e95875e436a267f58e51eb9d","unresolved":true,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"libvirt: At start-up allow skiping compareCPU() with a workaround"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This workaround will skip libvirt\u0027s compareCPU() call in"},{"line_number":10,"context_line":"_check_cpu_compatibility() and allow libvirt to handle it more"},{"line_number":11,"context_line":"correctly.  This will avoid certain classes of bugs.  (QEMU \u003e\u003d2.9 and"},{"line_number":12,"context_line":"libvirt \u003e\u003d 4.4.0 are the mininum required versions, and upstream Nova"},{"line_number":13,"context_line":"satisfies them by a good margin.)"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"3246fbcd_a699d9d6","line":11,"range":{"start_line":9,"start_character":0,"end_line":11,"end_character":11},"updated":"2023-01-18 11:34:37.000000000","message":"This is not totally true we only disable one compare call now","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"ceea3fa49f5dcc100be1361bd9c44307112940ad","unresolved":true,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"libvirt: At start-up allow skiping compareCPU() with a workaround"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This workaround will skip libvirt\u0027s compareCPU() call in"},{"line_number":10,"context_line":"_check_cpu_compatibility() and allow libvirt to handle it more"},{"line_number":11,"context_line":"correctly.  This will avoid certain classes of bugs.  (QEMU \u003e\u003d2.9 and"},{"line_number":12,"context_line":"libvirt \u003e\u003d 4.4.0 are the mininum required versions, and upstream Nova"},{"line_number":13,"context_line":"satisfies them by a good margin.)"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"b7265594_11f10321","line":11,"range":{"start_line":9,"start_character":0,"end_line":11,"end_character":11},"in_reply_to":"3246fbcd_a699d9d6","updated":"2023-01-18 13:34:33.000000000","message":"Right, I had a local draft that said \"skip the _first_ compareCPU() call\".  I\u0027ll correct it.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"libvirt: At start-up allow skiping compareCPU() with a workaround"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This workaround will skip libvirt\u0027s compareCPU() call in"},{"line_number":10,"context_line":"_check_cpu_compatibility() and allow libvirt to handle it more"},{"line_number":11,"context_line":"correctly.  This will avoid certain classes of bugs.  (QEMU \u003e\u003d2.9 and"},{"line_number":12,"context_line":"libvirt \u003e\u003d 4.4.0 are the mininum required versions, and upstream Nova"},{"line_number":13,"context_line":"satisfies them by a good margin.)"},{"line_number":14,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"94247878_7141bb0e","line":11,"range":{"start_line":9,"start_character":0,"end_line":11,"end_character":11},"in_reply_to":"b7265594_11f10321","updated":"2023-01-23 23:59:23.000000000","message":"Done","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"}],"/PATCHSET_LEVEL":[{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"64b99c3c6d1e13f986fa80a458f2a048335ea4c4","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"141bc06e_811e4997","updated":"2023-01-19 13:02:18.000000000","message":"Fixed in v6.  (The previous comment also should\u0027ve said v6 instead of v4)","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"8d754e4f4a7de308f2923de206424cff204f87b0","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"96474140_08ef549e","updated":"2023-01-19 13:51:13.000000000","message":"Looks good to me.","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"6457e1632b315affc60d6897d9a5a5d7e6a5d9df","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"3d67c16a_14a5176f","updated":"2023-01-20 10:49:33.000000000","message":"Okay, Sean clarified his thinking on IRC.  The summary is:\n\n- We can actually just remove the first compareCPU() call unconditionally\n- And put the second call one under a workaround - to future-proof the code","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"db1e2e33ebaaa524666b68709de9296da2940194","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":7,"id":"a7c8717f_9e0171ce","updated":"2023-01-20 14:17:46.000000000","message":"Thanks Kashyap.","commit_id":"cd0eccfff4f1ae30c67e8bbd06c798d152267c36"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"d1d95b9eee295c047f2cf0d3ee0ba844db119bd7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":7,"id":"bdb915ee_bd8e2d63","updated":"2023-01-20 12:36:14.000000000","message":"looks good","commit_id":"cd0eccfff4f1ae30c67e8bbd06c798d152267c36"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"a341f81a2c18076b007b1004359a42728012c08f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"f0fad8f3_f089b889","updated":"2023-01-23 13:23:33.000000000","message":"Notes for myself:\n\nOnce I add the missing mock to one of the two failing tests (both, failing in the same way), test__check_cpu_compatibility_advance_model\n\n    @mock.patch.object(libvirt_driver.LibvirtDriver,\n                       \u0027_register_all_undefined_instance_details\u0027,\n                       new\u003dmock.Mock())\n\nIt now fails with:\n\n\n    testtools.matchers._impl.MismatchError: \u003cbound method LibvirtDriver.init_host of \u003cnova.virt.libvirt.driver.LibvirtDriver object at 0x7fcbb8465070\u003e\u003e returned None\n                               \nStill investigating.","commit_id":"01389198cdedf66dc2de0e30831c58f0d8098c7d"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":9,"id":"ea004d29_344db9d0","updated":"2023-01-23 23:59:23.000000000","message":"i think this is mostly good one issue inline.","commit_id":"93847aaf3a5bb64bf3d15423432fd3d9b80e80c3"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"9c11116196deeed037af8005baee1f60246e31d8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"21c8acc3_f55b0f86","updated":"2023-01-24 10:32:22.000000000","message":"ok this look fine to proceed\n\nif you respin please add a release note but i dont think we neeed to hold it for that","commit_id":"9caaaf1f221063a4329c72c8b67a6015648644a2"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"5bac2c23f11a405316fc6a8978698ab3c34c5fe8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"851217d0_4f114daa","updated":"2023-01-26 10:52:07.000000000","message":"recheck (unrelated timeouts)","commit_id":"9caaaf1f221063a4329c72c8b67a6015648644a2"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"078c9f19a6512c0dcf1cf8f98711cfb7c8e56598","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"dfefc5c5_1688755b","updated":"2023-01-26 09:36:17.000000000","message":"recheck job timed out during uploading the logs from a successfull execution :/","commit_id":"9caaaf1f221063a4329c72c8b67a6015648644a2"}],"nova/conf/workarounds.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"68350f88ff252750e95875e436a267f58e51eb9d","unresolved":true,"context_lines":[{"line_number":410,"context_line":"4.4.0, libvirt will do the correct thing with respect to checking CPU"},{"line_number":411,"context_line":"compatibility on the destination host during live migration."},{"line_number":412,"context_line":"\"\"\"),"},{"line_number":413,"context_line":"    cfg.BoolOpt(\u0027at_startup_skip_cpu_compare\u0027,"},{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"}],"source_content_type":"text/x-python","patch_set":3,"id":"94ddbe52_137bc883","line":413,"updated":"2023-01-18 11:34:37.000000000","message":"I might call this `skip_cpu_compare_at_startup` to follow the pattern of the flag names here.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"ceea3fa49f5dcc100be1361bd9c44307112940ad","unresolved":true,"context_lines":[{"line_number":410,"context_line":"4.4.0, libvirt will do the correct thing with respect to checking CPU"},{"line_number":411,"context_line":"compatibility on the destination host during live migration."},{"line_number":412,"context_line":"\"\"\"),"},{"line_number":413,"context_line":"    cfg.BoolOpt(\u0027at_startup_skip_cpu_compare\u0027,"},{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"}],"source_content_type":"text/x-python","patch_set":3,"id":"95785fb4_becc0dc2","line":413,"in_reply_to":"94ddbe52_137bc883","updated":"2023-01-18 13:34:33.000000000","message":"Yeah, I also thought that first, I just thought to avoid mixing up one flag with the other in a hurry, I switched it around.  But being consistent makes sense; I\u0027ll rename it.\n\nAlso, I\u0027ll leave the flag name as \"skip_cpu_compare_at_startup\" and not \"skip_first_cpu_compare_at_startup\" (in case we end up wanting to skip the other call too in the future).","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":false,"context_lines":[{"line_number":410,"context_line":"4.4.0, libvirt will do the correct thing with respect to checking CPU"},{"line_number":411,"context_line":"compatibility on the destination host during live migration."},{"line_number":412,"context_line":"\"\"\"),"},{"line_number":413,"context_line":"    cfg.BoolOpt(\u0027at_startup_skip_cpu_compare\u0027,"},{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"}],"source_content_type":"text/x-python","patch_set":3,"id":"c7ae3eca_4727796f","line":413,"in_reply_to":"95785fb4_becc0dc2","updated":"2023-01-23 23:59:23.000000000","message":"Done","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"68350f88ff252750e95875e436a267f58e51eb9d","unresolved":true,"context_lines":[{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"},{"line_number":417,"context_line":"and let libvirt handle it more correctly."},{"line_number":418,"context_line":"\"\"\"),"},{"line_number":419,"context_line":""},{"line_number":420,"context_line":"    cfg.BoolOpt("}],"source_content_type":"text/x-python","patch_set":3,"id":"b4fe944e_7415b6c1","line":417,"updated":"2023-01-18 11:34:37.000000000","message":"This is not what the code actually does. The current code only disables one compare call at startup but not both. So we have to figure out why we have two calls to be able to define what we actually disabling here.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":false,"context_lines":[{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"},{"line_number":417,"context_line":"and let libvirt handle it more correctly."},{"line_number":418,"context_line":"\"\"\"),"},{"line_number":419,"context_line":""},{"line_number":420,"context_line":"    cfg.BoolOpt("}],"source_content_type":"text/x-python","patch_set":3,"id":"8c2af6ee_c2cfebcd","line":417,"in_reply_to":"6bbdcf27_50134aa1","updated":"2023-01-23 23:59:23.000000000","message":"Done","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"ceea3fa49f5dcc100be1361bd9c44307112940ad","unresolved":true,"context_lines":[{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"},{"line_number":417,"context_line":"and let libvirt handle it more correctly."},{"line_number":418,"context_line":"\"\"\"),"},{"line_number":419,"context_line":""},{"line_number":420,"context_line":"    cfg.BoolOpt("}],"source_content_type":"text/x-python","patch_set":3,"id":"fcc57684_c43d6657","line":417,"in_reply_to":"b4fe944e_7415b6c1","updated":"2023-01-18 13:34:33.000000000","message":"Again, true. I should\u0027ve explicitly called out that it skips the _first_ the CPU compare call.\n\nThe second call evaluates the extra CPU flags a user might configure (via `cpu_model_extra_flags`) _and_ the CPU model together: https://github.com/openstack/nova/blob/master/nova/virt/libvirt/driver.py#L1004,#L1018\n\nRetaining the second _compare_cpu() works as confirmed by a real-world test in a Red Hat test environment.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"a4c4988125deb0fedb835d8614e7e7e24d33331d","unresolved":true,"context_lines":[{"line_number":414,"context_line":"               default\u003dFalse,"},{"line_number":415,"context_line":"               help\u003d\"\"\""},{"line_number":416,"context_line":"This will skip the CPU comparison call at start-up of Compute service"},{"line_number":417,"context_line":"and let libvirt handle it more correctly."},{"line_number":418,"context_line":"\"\"\"),"},{"line_number":419,"context_line":""},{"line_number":420,"context_line":"    cfg.BoolOpt("}],"source_content_type":"text/x-python","patch_set":3,"id":"6bbdcf27_50134aa1","line":417,"in_reply_to":"fcc57684_c43d6657","updated":"2023-01-18 13:39:01.000000000","message":"My reading is that the first call is evaluating CPU model only; the second call takes into account both CPU model and extra flags together.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"}],"nova/tests/unit/virt/libvirt/test_driver.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"68350f88ff252750e95875e436a267f58e51eb9d","unresolved":true,"context_lines":[{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (2, 0)"},{"line_number":1341,"context_line":"        self.flags(group\u003d\u0027workarounds\u0027, at_startup_skip_cpu_compare\u003dTrue)"},{"line_number":1342,"context_line":"        self.flags(cpu_mode\u003d\"custom\","},{"line_number":1343,"context_line":"                   cpu_models\u003d[\"Icelake-Server-noTSX\"],"}],"source_content_type":"text/x-python","patch_set":3,"id":"5ce58f02_4bb3e646","line":1340,"updated":"2023-01-18 11:34:37.000000000","message":"I think this test expects that there will be only on call to compare_cpu as the other is disabled. So we only need a single return value here.\n\nAlso you need to assert at the end of the test case that mock_compare only called once and not twice.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"ceea3fa49f5dcc100be1361bd9c44307112940ad","unresolved":true,"context_lines":[{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (2, 0)"},{"line_number":1341,"context_line":"        self.flags(group\u003d\u0027workarounds\u0027, at_startup_skip_cpu_compare\u003dTrue)"},{"line_number":1342,"context_line":"        self.flags(cpu_mode\u003d\"custom\","},{"line_number":1343,"context_line":"                   cpu_models\u003d[\"Icelake-Server-noTSX\"],"}],"source_content_type":"text/x-python","patch_set":3,"id":"f768de45_a4763859","line":1340,"in_reply_to":"5ce58f02_4bb3e646","updated":"2023-01-18 13:34:33.000000000","message":"Thanks!  Will rework.","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"8001aaaf8fd4be4ceda40c903a3519e4998baf60","unresolved":false,"context_lines":[{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (2, 0)"},{"line_number":1341,"context_line":"        self.flags(group\u003d\u0027workarounds\u0027, at_startup_skip_cpu_compare\u003dTrue)"},{"line_number":1342,"context_line":"        self.flags(cpu_mode\u003d\"custom\","},{"line_number":1343,"context_line":"                   cpu_models\u003d[\"Icelake-Server-noTSX\"],"}],"source_content_type":"text/x-python","patch_set":3,"id":"fb123303_8f7aa60b","line":1340,"in_reply_to":"f768de45_a4763859","updated":"2023-01-19 13:01:15.000000000","message":"Fixed in v4","commit_id":"6885b0ac7edef66b9dd35b6dec32971f94a7adaf"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"db1e2e33ebaaa524666b68709de9296da2940194","unresolved":false,"context_lines":[{"line_number":1334,"context_line":"                       \u0027_register_all_undefined_instance_details\u0027,"},{"line_number":1335,"context_line":"                       new\u003dmock.Mock())"},{"line_number":1336,"context_line":"    @mock.patch(\u0027nova.virt.libvirt.host.libvirt.Connection.compareCPU\u0027)"},{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (1, 0)"}],"source_content_type":"text/x-python","patch_set":6,"id":"8be3bf6a_55d6ca4d","line":1337,"range":{"start_line":1337,"start_character":12,"end_line":1337,"end_character":14},"updated":"2023-01-20 14:17:46.000000000","message":"micronit: in general, I don\u0027t like to have two underscores for a test name but meh OK, we already do it above.","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"8d754e4f4a7de308f2923de206424cff204f87b0","unresolved":false,"context_lines":[{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (1, 0)"},{"line_number":1341,"context_line":"        self.flags(group\u003d\u0027workarounds\u0027, skip_cpu_compare_at_startup\u003dTrue)"},{"line_number":1342,"context_line":"        self.flags(cpu_mode\u003d\"custom\","},{"line_number":1343,"context_line":"                   cpu_models\u003d[\"Icelake-Server-noTSX\"],"}],"source_content_type":"text/x-python","patch_set":6,"id":"9fe70c68_d4eeaa5a","line":1340,"range":{"start_line":1340,"start_character":8,"end_line":1340,"end_character":43},"updated":"2023-01-19 13:51:13.000000000","message":"nit: this could have been\n    mock_compare.return_value \u003d 1","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"db1e2e33ebaaa524666b68709de9296da2940194","unresolved":false,"context_lines":[{"line_number":1337,"context_line":"    def test__check_cpu_compatibility_skip_first_compare_at_init("},{"line_number":1338,"context_line":"            self, mocked_compare"},{"line_number":1339,"context_line":"    ):"},{"line_number":1340,"context_line":"        mocked_compare.side_effect \u003d (1, 0)"},{"line_number":1341,"context_line":"        self.flags(group\u003d\u0027workarounds\u0027, skip_cpu_compare_at_startup\u003dTrue)"},{"line_number":1342,"context_line":"        self.flags(cpu_mode\u003d\"custom\","},{"line_number":1343,"context_line":"                   cpu_models\u003d[\"Icelake-Server-noTSX\"],"}],"source_content_type":"text/x-python","patch_set":6,"id":"11ad7392_e10dd3d4","line":1340,"range":{"start_line":1340,"start_character":8,"end_line":1340,"end_character":43},"in_reply_to":"9fe70c68_d4eeaa5a","updated":"2023-01-20 14:17:46.000000000","message":"yeah, now we only call the compareCPU once.","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"db1e2e33ebaaa524666b68709de9296da2940194","unresolved":false,"context_lines":[{"line_number":1345,"context_line":"                   group\u003d\"libvirt\")"},{"line_number":1346,"context_line":"        drvr \u003d libvirt_driver.LibvirtDriver(fake.FakeVirtAPI(), True)"},{"line_number":1347,"context_line":"        drvr.init_host(\"dummyhost\")"},{"line_number":1348,"context_line":"        mocked_compare.assert_called_once()"},{"line_number":1349,"context_line":""},{"line_number":1350,"context_line":"    @mock.patch.object(libvirt_driver.LibvirtDriver,"},{"line_number":1351,"context_line":"                       \u0027_register_all_undefined_instance_details\u0027,"}],"source_content_type":"text/x-python","patch_set":6,"id":"9a254915_efcc951d","line":1348,"updated":"2023-01-20 14:17:46.000000000","message":"see...\nnit as well, you could have used assert_called_once_with()","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"db1e2e33ebaaa524666b68709de9296da2940194","unresolved":true,"context_lines":[{"line_number":995,"context_line":"                             \"compatible with host CPU. Please correct your \""},{"line_number":996,"context_line":"                             \"config and try again. %(e)s\") % {"},{"line_number":997,"context_line":"                                \u0027model\u0027: model, \u0027e\u0027: e})"},{"line_number":998,"context_line":"                    raise exception.InvalidCPUInfo(msg)"},{"line_number":999,"context_line":""},{"line_number":1000,"context_line":"        # Use guest CPU model to check the compatibility between guest CPU and"},{"line_number":1001,"context_line":"        # configured extra_flags"}],"source_content_type":"text/x-python","patch_set":6,"id":"0a5443f6_83019bc4","line":998,"updated":"2023-01-20 14:17:46.000000000","message":"OK, given the IRC discussion, I understand why you only skip this check.","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":false,"context_lines":[{"line_number":995,"context_line":"                             \"compatible with host CPU. Please correct your \""},{"line_number":996,"context_line":"                             \"config and try again. %(e)s\") % {"},{"line_number":997,"context_line":"                                \u0027model\u0027: model, \u0027e\u0027: e})"},{"line_number":998,"context_line":"                    raise exception.InvalidCPUInfo(msg)"},{"line_number":999,"context_line":""},{"line_number":1000,"context_line":"        # Use guest CPU model to check the compatibility between guest CPU and"},{"line_number":1001,"context_line":"        # configured extra_flags"}],"source_content_type":"text/x-python","patch_set":6,"id":"98274a70_c5dfc60b","line":998,"in_reply_to":"0a5443f6_83019bc4","updated":"2023-01-23 23:59:23.000000000","message":"this is now outdated so marking resolved","commit_id":"6fe080c7fb00e3ebfb96f2e60bc3e11ecfea853a"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"a9e217530aaca46763329444a8776bc1eb1948d8","unresolved":true,"context_lines":[{"line_number":999,"context_line":"                    msg \u003d (_(\"Configured extra flag: %(flag)s it not correct, \""},{"line_number":1000,"context_line":"                             \"or the host CPU does not support this flag. \""},{"line_number":1001,"context_line":"                             \"Please correct the config and try again. \""},{"line_number":1002,"context_line":"                             \"% (e)s\") % {\u0027flag\u0027: flag, \u0027e\u0027: e})"},{"line_number":1003,"context_line":"                    raise exception.InvalidCPUInfo(msg)"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"    def _check_vtpm_support(self) -\u003e None:"}],"source_content_type":"text/x-python","patch_set":7,"id":"9be883a4_442002c8","line":1002,"range":{"start_line":1002,"start_character":29,"end_line":1002,"end_character":38},"updated":"2023-01-20 15:27:54.000000000","message":"this breaks the format string. It should be %(e)s without the extra space","commit_id":"cd0eccfff4f1ae30c67e8bbd06c798d152267c36"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"b75c4c5216dd685ded312baa1e98ec3cf9c39b45","unresolved":false,"context_lines":[{"line_number":999,"context_line":"                    msg \u003d (_(\"Configured extra flag: %(flag)s it not correct, \""},{"line_number":1000,"context_line":"                             \"or the host CPU does not support this flag. \""},{"line_number":1001,"context_line":"                             \"Please correct the config and try again. \""},{"line_number":1002,"context_line":"                             \"% (e)s\") % {\u0027flag\u0027: flag, \u0027e\u0027: e})"},{"line_number":1003,"context_line":"                    raise exception.InvalidCPUInfo(msg)"},{"line_number":1004,"context_line":""},{"line_number":1005,"context_line":"    def _check_vtpm_support(self) -\u003e None:"}],"source_content_type":"text/x-python","patch_set":7,"id":"f4947e86_dde02fb9","line":1002,"range":{"start_line":1002,"start_character":29,"end_line":1002,"end_character":38},"in_reply_to":"9be883a4_442002c8","updated":"2023-01-20 15:38:44.000000000","message":"Oops! I thought I was careful ... fixed in v8.\n\nThank you!","commit_id":"cd0eccfff4f1ae30c67e8bbd06c798d152267c36"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"175779ee93eeb3d2b18437293268b9636b2bb26e","unresolved":true,"context_lines":[{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            cpu.model \u003d self._host.get_capabilities().host.cpu.model"},{"line_number":992,"context_line":"            for flag in set(x.lower() for x"},{"line_number":993,"context_line":"                            in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":994,"context_line":"                cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":995,"context_line":"                cpu.add_feature(cpu_feature)"}],"source_content_type":"text/x-python","patch_set":8,"id":"f361f853_53939785","line":992,"updated":"2023-01-23 13:37:20.000000000","message":"This means if no cpu_model_extra_flags is configured then no compare_cpu is executed. \n\nAlso it means that if there cpu_model_extra_flags\u003d [\u0027foo\u0027, \u0027bar\u0027] is defined in the config then two compare_cpu calls are made.\n1) with self._host.get_capabilities().host.cpu.model + flag(\u0027foo\u0027)\n2) with self._host.get_capabilities().host.cpu.model + flag(\u0027bar\u0027)\n\nOver IRC Sean stated that:\n14:32 \u003c sean-k-mooney\u003e for example to disable TSX you need to remove two flags\n14:32 \u003c sean-k-mooney\u003e doing it one at a time will fail in that case\n\nbased on this we need to combine all the flags first then do a single compare_cpu call.","commit_id":"01389198cdedf66dc2de0e30831c58f0d8098c7d"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"ecaa33757c46c38bb105a04e14ea833c5bc2c3a5","unresolved":false,"context_lines":[{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            cpu.model \u003d self._host.get_capabilities().host.cpu.model"},{"line_number":992,"context_line":"            for flag in set(x.lower() for x"},{"line_number":993,"context_line":"                            in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":994,"context_line":"                cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":995,"context_line":"                cpu.add_feature(cpu_feature)"}],"source_content_type":"text/x-python","patch_set":8,"id":"503e8393_2ddd4b58","line":992,"in_reply_to":"5911aae2_e054582f","updated":"2023-01-23 14:44:45.000000000","message":"Fixed in PS9. Thank you, both!","commit_id":"01389198cdedf66dc2de0e30831c58f0d8098c7d"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"bbe72d749edef00473752eb26390afb689974650","unresolved":true,"context_lines":[{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            cpu.model \u003d self._host.get_capabilities().host.cpu.model"},{"line_number":992,"context_line":"            for flag in set(x.lower() for x"},{"line_number":993,"context_line":"                            in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":994,"context_line":"                cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":995,"context_line":"                cpu.add_feature(cpu_feature)"}],"source_content_type":"text/x-python","patch_set":8,"id":"5911aae2_e054582f","line":992,"in_reply_to":"8cee1b3c_91453174","updated":"2023-01-23 14:40:58.000000000","message":"Thank you for the suggestion.  A local quick test of the libvirt driver looks reasonable.  I\u0027ll add your suggested-by in the commit message","commit_id":"01389198cdedf66dc2de0e30831c58f0d8098c7d"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"68c25526c14ed9a3e90cf20cd71914b630097733","unresolved":true,"context_lines":[{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            cpu.model \u003d self._host.get_capabilities().host.cpu.model"},{"line_number":992,"context_line":"            for flag in set(x.lower() for x"},{"line_number":993,"context_line":"                            in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":994,"context_line":"                cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":995,"context_line":"                cpu.add_feature(cpu_feature)"}],"source_content_type":"text/x-python","patch_set":8,"id":"8cee1b3c_91453174","line":992,"in_reply_to":"f361f853_53939785","updated":"2023-01-23 13:45:51.000000000","message":"```\n        cpu \u003d vconfig.LibvirtConfigGuestCPU()\n        for model in models:\n            cpu.model \u003d self._get_cpu_model_mapping(model)\n            for flag in set(x.lower() for x in CONF.libvirt.cpu_model_extra_flags):\n              cpu_feature \u003d self._prepare_cpu_flag(flag)\n              cpu.add_feature(cpu_feature)\n            try:\n                self._compare_cpu(cpu, self._get_cpu_info(), None)\n            except exception.InvalidCPUInfo as e:\n                msg \u003d (_(\"Configured CPU model: %(model)s \"\n                         \"and CPU Flags %(flags)s ar not \"\n                         \"compatible with host CPU. Please correct your \"\n                         \"config and try again. %(e)s\") % {\n                            \u0027model\u0027: model, \u0027e\u0027: e,\n                            \u0027flags\u0027: CONF.libvirt.cpu_model_extra_flags})\n                raise exception.InvalidCPUInfo(msg)\n```\n\ni think this is the correct code we should replace this with\n\nand optionally we could wrap that in the workarounbd\n\n if not CONF.workarounds.skip_cpu_compare_at_startup:\n ...","commit_id":"01389198cdedf66dc2de0e30831c58f0d8098c7d"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":true,"context_lines":[{"line_number":987,"context_line":"        if not CONF.workarounds.skip_cpu_compare_at_startup:"},{"line_number":988,"context_line":"            # Use guest CPU model to check the compatibility between"},{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            for model in models:"},{"line_number":992,"context_line":"                cpu.model \u003d self._get_cpu_model_mapping(model)"},{"line_number":993,"context_line":"                for flag in set(x.lower() for"}],"source_content_type":"text/x-python","patch_set":9,"id":"fa6d6446_9db9766b","line":990,"updated":"2023-01-23 23:59:23.000000000","message":"so this is a bug in the example code i provded.\nsince we are modifying the cpu when there are cpu flags we need to move this to inside the for loop","commit_id":"93847aaf3a5bb64bf3d15423432fd3d9b80e80c3"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"a4d17934e8df0d7f05a16b054995fb03592b7914","unresolved":false,"context_lines":[{"line_number":987,"context_line":"        if not CONF.workarounds.skip_cpu_compare_at_startup:"},{"line_number":988,"context_line":"            # Use guest CPU model to check the compatibility between"},{"line_number":989,"context_line":"            # guest CPU and configured extra_flags"},{"line_number":990,"context_line":"            cpu \u003d vconfig.LibvirtConfigGuestCPU()"},{"line_number":991,"context_line":"            for model in models:"},{"line_number":992,"context_line":"                cpu.model \u003d self._get_cpu_model_mapping(model)"},{"line_number":993,"context_line":"                for flag in set(x.lower() for"}],"source_content_type":"text/x-python","patch_set":9,"id":"4b29ce55_f0d0ef67","line":990,"in_reply_to":"fa6d6446_9db9766b","updated":"2023-01-24 10:28:30.000000000","message":"Oops, good catch.  Fixing in PS:10","commit_id":"93847aaf3a5bb64bf3d15423432fd3d9b80e80c3"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"16b26fb02319f3d5c39dad5ff49222c334363426","unresolved":true,"context_lines":[{"line_number":993,"context_line":"                for flag in set(x.lower() for"},{"line_number":994,"context_line":"                                x in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":995,"context_line":"                    cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":996,"context_line":"                    cpu.add_feature(cpu_feature)"},{"line_number":997,"context_line":"                try:"},{"line_number":998,"context_line":"                    self._compare_cpu(cpu, self._get_cpu_info(), None)"},{"line_number":999,"context_line":"                except exception.InvalidCPUInfo as e:"}],"source_content_type":"text/x-python","patch_set":9,"id":"835aa14e_605363c8","line":996,"updated":"2023-01-23 23:59:23.000000000","message":"if we dont move the cpu asginemnt to line 992 insead the first for loop this will keep appendign the same feature over and over again.\n\nthat likely wont break anything but its wasting memory so can you move line 990 to 992","commit_id":"93847aaf3a5bb64bf3d15423432fd3d9b80e80c3"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"a4d17934e8df0d7f05a16b054995fb03592b7914","unresolved":false,"context_lines":[{"line_number":993,"context_line":"                for flag in set(x.lower() for"},{"line_number":994,"context_line":"                                x in CONF.libvirt.cpu_model_extra_flags):"},{"line_number":995,"context_line":"                    cpu_feature \u003d self._prepare_cpu_flag(flag)"},{"line_number":996,"context_line":"                    cpu.add_feature(cpu_feature)"},{"line_number":997,"context_line":"                try:"},{"line_number":998,"context_line":"                    self._compare_cpu(cpu, self._get_cpu_info(), None)"},{"line_number":999,"context_line":"                except exception.InvalidCPUInfo as e:"}],"source_content_type":"text/x-python","patch_set":9,"id":"d180813a_e0c9d446","line":996,"in_reply_to":"835aa14e_605363c8","updated":"2023-01-24 10:28:30.000000000","message":"Yep; fixed in PS:10","commit_id":"93847aaf3a5bb64bf3d15423432fd3d9b80e80c3"}]}
