)]}'
{"nova/tests/unit/virt/libvirt/test_driver.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e451aef4476dcdc19c7f328b058c34d1884514d6","unresolved":false,"context_lines":[{"line_number":5331,"context_line":"    @mock.patch.object(nova.virt.libvirt, \u0027config\u0027)"},{"line_number":5332,"context_line":"    def test_compare_cpu_handles_not_supported_error_gracefully(self,"},{"line_number":5333,"context_line":"                                                                mock_vconfig,"},{"line_number":5334,"context_line":"                                                                mock_conn):"},{"line_number":5335,"context_line":"        not_supported_exc \u003d fakelibvirt.make_libvirtError("},{"line_number":5336,"context_line":"                fakelibvirt.libvirtError,"},{"line_number":5337,"context_line":"                \u0027this function is not supported by the connection driver:\u0027"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_e7186d20","line":5334,"updated":"2015-05-19 15:32:31.000000000","message":"I just noticed this is the stable/kilo name for this parameter, this should have been something like mock_compare like the other tests.","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1112f827365100d728a3f910459b914dc56412cc","unresolved":false,"context_lines":[{"line_number":5337,"context_line":"                \u0027this function is not supported by the connection driver:\u0027"},{"line_number":5338,"context_line":"                \u0027 virCompareCPU\u0027,"},{"line_number":5339,"context_line":"                error_code\u003dfakelibvirt.VIR_ERR_NO_SUPPORT)"},{"line_number":5340,"context_line":"        mock_conn.compareCPU.side_effect \u003d not_supported_exc"},{"line_number":5341,"context_line":"        conn \u003d libvirt_driver.LibvirtDriver(fake.FakeVirtAPI(), False)"},{"line_number":5342,"context_line":"        ret \u003d conn._compare_cpu(None, jsonutils.dumps(_fake_cpu_info))"},{"line_number":5343,"context_line":"        self.assertIsNone(ret)"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_07cee981","line":5340,"updated":"2015-05-19 15:34:48.000000000","message":"This should have just been mock_conn.side_effect \u003d not_supported_exc","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":14358,"name":"Marian Horban","email":"m.horban@gmail.com","username":"mhorban"},"change_message_id":"371fcbdb6cd449fac940b80fb75dee9897f45f8e","unresolved":false,"context_lines":[{"line_number":5140,"context_line":"        try:"},{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu compare: \""},{"line_number":5146,"context_line":"                             \"The cloud admin has to take care that the \""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6ced46_b4127760","line":5143,"updated":"2015-03-23 11:43:30.000000000","message":"Is it possible to use more readable variables than: e, u, m?","commit_id":"a7d19faef5b9a0841fa46680f704be5b28b27104"},{"author":{"_account_id":11303,"name":"Markus Zoeller (markus_z)","email":"mzoeller@linux.vnet.ibm.com","username":"mzoeller"},"change_message_id":"59e9a8de6230ce27e499e9f1f86f321885b29d03","unresolved":false,"context_lines":[{"line_number":5140,"context_line":"        try:"},{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu compare: \""},{"line_number":5146,"context_line":"                             \"The cloud admin has to take care that the \""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6ced46_570065aa","line":5143,"in_reply_to":"1a6ced46_b4127760","updated":"2015-03-23 11:56:35.000000000","message":"@Marian Horban: I wanted to keep the change as minimal as possible, that\u0027s why I don\u0027t want to touch them right now.","commit_id":"a7d19faef5b9a0841fa46680f704be5b28b27104"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"dafaef5064140317d79e840dc195528715a43fc7","unresolved":false,"context_lines":[{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu compare: \""},{"line_number":5146,"context_line":"                             \"The cloud admin has to take care that the \""},{"line_number":5147,"context_line":"                             \"migration target is valid wrt the CPU.\""},{"line_number":5148,"context_line":"                             \"%(error)s\"),"},{"line_number":5149,"context_line":"                             {\u0027uri\u0027: self._host._uri, \u0027error\u0027: e})"},{"line_number":5150,"context_line":"                return"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6ced46_81494962","line":5147,"updated":"2015-03-25 16:31:48.000000000","message":"question: is \u0027wrt\u0027 some kind of abbreviation?\ncan we be more specific?","commit_id":"a7d19faef5b9a0841fa46680f704be5b28b27104"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"ef8e5e6a96e25c9a78034dd17211c8543e1e93eb","unresolved":false,"context_lines":[{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu compare: \""},{"line_number":5146,"context_line":"                             \"The cloud admin has to take care that the \""},{"line_number":5147,"context_line":"                             \"migration target is valid wrt the CPU.\""},{"line_number":5148,"context_line":"                             \"%(error)s\"),"},{"line_number":5149,"context_line":"                             {\u0027uri\u0027: self._host._uri, \u0027error\u0027: e})"},{"line_number":5150,"context_line":"                return"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6ced46_aa5fde3f","line":5147,"in_reply_to":"1a6ced46_4f54bcfe","updated":"2015-03-26 10:12:47.000000000","message":"me too... glad to know this :)","commit_id":"a7d19faef5b9a0841fa46680f704be5b28b27104"},{"author":{"_account_id":11303,"name":"Markus Zoeller (markus_z)","email":"mzoeller@linux.vnet.ibm.com","username":"mzoeller"},"change_message_id":"d34be7d0068ce1c7d4fa15878e987b71d64bbe32","unresolved":false,"context_lines":[{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu compare: \""},{"line_number":5146,"context_line":"                             \"The cloud admin has to take care that the \""},{"line_number":5147,"context_line":"                             \"migration target is valid wrt the CPU.\""},{"line_number":5148,"context_line":"                             \"%(error)s\"),"},{"line_number":5149,"context_line":"                             {\u0027uri\u0027: self._host._uri, \u0027error\u0027: e})"},{"line_number":5150,"context_line":"                return"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6ced46_4f54bcfe","line":5147,"in_reply_to":"1a6ced46_81494962","updated":"2015-03-26 09:29:01.000000000","message":"@jichenjc: I know it as abbreviation for \"with regard to\". I\u0027m not a English native speaker, so sorry for the confusion.","commit_id":"a7d19faef5b9a0841fa46680f704be5b28b27104"},{"author":{"_account_id":11303,"name":"Markus Zoeller (markus_z)","email":"mzoeller@linux.vnet.ibm.com","username":"mzoeller"},"change_message_id":"e6eb72adcc9f1acd6e9fb614769987958c3fa27e","unresolved":false,"context_lines":[{"line_number":5138,"context_line":"        m \u003d _(\"CPU doesn\u0027t have compatibility.\\n\\n%(ret)s\\n\\nRefer to %(u)s\")"},{"line_number":5139,"context_line":"        # unknown character exists in xml, then libvirt complains"},{"line_number":5140,"context_line":"        try:"},{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a6ced46_ef0008ad","line":5141,"updated":"2015-03-26 09:33:45.000000000","message":"I have a more general question here. If the nova.conf sets \"cpu_mode\u003dnone\" should the \"compareCPU\" even get called?","commit_id":"2103bd7263616e50a4307b30a45b6b0ee25a0c45"},{"author":{"_account_id":9466,"name":"Sean Severson","email":"sseverson@hpe.com","username":"sseverson"},"change_message_id":"da31ff90513c954437dded5762fe2cdb6bcfebb4","unresolved":false,"context_lines":[{"line_number":5138,"context_line":"        m \u003d _(\"CPU doesn\u0027t have compatibility.\\n\\n%(ret)s\\n\\nRefer to %(u)s\")"},{"line_number":5139,"context_line":"        # unknown character exists in xml, then libvirt complains"},{"line_number":5140,"context_line":"        try:"},{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"}],"source_content_type":"text/x-python","patch_set":2,"id":"fa963961_c92ac22c","line":5141,"in_reply_to":"1a6ced46_ef0008ad","updated":"2015-03-26 15:57:56.000000000","message":"The compare should definitely be called. Think about what the ramifications could be if one node is \"none\" and another node actually has a value.","commit_id":"2103bd7263616e50a4307b30a45b6b0ee25a0c45"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"1d52d066b98bbaa9fb72bd626d8de19ca4ad01c3","unresolved":false,"context_lines":[{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu comparison. \""},{"line_number":5146,"context_line":"                             \"It will be proceeded though. Error: %(error)s\"),"},{"line_number":5147,"context_line":"                             {\u0027uri\u0027: self.uri(), \u0027error\u0027: e})"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa53dc9_dc00e503","line":5144,"updated":"2015-04-08 12:49:23.000000000","message":"It seems like there is not need to log a warn message here, as its expected behaviour for certain drivers.\n\nMaybe go for a debug message to avoid the string freeze?","commit_id":"2103bd7263616e50a4307b30a45b6b0ee25a0c45"},{"author":{"_account_id":11303,"name":"Markus Zoeller (markus_z)","email":"mzoeller@linux.vnet.ibm.com","username":"mzoeller"},"change_message_id":"4cdc5398427e7c724b6a1522366062b0489a11d7","unresolved":false,"context_lines":[{"line_number":5141,"context_line":"            ret \u003d self._conn.compareCPU(cpu.to_xml(), 0)"},{"line_number":5142,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5143,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5144,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5145,"context_line":"                LOG.warn(_LW(\"URI %(uri)s does not support cpu comparison. \""},{"line_number":5146,"context_line":"                             \"It will be proceeded though. Error: %(error)s\"),"},{"line_number":5147,"context_line":"                             {\u0027uri\u0027: self.uri(), \u0027error\u0027: e})"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa53dc9_82b438d1","line":5144,"in_reply_to":"9aa53dc9_dc00e503","updated":"2015-04-08 13:38:03.000000000","message":"@John Garbutt: Yes, you are right, a cloud admin should be aware of the underlying hypervisors and their capabilities. According to the logging guidelines [1][2] this log does not fall into the WARN category. I will change it.\n\n[1] https://wiki.openstack.org/wiki/Security/Guidelines/logging_guidelines\n\n[2] https://github.com/openstack/openstack-specs/blob/master/specs/log-guidelines.rst","commit_id":"2103bd7263616e50a4307b30a45b6b0ee25a0c45"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1d8720296f612f4b7a19c0e350ea413678c091a0","unresolved":false,"context_lines":[{"line_number":494,"context_line":"        configurations to indicate to administrators that the quality is"},{"line_number":495,"context_line":"        unknown. Currently, only qemu or kvm on intel 32- or 64-bit systems"},{"line_number":496,"context_line":"        is tested upstream."},{"line_number":497,"context_line":"        \"\"\""},{"line_number":498,"context_line":"        caps \u003d self._host.get_capabilities()"},{"line_number":499,"context_line":"        hostarch \u003d caps.host.cpu.arch"},{"line_number":500,"context_line":"        if (CONF.libvirt.virt_type not in (\u0027qemu\u0027, \u0027kvm\u0027) or"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_3fcf17b2","line":497,"updated":"2015-05-14 19:42:08.000000000","message":"I\u0027m confused, in the bug report you link to the baselineCPU call in get_capabilities as being a problem:\n\nhttps://github.com/openstack/nova/blob/master/nova/virt/libvirt/host.py#L761\n\nBut that\u0027s not being changed in this patch, so how is that related?  Or does zkvm not have the VIR_CONNECT_BASELINE_CPU_EXPAND_FEATURES flag?","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e7c46299bc75f5f346340c1875a93186d151ad70","unresolved":false,"context_lines":[{"line_number":494,"context_line":"        configurations to indicate to administrators that the quality is"},{"line_number":495,"context_line":"        unknown. Currently, only qemu or kvm on intel 32- or 64-bit systems"},{"line_number":496,"context_line":"        is tested upstream."},{"line_number":497,"context_line":"        \"\"\""},{"line_number":498,"context_line":"        caps \u003d self._host.get_capabilities()"},{"line_number":499,"context_line":"        hostarch \u003d caps.host.cpu.arch"},{"line_number":500,"context_line":"        if (CONF.libvirt.virt_type not in (\u0027qemu\u0027, \u0027kvm\u0027) or"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_7107ea1c","line":497,"in_reply_to":"7a016987_3fcf17b2","updated":"2015-05-15 12:55:15.000000000","message":"I think you\u0027re mis-reading the bug - the first paragraph in the bug is saying that the code should check for failure of compareCPU, in the same way that nova already checks for failure of baselineCPU. ie currently baselineCPU code catches \u0026 ignores VIR_ERR_NO_SUPPORT, and thus compareCPU should do too.","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1d8720296f612f4b7a19c0e350ea413678c091a0","unresolved":false,"context_lines":[{"line_number":5149,"context_line":"            ret \u003d self._host.compare_cpu(cpu.to_xml())"},{"line_number":5150,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5151,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5152,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5153,"context_line":"                LOG.debug(\"URI %(uri)s does not support cpu comparison. \""},{"line_number":5154,"context_line":"                          \"It will be proceeded though. Error: %(error)s\","},{"line_number":5155,"context_line":"                          {\u0027uri\u0027: self.uri(), \u0027error\u0027: e})"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_3f871711","line":5152,"updated":"2015-05-14 19:42:08.000000000","message":"I think this needs to be more conditional since we\u0027re basically ignoring an error condition and proceeding with the live migration attempt anyway.  Maybe this is where the [workarounds] group comes in for the bug, but I don\u0027t think a config option is probably necessary.\n\nThe thing is, we basically have a condition where we have to say if you\u0027re on s390/s390x and a certain version of qemu (before whatever version gets the s390x cpu model implementation), then ignore the error and risk-assume you\u0027re OK with a TODO in the code that says remove this when we\u0027re at some x version of QEMU that has the support (to be updated later when that\u0027s committed and released).\n\nI think right now, today, we at least need a platform conditional check here such that we only do this for s390x.","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e7c46299bc75f5f346340c1875a93186d151ad70","unresolved":false,"context_lines":[{"line_number":5149,"context_line":"            ret \u003d self._host.compare_cpu(cpu.to_xml())"},{"line_number":5150,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5151,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5152,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5153,"context_line":"                LOG.debug(\"URI %(uri)s does not support cpu comparison. \""},{"line_number":5154,"context_line":"                          \"It will be proceeded though. Error: %(error)s\","},{"line_number":5155,"context_line":"                          {\u0027uri\u0027: self.uri(), \u0027error\u0027: e})"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_f4574800","line":5152,"in_reply_to":"7a016987_3f871711","updated":"2015-05-15 12:55:15.000000000","message":"I disagree actually - if we made it conditional on s390, we\u0027re basically guaranteeing that other libvirt/hypervisor/arch combinations with the same bug will result in nova still being buggy.  Checking only the VIR_ERR_NO_SUPPORT code is actually the correct thing todo here, as that error code is a reliable indicator of the the fact that the platform doesn\u0027t support upfront CPU compat comparisons. This matches what we do for exception handling in the baselineCPU method too, which is important as we want consistency across the two cases.","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"53aac882b316488755167cd797a1b47ea953676a","unresolved":false,"context_lines":[{"line_number":5149,"context_line":"            ret \u003d self._host.compare_cpu(cpu.to_xml())"},{"line_number":5150,"context_line":"        except libvirt.libvirtError as e:"},{"line_number":5151,"context_line":"            error_code \u003d e.get_error_code()"},{"line_number":5152,"context_line":"            if error_code \u003d\u003d libvirt.VIR_ERR_NO_SUPPORT:"},{"line_number":5153,"context_line":"                LOG.debug(\"URI %(uri)s does not support cpu comparison. \""},{"line_number":5154,"context_line":"                          \"It will be proceeded though. Error: %(error)s\","},{"line_number":5155,"context_line":"                          {\u0027uri\u0027: self.uri(), \u0027error\u0027: e})"}],"source_content_type":"text/x-python","patch_set":5,"id":"7a016987_8cba276d","line":5152,"in_reply_to":"7a016987_f4574800","updated":"2015-05-17 19:04:13.000000000","message":"OK, I wasn\u0027t making the connection to baselineCPU here. Thanks for clarifying.","commit_id":"da9301fbc7877529bc2b099ffeb622e02ef54f0e"}]}
