)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"41efbdc9fd4a28991afee403edfff47d4e2b04c8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"47ddf3e6_426dbc8f","updated":"2023-12-18 19:23:36.000000000","message":"Hm, yeah ... this was added by the ephemeral encryption series and the pattern of the \u0027encryption\u0027 dict is used _everywhere_ in the series. Is there not a way to resolve the mypy error without changing this to not a dict? I\u0027ll take a look at this locally to get some insight as to what is an issue here.","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"01129e987b6e91669b2dade726170bf1164330e8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"5c36cc3f_06d67e59","updated":"2023-12-15 13:10:19.000000000","message":"recheck unrelated failure","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"2ce4aed404d7a40d939f8bec7ddd42a09696dafc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"2f68d83e_4bd78d70","updated":"2023-12-18 17:19:30.000000000","message":"this is likely to impact mel\u0027s series so adding her for visibility","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"0d8fe2dfd503b732683a1d0f0f491def636210cb","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"f5360961_8aff58a7","in_reply_to":"29ff3939_08675581","updated":"2023-12-19 16:40:48.000000000","message":"Looks like it did. New revision pushed.","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"a6285ef3c4616f13497e0e3f4073dafe2317e06f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b317d9c8_2c95d293","in_reply_to":"47ddf3e6_426dbc8f","updated":"2023-12-18 19:56:45.000000000","message":"(update) I don\u0027t get any failures when I run \u0027tox -emypy\u0027 locally and nova/virt/libvirt/utils.py is in mypy-files.txt, so I\u0027m not sure what\u0027s wrong?","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"860af956122d187325c8c1727dec000f75926c90","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b50277fe_1a87b427","in_reply_to":"8a8e8f7d_a51f3f89","updated":"2023-12-19 15:44:48.000000000","message":"NamedTuple would be a-okay, as would a `TypedDict`. I might actually try the latter first to experiment with it.","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"7107efdc1aab665523af49b2074f768f1840926c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"b80e31dc_c283a50f","in_reply_to":"b317d9c8_2c95d293","updated":"2023-12-18 20:45:59.000000000","message":"You need to bump the version of mypy to see the issue. That\u0027s what we\u0027re seeing in [`openstack/requirements` failures](https://review.opendev.org/c/openstack/requirements/+/896970?tab\u003dchange-view-tab-header-zuul-results-summary).\n\nWe could rework this to keep using the dict, but we need to add some defensive coding and error out if those required keys are missing or the types of values aren\u0027t valid. I just figured it would be easier to replace the dict to better reflect the values we want though it sounds like no","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"1caea49a27e10d948e8ec40f78a223ca5f6ceb70","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"29ff3939_08675581","in_reply_to":"b50277fe_1a87b427","updated":"2023-12-19 16:10:00.000000000","message":"https://peps.python.org/pep-0589/ it was added in 3.8 so TypedDict would be fine if it works","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fcf6facb020dd96f2e748f3dfbc62311386b05fe","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"8a8e8f7d_a51f3f89","in_reply_to":"b80e31dc_c283a50f","updated":"2023-12-18 21:45:02.000000000","message":"Thanks. Yeah.. the dict is that way in part to allow for possible future expansion of the encryption attributes, such as encryption_options. The encryption info is part of the base imagebackend APIs in the ephemeral encryption series and it\u0027s passed to many functions/methods outside of imagebackend as well, so grouping the related attributes together is useful.\n\nI tried some stuff locally with mypy\u003d\u003d1.7.1 and it seems like using a namedtuple could work in place of the dict, what do you think?","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"33943f6d9c32d25ad098a91fdc123564ec0f9d6d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"bf6c3f4d_e912f153","updated":"2023-12-19 22:35:05.000000000","message":"This is much better, thanks!","commit_id":"298ca28e0f807bebc477743d9074f78b0a8784db"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fb68dec6528fa8b2220a7050baaea64c82825845","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"a3778b31_d264ddfb","updated":"2023-12-20 00:46:52.000000000","message":"recheck kernel: Out of memory: Killed process 48137 (mysqld) total-vm:4932292kB, anon-rss:638664kB, file-rss:0kB, shmem-rss:0kB, UID:116 pgtables:2272kB oom_score_adj:0","commit_id":"298ca28e0f807bebc477743d9074f78b0a8784db"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bf888b2d6256e5c43925afc482e7a2bf55bdabae","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"3db8e010_9bae29e0","updated":"2023-12-19 22:30:55.000000000","message":"recheck tempest-integrated-compute-rbac-old-defaults TIMED_OUT no tests failed","commit_id":"298ca28e0f807bebc477743d9074f78b0a8784db"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"cce540591ca6a782fa1cdb2990e00d4449ef39ac","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"d3c16c4c_289f4a0a","updated":"2023-12-20 10:37:09.000000000","message":"recheck timeout","commit_id":"298ca28e0f807bebc477743d9074f78b0a8784db"}],"nova/virt/libvirt/utils.py":[{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fcf6facb020dd96f2e748f3dfbc62311386b05fe","unresolved":true,"context_lines":[{"line_number":121,"context_line":"# global directory for emulated TPM"},{"line_number":122,"context_line":"VTPM_DIR \u003d \u0027/var/lib/libvirt/swtpm/\u0027"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"def create_image("},{"line_number":126,"context_line":"    path: str,"},{"line_number":127,"context_line":"    disk_format: str,"}],"source_content_type":"text/x-python","patch_set":2,"id":"8d9be7f3_29dd0fa1","line":124,"updated":"2023-12-18 21:45:02.000000000","message":"Locally I tried:\n```\nEncryption \u003d collections.namedtuple(\n    \u0027Encryption\u0027, [\u0027format\u0027, \u0027secret\u0027], defaults\u003d(None, None))\n```","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bf888b2d6256e5c43925afc482e7a2bf55bdabae","unresolved":false,"context_lines":[{"line_number":121,"context_line":"# global directory for emulated TPM"},{"line_number":122,"context_line":"VTPM_DIR \u003d \u0027/var/lib/libvirt/swtpm/\u0027"},{"line_number":123,"context_line":""},{"line_number":124,"context_line":""},{"line_number":125,"context_line":"def create_image("},{"line_number":126,"context_line":"    path: str,"},{"line_number":127,"context_line":"    disk_format: str,"}],"source_content_type":"text/x-python","patch_set":2,"id":"88a85725_590f000d","line":124,"in_reply_to":"8d9be7f3_29dd0fa1","updated":"2023-12-19 22:30:55.000000000","message":"Acknowledged","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fcf6facb020dd96f2e748f3dfbc62311386b05fe","unresolved":true,"context_lines":[{"line_number":129,"context_line":"    backing_file: ty.Optional[str] \u003d None,"},{"line_number":130,"context_line":"    *,"},{"line_number":131,"context_line":"    encryption_secret: ty.Optional[str] \u003d None,"},{"line_number":132,"context_line":"    encryption_format: ty.Optional[str] \u003d None,"},{"line_number":133,"context_line":") -\u003e None:"},{"line_number":134,"context_line":"    \"\"\"Disk image creation with qemu-img"},{"line_number":135,"context_line":"    :param path: Desired location of the disk image"}],"source_content_type":"text/x-python","patch_set":2,"id":"eee4df3f_32ab7693","line":132,"updated":"2023-12-18 21:45:02.000000000","message":"And:\n`encryption: ty.Optional[Encryption] \u003d None,` or `encryption: ty.Optional[\u0027Encryption\u0027] \u003d None,`","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bf888b2d6256e5c43925afc482e7a2bf55bdabae","unresolved":false,"context_lines":[{"line_number":129,"context_line":"    backing_file: ty.Optional[str] \u003d None,"},{"line_number":130,"context_line":"    *,"},{"line_number":131,"context_line":"    encryption_secret: ty.Optional[str] \u003d None,"},{"line_number":132,"context_line":"    encryption_format: ty.Optional[str] \u003d None,"},{"line_number":133,"context_line":") -\u003e None:"},{"line_number":134,"context_line":"    \"\"\"Disk image creation with qemu-img"},{"line_number":135,"context_line":"    :param path: Desired location of the disk image"}],"source_content_type":"text/x-python","patch_set":2,"id":"5e483aa9_56593792","line":132,"in_reply_to":"eee4df3f_32ab7693","updated":"2023-12-19 22:30:55.000000000","message":"Acknowledged","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fcf6facb020dd96f2e748f3dfbc62311386b05fe","unresolved":true,"context_lines":[{"line_number":181,"context_line":"    if encryption_secret and encryption_format:"},{"line_number":182,"context_line":"        with tempfile.NamedTemporaryFile(mode\u003d\u0027tr+\u0027, encoding\u003d\u0027utf-8\u0027) as f:"},{"line_number":183,"context_line":"            # Write out the passphrase secret to a temp file"},{"line_number":184,"context_line":"            f.write(encryption_secret)"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"            # Ensure the secret is written to disk, we can\u0027t .close() here as"},{"line_number":187,"context_line":"            # that removes the file when using NamedTemporaryFile"}],"source_content_type":"text/x-python","patch_set":2,"id":"8719aaf8_77f2c706","line":184,"updated":"2023-12-18 21:45:02.000000000","message":"And\n`f.write(encryption.secret)`","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bf888b2d6256e5c43925afc482e7a2bf55bdabae","unresolved":false,"context_lines":[{"line_number":181,"context_line":"    if encryption_secret and encryption_format:"},{"line_number":182,"context_line":"        with tempfile.NamedTemporaryFile(mode\u003d\u0027tr+\u0027, encoding\u003d\u0027utf-8\u0027) as f:"},{"line_number":183,"context_line":"            # Write out the passphrase secret to a temp file"},{"line_number":184,"context_line":"            f.write(encryption_secret)"},{"line_number":185,"context_line":""},{"line_number":186,"context_line":"            # Ensure the secret is written to disk, we can\u0027t .close() here as"},{"line_number":187,"context_line":"            # that removes the file when using NamedTemporaryFile"}],"source_content_type":"text/x-python","patch_set":2,"id":"2970e577_bc47758e","line":184,"in_reply_to":"8719aaf8_77f2c706","updated":"2023-12-19 22:30:55.000000000","message":"Acknowledged","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"fcf6facb020dd96f2e748f3dfbc62311386b05fe","unresolved":true,"context_lines":[{"line_number":191,"context_line":"            encryption_opts \u003d ["},{"line_number":192,"context_line":"                \u0027--object\u0027, f\"secret,id\u003dsec,file\u003d{f.name}\","},{"line_number":193,"context_line":"                \u0027-o\u0027, \u0027encrypt.key-secret\u003dsec\u0027,"},{"line_number":194,"context_line":"                \u0027-o\u0027, f\"encrypt.format\u003d{encryption_format}\","},{"line_number":195,"context_line":"            ]"},{"line_number":196,"context_line":"            # Supported luks options:"},{"line_number":197,"context_line":"            #  cipher-alg\u003d\u003cstr\u003e       - Name of cipher algorithm and key length"}],"source_content_type":"text/x-python","patch_set":2,"id":"bfa7de32_eaf66b27","line":194,"updated":"2023-12-18 21:45:02.000000000","message":"And\n`\u0027-o\u0027, f\"encrypt.format\u003d{encryption.format}\",`","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"bf888b2d6256e5c43925afc482e7a2bf55bdabae","unresolved":false,"context_lines":[{"line_number":191,"context_line":"            encryption_opts \u003d ["},{"line_number":192,"context_line":"                \u0027--object\u0027, f\"secret,id\u003dsec,file\u003d{f.name}\","},{"line_number":193,"context_line":"                \u0027-o\u0027, \u0027encrypt.key-secret\u003dsec\u0027,"},{"line_number":194,"context_line":"                \u0027-o\u0027, f\"encrypt.format\u003d{encryption_format}\","},{"line_number":195,"context_line":"            ]"},{"line_number":196,"context_line":"            # Supported luks options:"},{"line_number":197,"context_line":"            #  cipher-alg\u003d\u003cstr\u003e       - Name of cipher algorithm and key length"}],"source_content_type":"text/x-python","patch_set":2,"id":"d256c712_460a30f5","line":194,"in_reply_to":"bfa7de32_eaf66b27","updated":"2023-12-19 22:30:55.000000000","message":"Acknowledged","commit_id":"db013b45e9e123a979c4cba686a001228c49df9f"}]}
