)]}'
{"nova/api/openstack/compute/servers.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"d7c5fa0917603d6a0713c0a0955e058bf7420ce8","unresolved":false,"context_lines":[{"line_number":57,"context_line":"INVALID_FLAVOR_IMAGE_EXCEPTIONS \u003d ("},{"line_number":58,"context_line":"    exception.BadRequirementEmulatorThreadsPolicy,"},{"line_number":59,"context_line":"    exception.CPUThreadPolicyConfigurationInvalid,"},{"line_number":60,"context_line":"    exception.FlavorImageConflict,"},{"line_number":61,"context_line":"    exception.ImageCPUPinningForbidden,"},{"line_number":62,"context_line":"    exception.ImageCPUThreadPolicyForbidden,"},{"line_number":63,"context_line":"    exception.ImageNUMATopologyAsymmetric,"}],"source_content_type":"text/x-python","patch_set":4,"id":"7faddb67_32a70253","line":60,"range":{"start_line":60,"start_character":14,"end_line":60,"end_character":33},"updated":"2019-09-04 19:41:33.000000000","message":"because this","commit_id":"b051e8e836689230e2da613bb5842a141516d98d"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"d7c5fa0917603d6a0713c0a0955e058bf7420ce8","unresolved":false,"context_lines":[{"line_number":75,"context_line":"    exception.InvalidCPUAllocationPolicy,"},{"line_number":76,"context_line":"    exception.InvalidCPUThreadAllocationPolicy,"},{"line_number":77,"context_line":"    exception.InvalidEmulatorThreadsPolicy,"},{"line_number":78,"context_line":"    exception.InvalidMachineType,"},{"line_number":79,"context_line":"    exception.InvalidNUMANodesNumber,"},{"line_number":80,"context_line":"    exception.InvalidRequest,"},{"line_number":81,"context_line":"    exception.MemoryPageSizeForbidden,"}],"source_content_type":"text/x-python","patch_set":4,"id":"7faddb67_1266862a","line":78,"range":{"start_line":78,"start_character":14,"end_line":78,"end_character":32},"updated":"2019-09-04 19:41:33.000000000","message":"you wouldn\u0027t need this","commit_id":"b051e8e836689230e2da613bb5842a141516d98d"}],"nova/exception.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"346b41c2c584f1f5324030966676ff936b013913","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 was requested for image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s) but %(reason)s\")"},{"line_number":1983,"context_line":""},{"line_number":1984,"context_line":""},{"line_number":1985,"context_line":"class InvalidVirtualMachineMode(Invalid):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_34aa9583","line":1982,"range":{"start_line":1982,"start_character":47,"end_line":1982,"end_character":61},"updated":"2019-09-04 15:37:48.000000000","message":"This is bad for translators. Suggest something more like:\n\n\"Machine type X is not compatible with image Y (Z): %(reason)s\"","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"d7c5fa0917603d6a0713c0a0955e058bf7420ce8","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 was requested for image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s) but %(reason)s\")"},{"line_number":1983,"context_line":""},{"line_number":1984,"context_line":""},{"line_number":1985,"context_line":"class InvalidVirtualMachineMode(Invalid):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_d29d4e09","line":1982,"range":{"start_line":1982,"start_character":47,"end_line":1982,"end_character":61},"in_reply_to":"7faddb67_1410b958","updated":"2019-09-04 19:41:33.000000000","message":"\u003e something doesn\u0027t feel quite right with\n \u003e the word \"compatible\"\n\n\"valid\" would be fine too. Or s/is not \\w+/conflicts/. Whatevs.","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"1b7466e8072bd1598c35818e4f716ff5a1c25c98","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 was requested for image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s) but %(reason)s\")"},{"line_number":1983,"context_line":""},{"line_number":1984,"context_line":""},{"line_number":1985,"context_line":"class InvalidVirtualMachineMode(Invalid):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_6f3a7698","line":1982,"range":{"start_line":1982,"start_character":47,"end_line":1982,"end_character":61},"in_reply_to":"7faddb67_34aa9583","updated":"2019-09-04 16:36:14.000000000","message":"Done","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"94277b4b1b8e57db49f33673032c60451401085d","unresolved":false,"context_lines":[{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 was requested for image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s) but %(reason)s\")"},{"line_number":1983,"context_line":""},{"line_number":1984,"context_line":""},{"line_number":1985,"context_line":"class InvalidVirtualMachineMode(Invalid):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_1410b958","line":1982,"range":{"start_line":1982,"start_character":47,"end_line":1982,"end_character":61},"in_reply_to":"7faddb67_34aa9583","updated":"2019-09-04 15:58:13.000000000","message":"Yeah, makes sense.  (Also something doesn\u0027t feel quite right with the word \"compatible\", but I can\u0027t think of any better; so I\u0027m fine sticking with it.)","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"346b41c2c584f1f5324030966676ff936b013913","unresolved":false,"context_lines":[{"line_number":1977,"context_line":"                \"recognised\")"},{"line_number":1978,"context_line":""},{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 was requested for image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s) but %(reason)s\")"},{"line_number":1983,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"7faddb67_14319959","line":1980,"range":{"start_line":1980,"start_character":6,"end_line":1980,"end_character":24},"updated":"2019-09-04 15:37:48.000000000","message":"wouldn\u0027t be crazy to make this a subclass of FlavorImageConflict","commit_id":"9a20cd0e1222236a79597ede156b3f3cf6a82140"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"d7c5fa0917603d6a0713c0a0955e058bf7420ce8","unresolved":false,"context_lines":[{"line_number":1977,"context_line":"                \"recognised\")"},{"line_number":1978,"context_line":""},{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 is not compatible with image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s): %(reason)s\")"},{"line_number":1983,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"7faddb67_d26b0eed","line":1980,"range":{"start_line":1980,"start_character":6,"end_line":1980,"end_character":24},"updated":"2019-09-04 19:41:33.000000000","message":"if this was a subclass of FlavorImageConflict","commit_id":"b051e8e836689230e2da613bb5842a141516d98d"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"b97d01637152510c8e63a6240e8eff803acd772b","unresolved":false,"context_lines":[{"line_number":1977,"context_line":"                \"recognised\")"},{"line_number":1978,"context_line":""},{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 is not compatible with image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s): %(reason)s\")"},{"line_number":1983,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_560ef4e5","line":1980,"range":{"start_line":1980,"start_character":6,"end_line":1980,"end_character":24},"updated":"2019-09-06 16:51:13.000000000","message":"I mentioned this before, but is there a reason we shouldn\u0027t make this a subclass of FlavorImageConflict?\n\nAs currently worded, that doesn\u0027t gel; but as used, it does.","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"a5bc5bb0a0231d88077093c4eb91362bc473d533","unresolved":false,"context_lines":[{"line_number":1977,"context_line":"                \"recognised\")"},{"line_number":1978,"context_line":""},{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 is not compatible with image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s): %(reason)s\")"},{"line_number":1983,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_c86239d9","line":1980,"range":{"start_line":1980,"start_character":6,"end_line":1980,"end_character":24},"in_reply_to":"5faad753_0d5f0342","updated":"2019-09-06 19:59:05.000000000","message":"I can buy this argument, thanks for indulging me and explaining it.","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"fd765b0efb9218ef2fe2ad351e1b3352ece701af","unresolved":false,"context_lines":[{"line_number":1977,"context_line":"                \"recognised\")"},{"line_number":1978,"context_line":""},{"line_number":1979,"context_line":""},{"line_number":1980,"context_line":"class InvalidMachineType(Invalid):"},{"line_number":1981,"context_line":"    msg_fmt \u003d _(\"Machine type \u0027%(mtype)s\u0027 is not compatible with image \""},{"line_number":1982,"context_line":"                \"%(image_name)s (%(image_id)s): %(reason)s\")"},{"line_number":1983,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_0d5f0342","line":1980,"range":{"start_line":1980,"start_character":6,"end_line":1980,"end_character":24},"in_reply_to":"5faad753_560ef4e5","updated":"2019-09-06 19:51:12.000000000","message":"Consider this case:\n\n- The image has hw_mem_encryption\u003dTrue and hw_firmware_type\u003duefi but no hw_machine_type.\n- The SEV compute host has CONF.libvirt.hw_machine_type set to \u0027x86_64\u003dpc\u0027.\n\nIn that case, the conflict has nothing whatsoever to do with the flavor.  So making it a subclass of FlavorImageConflict doesn\u0027t feel right to me.  The real conflict is between the request for SEV (wherever it came from), and the calculated machine type (wherever it came from).  That may or may not involve flavors.\n\nIn fact it even may or may not involve images: imagine where the flavor has hw:mem_encryption\u003dTrue and the image only has hw_firmware_type\u003duefi.  In that case the conflict is nothing to do with the image.\n\nGranted, there\u0027s an argument that the *absence* of hw_machine_type on the image is part of the conflict.  But in the first case I gave, this still doesn\u0027t involve flavors at all.\n\nBTW I didn\u0027t make the exception SEV-specific because I figured there might be other unrelated occasions in the future where a certain machine type (or lack thereof) causes a conflict.  Maybe Kashyap can anticipate such potential scenarios.","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"}],"nova/tests/unit/virt/test_hardware.py":[{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"94277b4b1b8e57db49f33673032c60451401085d","unresolved":false,"context_lines":[{"line_number":3822,"context_line":"        self.assertEqual(self.expected_error % error_data, str(exc))"},{"line_number":3823,"context_line":""},{"line_number":3824,"context_line":""},{"line_number":3825,"context_line":"class MemEncryptionRequestedWithoutUEFITestCase("},{"line_number":3826,"context_line":"        MemEncryptionRequestedMissingImagePropTestCase):"},{"line_number":3827,"context_line":"    expected_exception \u003d exception.FlavorImageConflict"},{"line_number":3828,"context_line":"    expected_error \u003d ("}],"source_content_type":"text/x-python","patch_set":2,"id":"7faddb67_ef0d0635","line":3825,"range":{"start_line":3825,"start_character":6,"end_line":3825,"end_character":47},"updated":"2019-09-04 15:58:13.000000000","message":"Nice","commit_id":"9a20cd0e1222236a79597ede156b3f3cf6a82140"}],"nova/virt/hardware.py":[{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"94277b4b1b8e57db49f33673032c60451401085d","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"    raise exception.FlavorImageConflict(emsg % data)"},{"line_number":1230,"context_line":""},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"def _check_mem_encryption_machine_type(image_meta):"},{"line_number":1233,"context_line":"    # NOTE(aspiers): As explained in the SEV spec, SEV needs a q35"},{"line_number":1234,"context_line":"    # machine type in order to bind all the virtio devices to the PCIe"},{"line_number":1235,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_14e679b1","line":1232,"range":{"start_line":1232,"start_character":4,"end_line":1232,"end_character":38},"updated":"2019-09-04 15:58:13.000000000","message":"Okay, I see that you\u0027ve clubbed all the mem_encryption-/SEV- related checks together.\n\n(Per our previous discussion, thought you might put this in utils.py; but it does make sense here.)","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"1b7466e8072bd1598c35818e4f716ff5a1c25c98","unresolved":false,"context_lines":[{"line_number":1229,"context_line":"    raise exception.FlavorImageConflict(emsg % data)"},{"line_number":1230,"context_line":""},{"line_number":1231,"context_line":""},{"line_number":1232,"context_line":"def _check_mem_encryption_machine_type(image_meta):"},{"line_number":1233,"context_line":"    # NOTE(aspiers): As explained in the SEV spec, SEV needs a q35"},{"line_number":1234,"context_line":"    # machine type in order to bind all the virtio devices to the PCIe"},{"line_number":1235,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_ef450616","line":1232,"range":{"start_line":1232,"start_character":4,"end_line":1232,"end_character":38},"in_reply_to":"7faddb67_14e679b1","updated":"2019-09-04 16:36:14.000000000","message":"Changed my mind after discussion with Eric yesterday:\n\nhttp://eavesdrop.openstack.org/irclogs/%23openstack-nova/%23openstack-nova.2019-09-03.log.html#t2019-09-03T21:38:14","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":6962,"name":"Kashyap Chamarthy","email":"kchamart@redhat.com","username":"kashyapc"},"change_message_id":"94277b4b1b8e57db49f33673032c60451401085d","unresolved":false,"context_lines":[{"line_number":1245,"context_line":"    raise exception.InvalidMachineType("},{"line_number":1246,"context_line":"        mtype\u003dmach_type,"},{"line_number":1247,"context_line":"        image_id\u003dimage_meta.id, image_name\u003dimage_meta.name,"},{"line_number":1248,"context_line":"        reason\u003d\"q35 type is required in order to ensure SEV works\")"},{"line_number":1249,"context_line":""},{"line_number":1250,"context_line":""},{"line_number":1251,"context_line":"def _get_numa_pagesize_constraint(flavor, image_meta):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_74f32d74","line":1248,"range":{"start_line":1248,"start_character":16,"end_line":1248,"end_character":66},"updated":"2019-09-04 15:58:13.000000000","message":"Nit: \"Q35 machine type is required for SEV to work\")","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"1b7466e8072bd1598c35818e4f716ff5a1c25c98","unresolved":false,"context_lines":[{"line_number":1245,"context_line":"    raise exception.InvalidMachineType("},{"line_number":1246,"context_line":"        mtype\u003dmach_type,"},{"line_number":1247,"context_line":"        image_id\u003dimage_meta.id, image_name\u003dimage_meta.name,"},{"line_number":1248,"context_line":"        reason\u003d\"q35 type is required in order to ensure SEV works\")"},{"line_number":1249,"context_line":""},{"line_number":1250,"context_line":""},{"line_number":1251,"context_line":"def _get_numa_pagesize_constraint(flavor, image_meta):"}],"source_content_type":"text/x-python","patch_set":1,"id":"7faddb67_8f69f28c","line":1248,"range":{"start_line":1248,"start_character":16,"end_line":1248,"end_character":66},"in_reply_to":"7faddb67_74f32d74","updated":"2019-09-04 16:36:14.000000000","message":"Done, although as agreed on IRC we\u0027ll keep it lowercase.","commit_id":"d2a3e80fcb7fb411614b5ccec061195402e59074"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"415c0e291a441179f87769376c6dac305681fe0c","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from nova.i18n import _"},{"line_number":28,"context_line":"from nova import objects"},{"line_number":29,"context_line":"from nova.objects import fields"},{"line_number":30,"context_line":"from nova.virt.libvirt import utils as libvirt_utils"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"CONF \u003d nova.conf.CONF"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_e8972bea","line":30,"range":{"start_line":30,"start_character":0,"end_line":30,"end_character":52},"updated":"2019-09-05 12:26:41.000000000","message":"we could remove this then also breaking the circular dependency and any depency on the  driver directly","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"ac8133b826eae8c1231bb0ea60e72813c4b735ff","unresolved":false,"context_lines":[{"line_number":27,"context_line":"from nova.i18n import _"},{"line_number":28,"context_line":"from nova import objects"},{"line_number":29,"context_line":"from nova.objects import fields"},{"line_number":30,"context_line":"from nova.virt.libvirt import utils as libvirt_utils"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"CONF \u003d nova.conf.CONF"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_82dbeb4b","line":30,"range":{"start_line":30,"start_character":0,"end_line":30,"end_character":52},"in_reply_to":"7faddb67_e8972bea","updated":"2019-09-05 17:48:14.000000000","message":"Done in next PS.","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"c5fd5b76d1d1aeec44fd2b874a1fa982f1a075e9","unresolved":false,"context_lines":[{"line_number":1234,"context_line":"    raise exception.FlavorImageConflict(emsg % data)"},{"line_number":1235,"context_line":""},{"line_number":1236,"context_line":""},{"line_number":1237,"context_line":"def _check_mem_encryption_machine_type(image_meta):"},{"line_number":1238,"context_line":"    # NOTE(aspiers): As explained in the SEV spec, SEV needs a q35"},{"line_number":1239,"context_line":"    # machine type in order to bind all the virtio devices to the PCIe"},{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_88ad5785","line":1237,"range":{"start_line":1237,"start_character":4,"end_line":1237,"end_character":51},"updated":"2019-09-05 12:24:17.000000000","message":"_check_mem_encryption_machine_type(image_meta, machine_type\u003dNone):\n\nin driver.py you can pass in the machine type you get form calling\n\n libvirt_utils.get_machine_type(image_meta) as the machine_type","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"ac8133b826eae8c1231bb0ea60e72813c4b735ff","unresolved":false,"context_lines":[{"line_number":1234,"context_line":"    raise exception.FlavorImageConflict(emsg % data)"},{"line_number":1235,"context_line":""},{"line_number":1236,"context_line":""},{"line_number":1237,"context_line":"def _check_mem_encryption_machine_type(image_meta):"},{"line_number":1238,"context_line":"    # NOTE(aspiers): As explained in the SEV spec, SEV needs a q35"},{"line_number":1239,"context_line":"    # machine type in order to bind all the virtio devices to the PCIe"},{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_a23627b3","line":1237,"range":{"start_line":1237,"start_character":4,"end_line":1237,"end_character":51},"in_reply_to":"7faddb67_88ad5785","updated":"2019-09-05 17:48:14.000000000","message":"Nice idea - I\u0027ll add the optional parameter in the following commit which actually uses it.","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"d04279a1088984bb14b8d1785e8ae164f6d72254","unresolved":false,"context_lines":[{"line_number":1234,"context_line":"    raise exception.FlavorImageConflict(emsg % data)"},{"line_number":1235,"context_line":""},{"line_number":1236,"context_line":""},{"line_number":1237,"context_line":"def _check_mem_encryption_machine_type(image_meta):"},{"line_number":1238,"context_line":"    # NOTE(aspiers): As explained in the SEV spec, SEV needs a q35"},{"line_number":1239,"context_line":"    # machine type in order to bind all the virtio devices to the PCIe"},{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"}],"source_content_type":"text/x-python","patch_set":6,"id":"5faad753_c26c639e","line":1237,"range":{"start_line":1237,"start_character":4,"end_line":1237,"end_character":51},"in_reply_to":"7faddb67_a23627b3","updated":"2019-09-06 10:54:07.000000000","message":"Now done in https://review.opendev.org/#/c/644565/52/nova/virt/hardware.py","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"c5fd5b76d1d1aeec44fd2b874a1fa982f1a075e9","unresolved":false,"context_lines":[{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"},{"line_number":1241,"context_line":"    # QEMU\u0027s iommu_platform feature was added in virtio 1.0 only:"},{"line_number":1242,"context_line":"    # http://specs.openstack.org/openstack/nova-specs/specs/train/approved/amd-sev-libvirt-support.html"},{"line_number":1243,"context_line":"    mach_type \u003d libvirt_utils.get_machine_type(image_meta)"},{"line_number":1244,"context_line":""},{"line_number":1245,"context_line":"    # Could be something like pc-q35-2.11 if a specific version"},{"line_number":1246,"context_line":"    # of the machine type is required"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_c8890f26","line":1243,"range":{"start_line":1243,"start_character":3,"end_line":1243,"end_character":58},"updated":"2019-09-05 12:24:17.000000000","message":"mach_type \u003d machine_type or image_meta.properties.get(\"machine_type\")\n\nform the api wew will call this without passing machine_type\n\nform the driver.py it will pass in a prefer machine type but alternitive we coudl revers teh precedence and do \n\nmach_type \u003d image_meta.properties.get(\"machine_type\", machine_type)\n\nthat rely on the internal implemation of  libvirt_utils.get_machine_type(image_meta) however which prefers the image over the config so i think the other form that does not rely on the behavior and instead relys on the caller passing the machine_type is better","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"d04279a1088984bb14b8d1785e8ae164f6d72254","unresolved":false,"context_lines":[{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"},{"line_number":1241,"context_line":"    # QEMU\u0027s iommu_platform feature was added in virtio 1.0 only:"},{"line_number":1242,"context_line":"    # http://specs.openstack.org/openstack/nova-specs/specs/train/approved/amd-sev-libvirt-support.html"},{"line_number":1243,"context_line":"    mach_type \u003d libvirt_utils.get_machine_type(image_meta)"},{"line_number":1244,"context_line":""},{"line_number":1245,"context_line":"    # Could be something like pc-q35-2.11 if a specific version"},{"line_number":1246,"context_line":"    # of the machine type is required"}],"source_content_type":"text/x-python","patch_set":6,"id":"5faad753_82042bc8","line":1243,"range":{"start_line":1243,"start_character":3,"end_line":1243,"end_character":58},"in_reply_to":"7faddb67_c23003a1","updated":"2019-09-06 10:54:07.000000000","message":"This is now passed here: https://review.opendev.org/#/c/644565/52/nova/virt/libvirt/driver.py@5498","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"ac8133b826eae8c1231bb0ea60e72813c4b735ff","unresolved":false,"context_lines":[{"line_number":1240,"context_line":"    # bridge so that they use virtio 1.0 and not virtio 0.9, since"},{"line_number":1241,"context_line":"    # QEMU\u0027s iommu_platform feature was added in virtio 1.0 only:"},{"line_number":1242,"context_line":"    # http://specs.openstack.org/openstack/nova-specs/specs/train/approved/amd-sev-libvirt-support.html"},{"line_number":1243,"context_line":"    mach_type \u003d libvirt_utils.get_machine_type(image_meta)"},{"line_number":1244,"context_line":""},{"line_number":1245,"context_line":"    # Could be something like pc-q35-2.11 if a specific version"},{"line_number":1246,"context_line":"    # of the machine type is required"}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_c23003a1","line":1243,"range":{"start_line":1243,"start_character":3,"end_line":1243,"end_character":58},"in_reply_to":"7faddb67_c8890f26","updated":"2019-09-05 17:48:14.000000000","message":"Agreed.  Will do this in the follow-up commit which passes the machine_type parameter.","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"c5fd5b76d1d1aeec44fd2b874a1fa982f1a075e9","unresolved":false,"context_lines":[{"line_number":1244,"context_line":""},{"line_number":1245,"context_line":"    # Could be something like pc-q35-2.11 if a specific version"},{"line_number":1246,"context_line":"    # of the machine type is required"},{"line_number":1247,"context_line":"    if \u0027q35\u0027 in mach_type:"},{"line_number":1248,"context_line":"        return"},{"line_number":1249,"context_line":""},{"line_number":1250,"context_line":"    raise exception.InvalidMachineType("}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_a88133c4","line":1247,"range":{"start_line":1247,"start_character":4,"end_line":1247,"end_character":26},"updated":"2019-09-05 12:24:17.000000000","message":"if mach_type is none or \u0027q35\u0027 in mach_type:","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"ac8133b826eae8c1231bb0ea60e72813c4b735ff","unresolved":false,"context_lines":[{"line_number":1244,"context_line":""},{"line_number":1245,"context_line":"    # Could be something like pc-q35-2.11 if a specific version"},{"line_number":1246,"context_line":"    # of the machine type is required"},{"line_number":1247,"context_line":"    if \u0027q35\u0027 in mach_type:"},{"line_number":1248,"context_line":"        return"},{"line_number":1249,"context_line":""},{"line_number":1250,"context_line":"    raise exception.InvalidMachineType("}],"source_content_type":"text/x-python","patch_set":6,"id":"7faddb67_623caf91","line":1247,"range":{"start_line":1247,"start_character":4,"end_line":1247,"end_character":26},"in_reply_to":"7faddb67_a88133c4","updated":"2019-09-05 17:48:14.000000000","message":"Done in next PS.","commit_id":"d99e8c84352f48919a23f318025a05109d1cbdaa"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"b97d01637152510c8e63a6240e8eff803acd772b","unresolved":false,"context_lines":[{"line_number":1256,"context_line":"    # configured correctly on SEV compute nodes, then a separate check"},{"line_number":1257,"context_line":"    # in the driver will catch that and potentially retry on other"},{"line_number":1258,"context_line":"    # compute nodes."},{"line_number":1259,"context_line":"    if mach_type is None:"},{"line_number":1260,"context_line":"        return"},{"line_number":1261,"context_line":""},{"line_number":1262,"context_line":"    # Could be something like pc-q35-2.11 if a specific version of the"},{"line_number":1263,"context_line":"    # machine type is required, so do substring matching."}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_07e60418","line":1260,"range":{"start_line":1259,"start_character":0,"end_line":1260,"end_character":14},"updated":"2019-09-06 16:51:13.000000000","message":"I don\u0027t see test coverage for this code path","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"fd765b0efb9218ef2fe2ad351e1b3352ece701af","unresolved":false,"context_lines":[{"line_number":1256,"context_line":"    # configured correctly on SEV compute nodes, then a separate check"},{"line_number":1257,"context_line":"    # in the driver will catch that and potentially retry on other"},{"line_number":1258,"context_line":"    # compute nodes."},{"line_number":1259,"context_line":"    if mach_type is None:"},{"line_number":1260,"context_line":"        return"},{"line_number":1261,"context_line":""},{"line_number":1262,"context_line":"    # Could be something like pc-q35-2.11 if a specific version of the"},{"line_number":1263,"context_line":"    # machine type is required, so do substring matching."}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_adbcafbb","line":1260,"range":{"start_line":1259,"start_character":0,"end_line":1260,"end_character":14},"in_reply_to":"5faad753_07e60418","updated":"2019-09-06 19:51:12.000000000","message":"Ignore what I said on IRC earlier - it *is* definitely already covered here:\n\nhttps://review.opendev.org/#/c/680065/8/nova/tests/unit/virt/test_hardware.py@3925\n\nI tried commenting out these two lines, and as I expected it made nova.tests.unit.virt.test_hardware.MemEncryptionRequiredTestCase fail.","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"},{"author":{"_account_id":2394,"name":"Adam Spiers","email":"aspiers@suse.com","username":"adam.spiers"},"change_message_id":"ead33971d58f9f05cf730acf48fc7cedc9d4a03f","unresolved":false,"context_lines":[{"line_number":1256,"context_line":"    # configured correctly on SEV compute nodes, then a separate check"},{"line_number":1257,"context_line":"    # in the driver will catch that and potentially retry on other"},{"line_number":1258,"context_line":"    # compute nodes."},{"line_number":1259,"context_line":"    if mach_type is None:"},{"line_number":1260,"context_line":"        return"},{"line_number":1261,"context_line":""},{"line_number":1262,"context_line":"    # Could be something like pc-q35-2.11 if a specific version of the"},{"line_number":1263,"context_line":"    # machine type is required, so do substring matching."}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_e88db57b","line":1260,"range":{"start_line":1259,"start_character":0,"end_line":1260,"end_character":14},"in_reply_to":"5faad753_68a9c5dd","updated":"2019-09-06 20:02:34.000000000","message":"Well given that the author couldn\u0027t find it for a few hours, I think you can be forgiven for missing it ;-)","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"a5bc5bb0a0231d88077093c4eb91362bc473d533","unresolved":false,"context_lines":[{"line_number":1256,"context_line":"    # configured correctly on SEV compute nodes, then a separate check"},{"line_number":1257,"context_line":"    # in the driver will catch that and potentially retry on other"},{"line_number":1258,"context_line":"    # compute nodes."},{"line_number":1259,"context_line":"    if mach_type is None:"},{"line_number":1260,"context_line":"        return"},{"line_number":1261,"context_line":""},{"line_number":1262,"context_line":"    # Could be something like pc-q35-2.11 if a specific version of the"},{"line_number":1263,"context_line":"    # machine type is required, so do substring matching."}],"source_content_type":"text/x-python","patch_set":8,"id":"5faad753_68a9c5dd","line":1260,"range":{"start_line":1259,"start_character":0,"end_line":1260,"end_character":14},"in_reply_to":"5faad753_adbcafbb","updated":"2019-09-06 19:59:05.000000000","message":"oh, duh, I see that now, I totally missed that L3925 was hitting the same test case with no machine type set.","commit_id":"c1179d1ff2f744460b4609eb613c6021bb439486"}]}
