)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"ee9d0d398c3ffa801339e1c3b9e60dc7b36ef663","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"8acbd8b5_7d5cf658","updated":"2026-01-08 00:06:22.000000000","message":"recheck","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"870974a659afc46f9d1f03994b7c1155401fd0f6","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"74603b14_52389aa6","updated":"2026-01-15 01:35:58.000000000","message":"recheck Zuul maintenance","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"fe131b62fadf6ff75dfb26ab240e9cf7c5bda7da","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"c4fab881_d0dcab3d","updated":"2026-01-09 08:20:41.000000000","message":"recheck Zuul maintenance","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"15e04d71dab334817bdc1bbb1f580fa2248a6f7c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"b2ac3390_b6e90976","updated":"2026-01-09 04:22:45.000000000","message":"recheck bug #2131931","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"9c49bd03df17a70e65a92b2fd0ad7aff8fbbed99","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"65837206_058bed74","updated":"2026-01-22 09:27:31.000000000","message":"I noticed that [a patch for replacing objects from typing with literals](https://github.com/openstack/nova/commit/e785ab52dc77bae29e70be1b928483228af34ce9) has recently been merged.\n\nMy patch also contained parts that utilized typing.Union. So, I have updated my patch to align this patch.","commit_id":"a4b419c27764a9c0e7ef189c2e9f4a2e6dba3f40"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"9e6e4797389eed42ad76ebf26823280bb44f08c9","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":9,"id":"c40337ca_ab90b2d5","updated":"2026-02-04 11:50:05.000000000","message":"Overall, this patch looks good to me.\nI’m giving a small -1 as I think we’re just missing a couple of unit tests to cover the newly introduced methods.\nThis is not strictly required, but I believe the patch could be made slightly more generic; see inline comments for details, but that\u0027s ok if you don\u0027t want to go this way.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"046b6345228f49457f9e5f31ca760c46b15d20d2","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":9,"id":"da3289a0_564cf8f3","in_reply_to":"c40337ca_ab90b2d5","updated":"2026-03-06 10:42:54.000000000","message":"Done","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"09a72ce045571269b91a75615852b964a2144a2c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"e5daa567_029c5723","updated":"2026-02-26 15:58:12.000000000","message":"I do think we missed to mention that upgrade concern at the PTG and we need to agree on a design decision.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"c854d37f_9012a45a","updated":"2026-02-26 15:21:19.000000000","message":"I\u0027m mostly -1 due to potentially sending total\u003d0 to placement, which is invalid.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"cd34e2b896da8bef497d430cf63d409cd9d03c1c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"10422e37_46f69ef8","updated":"2026-02-19 15:57:06.000000000","message":"LGTM","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"195700b05c9e43b4765f4826529b2f7b15291765","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"d0360e2b_371c622b","updated":"2026-02-20 05:24:54.000000000","message":"recheck grenade-skip-level-always failed due to missing pkg resource","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"9e5d06cce6418ef95621da203b782f5c5b798256","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":13,"id":"106ef79c_26f9337c","updated":"2026-03-19 17:56:22.000000000","message":"All latest comments addressed so LGTM.","commit_id":"913b319e61dec10b039e222a5a15a9989d0f71ab"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"fa160a7cc741cb76fc7309992d68b4d21af9f2c1","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":13,"id":"d20fd712_c69cfe15","updated":"2026-03-09 04:32:45.000000000","message":"recheck Zuul failed due to missing config format","commit_id":"913b319e61dec10b039e222a5a15a9989d0f71ab"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"2cff40f7ee04f41634406188ca11bfcdd0dfd8d5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"33e904fa_d8578375","updated":"2026-04-15 08:24:04.000000000","message":"recheck TestShelveInstance failed to reach ACTIVE status by timeout","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"405b889cdd95090156418c56f865a47c9b101a02","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"9f4f884f_e845391f","updated":"2026-04-15 00:21:31.000000000","message":"recheck failed to connect mirror","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"02f41c628629a391145062ac24dabf4bb1d9a937","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"1ebd44a3_4d78400d","updated":"2026-04-15 03:58:46.000000000","message":"recheck ssh connection timeout","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"bb99eccd1c449dd44489e8ce580d21a0814adef1","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"86ab83f4_df38f4da","updated":"2026-04-10 14:34:28.000000000","message":"wfm but a few nits but we can merge","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"593430541929a0af2f04511b336b7efa4c0ac68c","unresolved":true,"context_lines":[{"line_number":9789,"context_line":"        slots_strs \u003d []"},{"line_number":9790,"context_line":""},{"line_number":9791,"context_line":"        for model_name, attrs in inventories.items():"},{"line_number":9792,"context_line":"            if \u0027traits\u0027 in attrs and attrs[\u0027traits\u0027] is not None:"},{"line_number":9793,"context_line":"                attrs.setdefault(\u0027step_size\u0027, 1)"},{"line_number":9794,"context_line":"                attrs.setdefault(\u0027max_unit\u0027, 1)"},{"line_number":9795,"context_line":"                attrs.setdefault(\u0027min_unit\u0027, 1)"}],"source_content_type":"text/x-python","patch_set":6,"id":"08ebc51f_43256898","line":9792,"updated":"2026-01-17 18:48:41.000000000","message":"It seems like the non-existence of the traits field somehow use as deciding if inventory is needed or not. That feels strange. I would rather use total\u003d\u003d0 as the trigger to skip an inventory.\n\nI\u0027m wondering if it would be cleaner to have a proper type (namedtuple, or class) that ensures we always have traits here that are never None.","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"73d718726078b5d7e84bc9322ca4160824691024","unresolved":true,"context_lines":[{"line_number":9789,"context_line":"        slots_strs \u003d []"},{"line_number":9790,"context_line":""},{"line_number":9791,"context_line":"        for model_name, attrs in inventories.items():"},{"line_number":9792,"context_line":"            if \u0027traits\u0027 in attrs and attrs[\u0027traits\u0027] is not None:"},{"line_number":9793,"context_line":"                attrs.setdefault(\u0027step_size\u0027, 1)"},{"line_number":9794,"context_line":"                attrs.setdefault(\u0027max_unit\u0027, 1)"},{"line_number":9795,"context_line":"                attrs.setdefault(\u0027min_unit\u0027, 1)"}],"source_content_type":"text/x-python","patch_set":6,"id":"d223db8f_ff1365fa","line":9792,"in_reply_to":"08ebc51f_43256898","updated":"2026-01-20 10:25:51.000000000","message":"I\u0027ve updated the logic to use `supported\u003dyes` for determining whether an inventory is needed.\n\nRegarding `total\u003d\u003d0` as a trigger for skipping inventory, I found it\u0027s not always appropriate. Although the hardware might support `amd_sev(es)`, the `total` could still be zero if the configuration sets [conf_slots](https://github.com/openstack/nova/blob/66bad0b1d9f9a1136482ee4b658d69ebc9d4e428/nova/virt/libvirt/driver.py#L9802) or [sev_slots](https://github.com/openstack/nova/blob/66bad0b1d9f9a1136482ee4b658d69ebc9d4e428/nova/virt/libvirt/driver.py#L9821)(Updated to `slots` in this change) to 0.","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"48f1f11460d5757f51d96b5bde0143d1b8699f63","unresolved":false,"context_lines":[{"line_number":9789,"context_line":"        slots_strs \u003d []"},{"line_number":9790,"context_line":""},{"line_number":9791,"context_line":"        for model_name, attrs in inventories.items():"},{"line_number":9792,"context_line":"            if \u0027traits\u0027 in attrs and attrs[\u0027traits\u0027] is not None:"},{"line_number":9793,"context_line":"                attrs.setdefault(\u0027step_size\u0027, 1)"},{"line_number":9794,"context_line":"                attrs.setdefault(\u0027max_unit\u0027, 1)"},{"line_number":9795,"context_line":"                attrs.setdefault(\u0027min_unit\u0027, 1)"}],"source_content_type":"text/x-python","patch_set":6,"id":"0c8678fb_73b0137a","line":9792,"in_reply_to":"d223db8f_ff1365fa","updated":"2026-04-02 16:22:11.000000000","message":"Done","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":true,"context_lines":[{"line_number":9860,"context_line":"                attrs.setdefault(\u0027allocation_ratio\u0027, 1.0)"},{"line_number":9861,"context_line":"                attrs.setdefault(\u0027reserved\u0027, 0)"},{"line_number":9862,"context_line":"            else:"},{"line_number":9863,"context_line":"                attrs[\u0027total\u0027] \u003d 0"},{"line_number":9864,"context_line":"            slots_strs.append(\u0027%s\u003d%d\u0027 % (model_name, attrs[\u0027total\u0027]))"},{"line_number":9865,"context_line":""},{"line_number":9866,"context_line":"        LOG.debug(\"Available memory encrypted slots: %s\", \u0027 \u0027.join(slots_strs))"}],"source_content_type":"text/x-python","patch_set":10,"id":"8a05a679_bc57f944","line":9863,"updated":"2026-02-26 15:21:19.000000000","message":"If this ends up being sent to placement then we have a problem.\nI don\u0027t think placement allows creating an inventory record with total\u003d0\n```\nstack@aio:~$ openstack resource provider inventory set 6080feac-124e-4e40-a0b7-36bef86da212 --amend --resource VCPU:total\u003d0\nJSON does not validate: 0 is less than the minimum of 1  Failed validating \u0027minimum\u0027 in schema[\u0027properties\u0027][\u0027inventories\u0027][\u0027patternProperties\u0027][\u0027^[A-Z0-9_]+$\u0027][\u0027properties\u0027][\u0027total\u0027]:     {\u0027type\u0027: \u0027integer\u0027, \u0027maximum\u0027: 2147483647, \u0027minimum\u0027: 1}  On instance[\u0027inventories\u0027][\u0027VCPU\u0027][\u0027total\u0027]:     0 (HTTP 400)\n```","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"b313b3a745c198104fc9c7df28f6568fd41960ce","unresolved":true,"context_lines":[{"line_number":9860,"context_line":"                attrs.setdefault(\u0027allocation_ratio\u0027, 1.0)"},{"line_number":9861,"context_line":"                attrs.setdefault(\u0027reserved\u0027, 0)"},{"line_number":9862,"context_line":"            else:"},{"line_number":9863,"context_line":"                attrs[\u0027total\u0027] \u003d 0"},{"line_number":9864,"context_line":"            slots_strs.append(\u0027%s\u003d%d\u0027 % (model_name, attrs[\u0027total\u0027]))"},{"line_number":9865,"context_line":""},{"line_number":9866,"context_line":"        LOG.debug(\"Available memory encrypted slots: %s\", \u0027 \u0027.join(slots_strs))"}],"source_content_type":"text/x-python","patch_set":10,"id":"8c131cd6_d6f6d40f","line":9863,"in_reply_to":"169ad734_fbaa8d26","updated":"2026-02-27 10:57:26.000000000","message":"Even before this refactoring, the nova implementation handles this `total\u003d0` pattern.  If `inventory[\u0027total\u0027]` is 0, the corresponding Resource Provider tree is removed in [this part](https://opendev.org/openstack/nova/src/commit/8e780914d2fda0c972b43dc6aa1f3a73ef215925/nova/virt/libvirt/driver.py#L9764)\nSo, `total\u003d0` inventories don\u0027t get sent to Placement. This avoids the Placement error.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"09a72ce045571269b91a75615852b964a2144a2c","unresolved":true,"context_lines":[{"line_number":9860,"context_line":"                attrs.setdefault(\u0027allocation_ratio\u0027, 1.0)"},{"line_number":9861,"context_line":"                attrs.setdefault(\u0027reserved\u0027, 0)"},{"line_number":9862,"context_line":"            else:"},{"line_number":9863,"context_line":"                attrs[\u0027total\u0027] \u003d 0"},{"line_number":9864,"context_line":"            slots_strs.append(\u0027%s\u003d%d\u0027 % (model_name, attrs[\u0027total\u0027]))"},{"line_number":9865,"context_line":""},{"line_number":9866,"context_line":"        LOG.debug(\"Available memory encrypted slots: %s\", \u0027 \u0027.join(slots_strs))"}],"source_content_type":"text/x-python","patch_set":10,"id":"169ad734_fbaa8d26","line":9863,"in_reply_to":"8a05a679_bc57f944","updated":"2026-02-26 15:58:12.000000000","message":"Yeah, that\u0027s a design issue, we shouldn\u0027t allow total to be 0 but we can delete the RP... provided there are no allocations against it 😊","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"49da64e640b2af4ecaafd59cf562f84e99e5e610","unresolved":false,"context_lines":[{"line_number":9860,"context_line":"                attrs.setdefault(\u0027allocation_ratio\u0027, 1.0)"},{"line_number":9861,"context_line":"                attrs.setdefault(\u0027reserved\u0027, 0)"},{"line_number":9862,"context_line":"            else:"},{"line_number":9863,"context_line":"                attrs[\u0027total\u0027] \u003d 0"},{"line_number":9864,"context_line":"            slots_strs.append(\u0027%s\u003d%d\u0027 % (model_name, attrs[\u0027total\u0027]))"},{"line_number":9865,"context_line":""},{"line_number":9866,"context_line":"        LOG.debug(\"Available memory encrypted slots: %s\", \u0027 \u0027.join(slots_strs))"}],"source_content_type":"text/x-python","patch_set":10,"id":"cbd06b10_aea7e4d5","line":9863,"in_reply_to":"8c131cd6_d6f6d40f","updated":"2026-03-05 14:18:36.000000000","message":"cool then this is not a problem.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"}],"nova/virt/libvirt/host.py":[{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"6ef3149597a1b0fff79860d38f9717d699504249","unresolved":true,"context_lines":[{"line_number":2066,"context_line":"            return None"},{"line_number":2067,"context_line":"        return self._max_sev_es_guests"},{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"}],"source_content_type":"text/x-python","patch_set":1,"id":"2b4f45b6_85e38975","line":2069,"range":{"start_line":2069,"start_character":5,"end_line":2069,"end_character":13},"updated":"2025-11-27 14:48:28.000000000","message":"If we use property then I think we should cache the data to avoid calculating the same information multiple times.\n\nHowever AFAIK this is called only one-short then we can probably just use usual function interface (like get_mem_encryption_attrs).","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"a39c5995fb2f3c008e03db4ce04072ce04170597","unresolved":false,"context_lines":[{"line_number":2066,"context_line":"            return None"},{"line_number":2067,"context_line":"        return self._max_sev_es_guests"},{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"}],"source_content_type":"text/x-python","patch_set":1,"id":"8c6957d9_cc47191e","line":2069,"range":{"start_line":2069,"start_character":5,"end_line":2069,"end_character":13},"in_reply_to":"2b4f45b6_85e38975","updated":"2025-12-08 08:01:02.000000000","message":"Done","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"6ef3149597a1b0fff79860d38f9717d699504249","unresolved":true,"context_lines":[{"line_number":2067,"context_line":"        return self._max_sev_es_guests"},{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"},{"line_number":2073,"context_line":"        and required traits for each supported model."}],"source_content_type":"text/x-python","patch_set":1,"id":"74518e41_6a41bf3a","line":2070,"range":{"start_line":2070,"start_character":23,"end_line":2070,"end_character":28},"updated":"2025-11-27 14:48:28.000000000","message":"mem_encryption_inventories or mem_encryption_slots . attrs (attributes) may not indicate quantity.","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"22efd92999feb38a2360d56e4d148d65beef2bd6","unresolved":false,"context_lines":[{"line_number":2067,"context_line":"        return self._max_sev_es_guests"},{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"},{"line_number":2073,"context_line":"        and required traits for each supported model."}],"source_content_type":"text/x-python","patch_set":1,"id":"a409eb97_8db5f011","line":2070,"range":{"start_line":2070,"start_character":23,"end_line":2070,"end_character":28},"in_reply_to":"633fdb66_47b7ae53","updated":"2026-02-20 04:04:51.000000000","message":"Done","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"a39c5995fb2f3c008e03db4ce04072ce04170597","unresolved":true,"context_lines":[{"line_number":2067,"context_line":"        return self._max_sev_es_guests"},{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"},{"line_number":2073,"context_line":"        and required traits for each supported model."}],"source_content_type":"text/x-python","patch_set":1,"id":"633fdb66_47b7ae53","line":2070,"range":{"start_line":2070,"start_character":23,"end_line":2070,"end_character":28},"in_reply_to":"74518e41_6a41bf3a","updated":"2025-12-08 08:01:02.000000000","message":"I\u0027ve renamed `get_mem_encryption_inventories`.","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"6ef3149597a1b0fff79860d38f9717d699504249","unresolved":true,"context_lines":[{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"},{"line_number":2073,"context_line":"        and required traits for each supported model."},{"line_number":2074,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"8801143d_00151ca5","line":2071,"range":{"start_line":2071,"start_character":11,"end_line":2071,"end_character":18},"updated":"2025-11-27 14:48:28.000000000","message":"I\u0027d suggest creating a separate title line.","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"a39c5995fb2f3c008e03db4ce04072ce04170597","unresolved":false,"context_lines":[{"line_number":2068,"context_line":""},{"line_number":2069,"context_line":"    @property"},{"line_number":2070,"context_line":"    def mem_encryption_attrs(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2071,"context_line":"        \"\"\"Returns a dictionary of memory encryption attributes"},{"line_number":2072,"context_line":"        supported by the host. This includes total slots"},{"line_number":2073,"context_line":"        and required traits for each supported model."},{"line_number":2074,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"a19b0687_a04259f8","line":2071,"range":{"start_line":2071,"start_character":11,"end_line":2071,"end_character":18},"in_reply_to":"8801143d_00151ca5","updated":"2025-12-08 08:01:02.000000000","message":"Done","commit_id":"ea9c5359f55e08658848ab296ac6afb23a14eb9c"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"593430541929a0af2f04511b336b7efa4c0ac68c","unresolved":true,"context_lines":[{"line_number":2064,"context_line":""},{"line_number":2065,"context_line":"        return self.supports_amd_sev"},{"line_number":2066,"context_line":""},{"line_number":2067,"context_line":"    def get_mem_encryption_inventories(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2068,"context_line":"        \"\"\"Return a dictionary of memory encryption information."},{"line_number":2069,"context_line":""},{"line_number":2070,"context_line":"        The return value contains total slots and required traits for"}],"source_content_type":"text/x-python","patch_set":6,"id":"f41b19fa_b550e640","line":2067,"updated":"2026-01-17 18:48:41.000000000","message":"This function feels like a candidate to split into smaller functions by encryption type","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":false,"context_lines":[{"line_number":2064,"context_line":""},{"line_number":2065,"context_line":"        return self.supports_amd_sev"},{"line_number":2066,"context_line":""},{"line_number":2067,"context_line":"    def get_mem_encryption_inventories(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2068,"context_line":"        \"\"\"Return a dictionary of memory encryption information."},{"line_number":2069,"context_line":""},{"line_number":2070,"context_line":"        The return value contains total slots and required traits for"}],"source_content_type":"text/x-python","patch_set":6,"id":"237e8d09_34577281","line":2067,"in_reply_to":"313119a2_53827c4b","updated":"2026-02-26 15:21:19.000000000","message":"Done","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"73d718726078b5d7e84bc9322ca4160824691024","unresolved":true,"context_lines":[{"line_number":2064,"context_line":""},{"line_number":2065,"context_line":"        return self.supports_amd_sev"},{"line_number":2066,"context_line":""},{"line_number":2067,"context_line":"    def get_mem_encryption_inventories(self) -\u003e ty.Dict[str, ty.Any]:"},{"line_number":2068,"context_line":"        \"\"\"Return a dictionary of memory encryption information."},{"line_number":2069,"context_line":""},{"line_number":2070,"context_line":"        The return value contains total slots and required traits for"}],"source_content_type":"text/x-python","patch_set":6,"id":"313119a2_53827c4b","line":2067,"in_reply_to":"f41b19fa_b550e640","updated":"2026-01-20 10:25:51.000000000","message":"As your suggestion, I\u0027ve split this function into three, based on encryption type.","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"593430541929a0af2f04511b336b7efa4c0ac68c","unresolved":true,"context_lines":[{"line_number":2087,"context_line":"                slots \u003d min(slots, conf_slots)"},{"line_number":2088,"context_line":"            inventories[\u0027amd_sev\u0027] \u003d {"},{"line_number":2089,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2090,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV]"},{"line_number":2091,"context_line":"            }"},{"line_number":2092,"context_line":"        else:"},{"line_number":2093,"context_line":"            if conf_slots is not None:"}],"source_content_type":"text/x-python","patch_set":6,"id":"764d8ab9_f226198c","line":2090,"updated":"2026-01-17 18:48:41.000000000","message":"I\u0027m wondering if we can unify this trait with the trait defined in the specific MemEncryptionConfig type","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"73d718726078b5d7e84bc9322ca4160824691024","unresolved":true,"context_lines":[{"line_number":2087,"context_line":"                slots \u003d min(slots, conf_slots)"},{"line_number":2088,"context_line":"            inventories[\u0027amd_sev\u0027] \u003d {"},{"line_number":2089,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2090,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV]"},{"line_number":2091,"context_line":"            }"},{"line_number":2092,"context_line":"        else:"},{"line_number":2093,"context_line":"            if conf_slots is not None:"}],"source_content_type":"text/x-python","patch_set":6,"id":"c6df1253_b235bdcb","line":2090,"in_reply_to":"764d8ab9_f226198c","updated":"2026-01-20 10:25:51.000000000","message":"I believe it would be both difficult and inappropriate to unify this trait with the one defined in the `MemEncryptionConfig` class.\n\nThe reason is that these two traits serve fundamentally different purposes:\n* The trait discussed here (the one in the current context) indicates that a specific compute host possesses the hardware feature.\n* The trait within the `MemEncryptionConfig` class　represents resource requests from OpenStack.\n\nForcibly using the `MemEncryptionConfig`\u0027s trait in this context would not simplify the code logic.","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":false,"context_lines":[{"line_number":2087,"context_line":"                slots \u003d min(slots, conf_slots)"},{"line_number":2088,"context_line":"            inventories[\u0027amd_sev\u0027] \u003d {"},{"line_number":2089,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2090,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV]"},{"line_number":2091,"context_line":"            }"},{"line_number":2092,"context_line":"        else:"},{"line_number":2093,"context_line":"            if conf_slots is not None:"}],"source_content_type":"text/x-python","patch_set":6,"id":"211bab64_10965151","line":2090,"in_reply_to":"c6df1253_b235bdcb","updated":"2026-02-26 15:21:19.000000000","message":"I was thinking along the same line as you. We have a single trait and it is used two ways\n* expressing when a compute supports the feature\n* expressing that the request needs a compute that support the feature.\n\nI need to look a more on the implementation level but for me referencing the same entity for both usage make sense on high level.\n\nI\u0027m not blocking this. It is probably a bit philosophical.","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"593430541929a0af2f04511b336b7efa4c0ac68c","unresolved":true,"context_lines":[{"line_number":2101,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2102,"context_line":"            slots \u003d 0"},{"line_number":2103,"context_line":"            if self.max_sev_es_guests is not None:"},{"line_number":2104,"context_line":"                slots \u003d self.max_sev_es_guests"},{"line_number":2105,"context_line":"            inventories[\u0027amd_sev_es\u0027] \u003d {"},{"line_number":2106,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2107,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV_ES]"}],"source_content_type":"text/x-python","patch_set":6,"id":"9b2d366f_0c27d246","line":2104,"updated":"2026-01-17 18:48:41.000000000","message":"Is it a bug that we don\u0027t do the same logic with conf_slots as for AMD SEV? Or that config is SEV only?","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"73d718726078b5d7e84bc9322ca4160824691024","unresolved":true,"context_lines":[{"line_number":2101,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2102,"context_line":"            slots \u003d 0"},{"line_number":2103,"context_line":"            if self.max_sev_es_guests is not None:"},{"line_number":2104,"context_line":"                slots \u003d self.max_sev_es_guests"},{"line_number":2105,"context_line":"            inventories[\u0027amd_sev_es\u0027] \u003d {"},{"line_number":2106,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2107,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV_ES]"}],"source_content_type":"text/x-python","patch_set":6,"id":"9ddd024c_3dee3241","line":2104,"in_reply_to":"9b2d366f_0c27d246","updated":"2026-01-20 10:25:51.000000000","message":"I understand that this is not a bug and that configuration is specific to SEV only (not SEV-ES).\n\nThe reason is that `conf_slots` is planned to be deprecated because libvirt (since version 8.0.0) can now get the maximum number of SEV/SEV-ES guests directly via `DomainCapabilities`. The development of SEV-ES within OpenStack occurred after this deprecation was determined, which is why `conf_slots` for SEV-ES was never implemented. [1]\n\n[1] https://github.com/openstack/nova/blob/66bad0b1d9f9a1136482ee4b658d69ebc9d4e428/nova/conf/libvirt.py#L875","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":false,"context_lines":[{"line_number":2101,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2102,"context_line":"            slots \u003d 0"},{"line_number":2103,"context_line":"            if self.max_sev_es_guests is not None:"},{"line_number":2104,"context_line":"                slots \u003d self.max_sev_es_guests"},{"line_number":2105,"context_line":"            inventories[\u0027amd_sev_es\u0027] \u003d {"},{"line_number":2106,"context_line":"                \u0027total\u0027: slots,"},{"line_number":2107,"context_line":"                \u0027traits\u0027: [ot.HW_CPU_X86_AMD_SEV_ES]"}],"source_content_type":"text/x-python","patch_set":6,"id":"504f33dc_696e29a0","line":2104,"in_reply_to":"9ddd024c_3dee3241","updated":"2026-02-26 15:21:19.000000000","message":"Acknowledged","commit_id":"302904c0413304925be898cdf853c261cbf9fd9d"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"9e6e4797389eed42ad76ebf26823280bb44f08c9","unresolved":true,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"42814ace_0a83755c","line":2078,"range":{"start_line":2078,"start_character":8,"end_line":2078,"end_character":46},"updated":"2026-02-04 11:50:05.000000000","message":"I think a unit test to cover this function would be good.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"9e6e4797389eed42ad76ebf26823280bb44f08c9","unresolved":true,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"73e8916b_344cdb54","line":2078,"updated":"2026-02-04 11:50:05.000000000","message":"Optionally, we could go one step further by introducing a private helper to build or retrieve the encryption inventory per model. This would make it easier to add new models, which is one of the goals of this patch series.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"cd34e2b896da8bef497d430cf63d409cd9d03c1c","unresolved":false,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"9f50fee7_e0d0ed80","line":2078,"range":{"start_line":2078,"start_character":8,"end_line":2078,"end_character":46},"in_reply_to":"2feec230_72226ab2","updated":"2026-02-19 15:57:06.000000000","message":"Acknowledged","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"2ca4a92ae9f72cc9374b2c84878f179df25b5b5d","unresolved":true,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"2feec230_72226ab2","line":2078,"range":{"start_line":2078,"start_character":8,"end_line":2078,"end_character":46},"in_reply_to":"42814ace_0a83755c","updated":"2026-02-09 10:00:11.000000000","message":"Updated unit tests to cover this function.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"2ca4a92ae9f72cc9374b2c84878f179df25b5b5d","unresolved":true,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"9f1518cc_e4f14120","line":2078,"in_reply_to":"73e8916b_344cdb54","updated":"2026-02-09 10:00:11.000000000","message":"The latest patch addresses this by:\n\n* Dynamically iterating all models in _get_mem_encryption_inventories(), calling dedicated _get_mem_encryption_slots_X() / _get_mem_encryption_traits_X() helpers.\n* Separating concerns into these specific, underscored helper methods.\n\nThis improves extensibility and clarity as suggested. Please check it again when you have time.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"cd34e2b896da8bef497d430cf63d409cd9d03c1c","unresolved":false,"context_lines":[{"line_number":2075,"context_line":""},{"line_number":2076,"context_line":"        return inventories"},{"line_number":2077,"context_line":""},{"line_number":2078,"context_line":"    def get_mem_encryption_inventories_amd_sev(self) -\u003e dict[str, ty.Any]:"},{"line_number":2079,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2080,"context_line":"        if self.supports_amd_sev:"},{"line_number":2081,"context_line":"            slots \u003d db_const.MAX_INT"}],"source_content_type":"text/x-python","patch_set":9,"id":"a63586c5_7db567d2","line":2078,"in_reply_to":"9f1518cc_e4f14120","updated":"2026-02-19 15:57:06.000000000","message":"Acknowledged","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"9e6e4797389eed42ad76ebf26823280bb44f08c9","unresolved":true,"context_lines":[{"line_number":2102,"context_line":""},{"line_number":2103,"context_line":"        return inventories"},{"line_number":2104,"context_line":""},{"line_number":2105,"context_line":"    def get_mem_encryption_inventories_amd_sev_es("},{"line_number":2106,"context_line":"            self) -\u003e dict[str, ty.Any]:"},{"line_number":2107,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2108,"context_line":"            slots \u003d 0"}],"source_content_type":"text/x-python","patch_set":9,"id":"2f8f3e36_a513074a","line":2105,"range":{"start_line":2105,"start_character":8,"end_line":2105,"end_character":49},"updated":"2026-02-04 11:50:05.000000000","message":"I think a unit test to cover this function would be good.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"2ca4a92ae9f72cc9374b2c84878f179df25b5b5d","unresolved":true,"context_lines":[{"line_number":2102,"context_line":""},{"line_number":2103,"context_line":"        return inventories"},{"line_number":2104,"context_line":""},{"line_number":2105,"context_line":"    def get_mem_encryption_inventories_amd_sev_es("},{"line_number":2106,"context_line":"            self) -\u003e dict[str, ty.Any]:"},{"line_number":2107,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2108,"context_line":"            slots \u003d 0"}],"source_content_type":"text/x-python","patch_set":9,"id":"f2db61b7_234a33de","line":2105,"range":{"start_line":2105,"start_character":8,"end_line":2105,"end_character":49},"in_reply_to":"2f8f3e36_a513074a","updated":"2026-02-09 10:00:11.000000000","message":"Updated unit tests to cover this function.","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":16207,"name":"ribaudr","display_name":"uggla","email":"rene.ribaud@gmail.com","username":"uggla","status":"Red Hat"},"change_message_id":"cd34e2b896da8bef497d430cf63d409cd9d03c1c","unresolved":false,"context_lines":[{"line_number":2102,"context_line":""},{"line_number":2103,"context_line":"        return inventories"},{"line_number":2104,"context_line":""},{"line_number":2105,"context_line":"    def get_mem_encryption_inventories_amd_sev_es("},{"line_number":2106,"context_line":"            self) -\u003e dict[str, ty.Any]:"},{"line_number":2107,"context_line":"        if self.supports_amd_sev_es:"},{"line_number":2108,"context_line":"            slots \u003d 0"}],"source_content_type":"text/x-python","patch_set":9,"id":"515697a6_beccbdf3","line":2105,"range":{"start_line":2105,"start_character":8,"end_line":2105,"end_character":49},"in_reply_to":"f2db61b7_234a33de","updated":"2026-02-19 15:57:06.000000000","message":"Acknowledged","commit_id":"c57c8f83f564604ec645802c640f71d847b2cc77"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":true,"context_lines":[{"line_number":2164,"context_line":"        \"\"\""},{"line_number":2165,"context_line":"        inventories: dict[str, ty.Any] \u003d {}"},{"line_number":2166,"context_line":"        for model in fields.MemEncryptionModel.ALL:"},{"line_number":2167,"context_line":"            modelsym \u003d model.replace(\u0027-\u0027, \u0027_\u0027)"},{"line_number":2168,"context_line":"            prop_supports \u003d \u0027supports_%s\u0027 % modelsym"},{"line_number":2169,"context_line":"            func_slots \u003d \u0027_get_mem_encryption_slots_%s\u0027 % modelsym"},{"line_number":2170,"context_line":"            func_traits \u003d \u0027_get_mem_encryption_traits_%s\u0027 % modelsym"},{"line_number":2171,"context_line":"            inv \u003d {\u0027supported\u0027: getattr(self, prop_supports)}"},{"line_number":2172,"context_line":"            if inv[\u0027supported\u0027]:"},{"line_number":2173,"context_line":"                inv.update("},{"line_number":2174,"context_line":"                    total\u003dgetattr(self, func_slots)(),"}],"source_content_type":"text/x-python","patch_set":10,"id":"8f72e649_21f8e91a","line":2171,"range":{"start_line":2167,"start_character":0,"end_line":2171,"end_character":0},"updated":"2026-02-26 15:21:19.000000000","message":"(I\u0027m not blocking on this) Here we are converting from the model name to a function that returns model specific data. We also have model specific classes like MemEncryptionConfigSev and MemEncryptionConfigSevEs. So I\u0027m wondering that these functions belong to those respective classes or a similar / parallel classes could represent this mode/type specific variants.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"bb99eccd1c449dd44489e8ce580d21a0814adef1","unresolved":true,"context_lines":[{"line_number":2164,"context_line":"        \"\"\""},{"line_number":2165,"context_line":"        inventories: dict[str, ty.Any] \u003d {}"},{"line_number":2166,"context_line":"        for model in fields.MemEncryptionModel.ALL:"},{"line_number":2167,"context_line":"            modelsym \u003d model.replace(\u0027-\u0027, \u0027_\u0027)"},{"line_number":2168,"context_line":"            prop_supports \u003d \u0027supports_%s\u0027 % modelsym"},{"line_number":2169,"context_line":"            func_slots \u003d \u0027_get_mem_encryption_slots_%s\u0027 % modelsym"},{"line_number":2170,"context_line":"            func_traits \u003d \u0027_get_mem_encryption_traits_%s\u0027 % modelsym"},{"line_number":2171,"context_line":"            inv \u003d {\u0027supported\u0027: getattr(self, prop_supports)}"},{"line_number":2172,"context_line":"            if inv[\u0027supported\u0027]:"},{"line_number":2173,"context_line":"                inv.update("},{"line_number":2174,"context_line":"                    total\u003dgetattr(self, func_slots)(),"}],"source_content_type":"text/x-python","patch_set":10,"id":"9f47e88e_efb1250b","line":2171,"range":{"start_line":2167,"start_character":0,"end_line":2171,"end_character":0},"in_reply_to":"8f72e649_21f8e91a","updated":"2026-04-10 14:34:28.000000000","message":"I agree with gibi, I\u0027m afraid of this pattern but we can change it later if we don\u0027t like it.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"405b889cdd95090156418c56f865a47c9b101a02","unresolved":true,"context_lines":[{"line_number":2164,"context_line":"        \"\"\""},{"line_number":2165,"context_line":"        inventories: dict[str, ty.Any] \u003d {}"},{"line_number":2166,"context_line":"        for model in fields.MemEncryptionModel.ALL:"},{"line_number":2167,"context_line":"            modelsym \u003d model.replace(\u0027-\u0027, \u0027_\u0027)"},{"line_number":2168,"context_line":"            prop_supports \u003d \u0027supports_%s\u0027 % modelsym"},{"line_number":2169,"context_line":"            func_slots \u003d \u0027_get_mem_encryption_slots_%s\u0027 % modelsym"},{"line_number":2170,"context_line":"            func_traits \u003d \u0027_get_mem_encryption_traits_%s\u0027 % modelsym"},{"line_number":2171,"context_line":"            inv \u003d {\u0027supported\u0027: getattr(self, prop_supports)}"},{"line_number":2172,"context_line":"            if inv[\u0027supported\u0027]:"},{"line_number":2173,"context_line":"                inv.update("},{"line_number":2174,"context_line":"                    total\u003dgetattr(self, func_slots)(),"}],"source_content_type":"text/x-python","patch_set":10,"id":"7d5ac1e4_d0a3417b","line":2171,"range":{"start_line":2167,"start_character":0,"end_line":2171,"end_character":0},"in_reply_to":"9f47e88e_efb1250b","updated":"2026-04-15 00:21:31.000000000","message":"Given that this patchset has received workflow +1, I\u0027d like to keep the current implementation for now to move forward. I will definitely look into refactoring this based on your feedbacks.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":true,"context_lines":[{"line_number":2176,"context_line":"            else:"},{"line_number":2177,"context_line":"                slots \u003d getattr(self, func_slots)()"},{"line_number":2178,"context_line":"                if slots \u003e 0:"},{"line_number":2179,"context_line":"                    LOG.warning(\"Host does not support %s but function %s \""},{"line_number":2180,"context_line":"                                \"returns number of slots %d.\", slots)"},{"line_number":2181,"context_line":""},{"line_number":2182,"context_line":"            inventories[modelsym] \u003d inv"},{"line_number":2183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"7b7b2706_eaa328ec","line":2180,"range":{"start_line":2179,"start_character":62,"end_line":2180,"end_character":69},"updated":"2026-02-26 15:21:19.000000000","message":"this part of the message does not really helpful for the admin to see in a warning. Warning is scary but does not instruct the admin what to do. If this is a real problem we don\u0027t know what to do about then we should fail. If this is not a real issue just a misconfiguration then warning should instruct the admin what to do. If this is just a debugging information for the software devs then move this to debug level.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"3d924acb4149f0cb6d5aa55a3981942764983fc3","unresolved":true,"context_lines":[{"line_number":2176,"context_line":"            else:"},{"line_number":2177,"context_line":"                slots \u003d getattr(self, func_slots)()"},{"line_number":2178,"context_line":"                if slots \u003e 0:"},{"line_number":2179,"context_line":"                    LOG.warning(\"Host does not support %s but function %s \""},{"line_number":2180,"context_line":"                                \"returns number of slots %d.\", slots)"},{"line_number":2181,"context_line":""},{"line_number":2182,"context_line":"            inventories[modelsym] \u003d inv"},{"line_number":2183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"d6cd5d4b_9f3ae730","line":2180,"range":{"start_line":2179,"start_character":62,"end_line":2180,"end_character":69},"in_reply_to":"79cfc4c0_1e2b41af","updated":"2026-02-27 04:03:48.000000000","message":"This is just debugging information for the software developers, so I\u0027ve converted it to `LOG.debug` and corrected formatting error.","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"09a72ce045571269b91a75615852b964a2144a2c","unresolved":true,"context_lines":[{"line_number":2176,"context_line":"            else:"},{"line_number":2177,"context_line":"                slots \u003d getattr(self, func_slots)()"},{"line_number":2178,"context_line":"                if slots \u003e 0:"},{"line_number":2179,"context_line":"                    LOG.warning(\"Host does not support %s but function %s \""},{"line_number":2180,"context_line":"                                \"returns number of slots %d.\", slots)"},{"line_number":2181,"context_line":""},{"line_number":2182,"context_line":"            inventories[modelsym] \u003d inv"},{"line_number":2183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"79cfc4c0_1e2b41af","line":2180,"range":{"start_line":2179,"start_character":62,"end_line":2180,"end_character":69},"in_reply_to":"7b7b2706_eaa328ec","updated":"2026-02-26 15:58:12.000000000","message":"there will also be a formatting error which will crash at runtile, the string awaits three parameters but only one is provided (slots)","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"49da64e640b2af4ecaafd59cf562f84e99e5e610","unresolved":false,"context_lines":[{"line_number":2176,"context_line":"            else:"},{"line_number":2177,"context_line":"                slots \u003d getattr(self, func_slots)()"},{"line_number":2178,"context_line":"                if slots \u003e 0:"},{"line_number":2179,"context_line":"                    LOG.warning(\"Host does not support %s but function %s \""},{"line_number":2180,"context_line":"                                \"returns number of slots %d.\", slots)"},{"line_number":2181,"context_line":""},{"line_number":2182,"context_line":"            inventories[modelsym] \u003d inv"},{"line_number":2183,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"6de974ec_625f3a93","line":2180,"range":{"start_line":2179,"start_character":62,"end_line":2180,"end_character":69},"in_reply_to":"d6cd5d4b_9f3ae730","updated":"2026-03-05 14:18:36.000000000","message":"Done","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":true,"context_lines":[{"line_number":2187,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2188,"context_line":"        if self.supports_amd_sev:"},{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"}],"source_content_type":"text/x-python","patch_set":10,"id":"230519fb_2ec6c51a","line":2190,"updated":"2026-02-26 15:21:19.000000000","message":"is this field reported from libvirt? if so can this be really missing?","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"09a72ce045571269b91a75615852b964a2144a2c","unresolved":true,"context_lines":[{"line_number":2187,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2188,"context_line":"        if self.supports_amd_sev:"},{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"}],"source_content_type":"text/x-python","patch_set":10,"id":"ae13c2c1_5111f856","line":2190,"in_reply_to":"230519fb_2ec6c51a","updated":"2026-02-26 15:58:12.000000000","message":"this is an optional flag AFAICU https://libvirt.org/formatdomaincaps.html#sev-capabilities so yeah this can be None","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"49da64e640b2af4ecaafd59cf562f84e99e5e610","unresolved":false,"context_lines":[{"line_number":2187,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2188,"context_line":"        if self.supports_amd_sev:"},{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"}],"source_content_type":"text/x-python","patch_set":10,"id":"aa8a28d0_2991e71d","line":2190,"in_reply_to":"a55dc387_bba30ad1","updated":"2026-03-05 14:18:36.000000000","message":"Acknowledged","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"c663b389718f155782c5fe70a15428a62a2b2926","unresolved":true,"context_lines":[{"line_number":2187,"context_line":"        conf_slots \u003d CONF.libvirt.num_memory_encrypted_guests"},{"line_number":2188,"context_line":"        if self.supports_amd_sev:"},{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"}],"source_content_type":"text/x-python","patch_set":10,"id":"a55dc387_bba30ad1","line":2190,"in_reply_to":"ae13c2c1_5111f856","updated":"2026-02-27 08:33:30.000000000","message":"Yes. libvirt(\u003e8.00) provides the maximum number of guests per SEV host. In case that where older libvirt do not provide this, `max_sev_guests` can be None ([code link](https://github.com/openstack/nova/blob/7927ab4205b6d749e92b88073e5f000b2e5abc21/nova/virt/libvirt/config.py#L368))","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"35e75d2a48bfc9d702747b3c5f64762f539313c5","unresolved":true,"context_lines":[{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"},{"line_number":2194,"context_line":"                    LOG.warning(\"Host is configured with \""},{"line_number":2195,"context_line":"                                \"libvirt.num_memory_encrypted_guests set \""}],"source_content_type":"text/x-python","patch_set":10,"id":"c1bc8b57_3772217b","line":2192,"updated":"2026-02-26 15:21:19.000000000","message":"does CONF.libvirt.num_memory_encrypted_guests defined in a way that its value can be None?","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"c663b389718f155782c5fe70a15428a62a2b2926","unresolved":true,"context_lines":[{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"},{"line_number":2194,"context_line":"                    LOG.warning(\"Host is configured with \""},{"line_number":2195,"context_line":"                                \"libvirt.num_memory_encrypted_guests set \""}],"source_content_type":"text/x-python","patch_set":10,"id":"b78419bd_74ef8bf9","line":2192,"in_reply_to":"ac1383f3_a858fd1c","updated":"2026-02-27 08:33:30.000000000","message":"Yes. `num_memory_encrypted_guest` can be None when cloud operators do not set options([code link](https://github.com/openstack/nova/blob/7927ab4205b6d749e92b88073e5f000b2e5abc21/nova/conf/libvirt.py#L869)).","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"49da64e640b2af4ecaafd59cf562f84e99e5e610","unresolved":false,"context_lines":[{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"},{"line_number":2194,"context_line":"                    LOG.warning(\"Host is configured with \""},{"line_number":2195,"context_line":"                                \"libvirt.num_memory_encrypted_guests set \""}],"source_content_type":"text/x-python","patch_set":10,"id":"633d0208_a5d1dac3","line":2192,"in_reply_to":"b78419bd_74ef8bf9","updated":"2026-03-05 14:18:36.000000000","message":"Acknowledged","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"09a72ce045571269b91a75615852b964a2144a2c","unresolved":true,"context_lines":[{"line_number":2189,"context_line":"            slots \u003d db_const.MAX_INT"},{"line_number":2190,"context_line":"            if self.max_sev_guests is not None:"},{"line_number":2191,"context_line":"                slots \u003d self.max_sev_guests"},{"line_number":2192,"context_line":"            if conf_slots is not None:"},{"line_number":2193,"context_line":"                if conf_slots \u003e slots:"},{"line_number":2194,"context_line":"                    LOG.warning(\"Host is configured with \""},{"line_number":2195,"context_line":"                                \"libvirt.num_memory_encrypted_guests set \""}],"source_content_type":"text/x-python","patch_set":10,"id":"ac1383f3_a858fd1c","line":2192,"in_reply_to":"c1bc8b57_3772217b","updated":"2026-02-26 15:58:12.000000000","message":"ditto, this can be optional AFAICU","commit_id":"8e780914d2fda0c972b43dc6aa1f3a73ef215925"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"bb99eccd1c449dd44489e8ce580d21a0814adef1","unresolved":true,"context_lines":[{"line_number":2182,"context_line":"                slots \u003d min(slots, conf_slots)"},{"line_number":2183,"context_line":"            return slots"},{"line_number":2184,"context_line":"        else:"},{"line_number":2185,"context_line":"            if conf_slots is not None:"},{"line_number":2186,"context_line":"                LOG.warning(\"Host is configured with \""},{"line_number":2187,"context_line":"                            \"libvirt.num_memory_encrypted_guests set to \""},{"line_number":2188,"context_line":"                            \"%d, but is not SEV-capable.\", conf_slots)"}],"source_content_type":"text/x-python","patch_set":14,"id":"ed4bc5cf_5a4c26fc","line":2185,"updated":"2026-04-10 14:34:28.000000000","message":"any reason why you didn\u0027t followed the previous conditional ?\n```            if conf_slots and conf_slots \u003e 0: ```\n\nnote: not holding the merge for that point","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"},{"author":{"_account_id":35307,"name":"Taketani Ryo","email":"taketani.ryo@fujitsu.com","username":"r-taketn0517"},"change_message_id":"405b889cdd95090156418c56f865a47c9b101a02","unresolved":true,"context_lines":[{"line_number":2182,"context_line":"                slots \u003d min(slots, conf_slots)"},{"line_number":2183,"context_line":"            return slots"},{"line_number":2184,"context_line":"        else:"},{"line_number":2185,"context_line":"            if conf_slots is not None:"},{"line_number":2186,"context_line":"                LOG.warning(\"Host is configured with \""},{"line_number":2187,"context_line":"                            \"libvirt.num_memory_encrypted_guests set to \""},{"line_number":2188,"context_line":"                            \"%d, but is not SEV-capable.\", conf_slots)"}],"source_content_type":"text/x-python","patch_set":14,"id":"b0fedccf_6cd39de1","line":2185,"in_reply_to":"ed4bc5cf_5a4c26fc","updated":"2026-04-15 00:21:31.000000000","message":"Thanks. There\u0027s not any reason why I changed conditions. I will address this in the follow-up patch.","commit_id":"6a4f01092f42fbebb802d7ec949913461edd8c35"}]}
