)]}'
{"doc/source/user/flavors.rst":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"5fa22ed8064149912c9da672cca239aa600d5584","unresolved":true,"context_lines":[{"line_number":507,"context_line":"  **socket**"},{"line_number":508,"context_line":"      This means that the PCI device must be affined to the same host socket as"},{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"}],"source_content_type":"text/x-rst","patch_set":12,"id":"0121d2f7_cb780d43","line":510,"range":{"start_line":510,"start_character":6,"end_line":510,"end_character":7},"updated":"2021-02-24 10:40:55.000000000","message":"two","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"5fa22ed8064149912c9da672cca239aa600d5584","unresolved":true,"context_lines":[{"line_number":507,"context_line":"  **socket**"},{"line_number":508,"context_line":"      This means that the PCI device must be affined to the same host socket as"},{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"}],"source_content_type":"text/x-rst","patch_set":12,"id":"98ec05d3_4d7aa2f3","line":510,"range":{"start_line":510,"start_character":27,"end_line":510,"end_character":28},"updated":"2021-02-24 10:40:55.000000000","message":"two","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":507,"context_line":"  **socket**"},{"line_number":508,"context_line":"      This means that the PCI device must be affined to the same host socket as"},{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"}],"source_content_type":"text/x-rst","patch_set":12,"id":"c3f0378a_96af6921","line":510,"range":{"start_line":510,"start_character":6,"end_line":510,"end_character":7},"in_reply_to":"0121d2f7_cb780d43","updated":"2021-02-24 11:18:09.000000000","message":"Done","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":507,"context_line":"  **socket**"},{"line_number":508,"context_line":"      This means that the PCI device must be affined to the same host socket as"},{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"}],"source_content_type":"text/x-rst","patch_set":12,"id":"83785dcf_5c20d7ba","line":510,"range":{"start_line":510,"start_character":27,"end_line":510,"end_character":28},"in_reply_to":"98ec05d3_4d7aa2f3","updated":"2021-02-24 11:18:09.000000000","message":"Done","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"5fa22ed8064149912c9da672cca239aa600d5584","unresolved":true,"context_lines":[{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"},{"line_number":514,"context_line":"      "},{"line_number":515,"context_line":"      * node 0 and node 1"}],"source_content_type":"text/x-rst","patch_set":12,"id":"0d826bec_454c9002","line":512,"range":{"start_line":512,"start_character":35,"end_line":512,"end_character":36},"updated":"2021-02-24 10:40:55.000000000","message":"two\n\n(the other numbers inbetween are okay since they\u0027re indexes)","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":509,"context_line":"      at least one of the guest NUMA nodes. For example, consider a system with"},{"line_number":510,"context_line":"      2 sockets, each with 2 NUMA nodes, numbered node 0 and node 1 on socket"},{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"},{"line_number":514,"context_line":"      "},{"line_number":515,"context_line":"      * node 0 and node 1"}],"source_content_type":"text/x-rst","patch_set":12,"id":"7d701a24_e0b570ee","line":512,"range":{"start_line":512,"start_character":35,"end_line":512,"end_character":36},"in_reply_to":"0d826bec_454c9002","updated":"2021-02-24 11:18:09.000000000","message":"Done","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"5fa22ed8064149912c9da672cca239aa600d5584","unresolved":true,"context_lines":[{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"},{"line_number":514,"context_line":"      "},{"line_number":515,"context_line":"      * node 0 and node 1"},{"line_number":516,"context_line":"      * node 0 and node 2"},{"line_number":517,"context_line":"      * node 0 and node 3"}],"source_content_type":"text/x-rst","patch_set":12,"id":"50e13aea_8587b680","line":514,"range":{"start_line":514,"start_character":0,"end_line":514,"end_character":6},"updated":"2021-02-24 10:40:55.000000000","message":"whoops","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"},{"line_number":514,"context_line":"      "},{"line_number":515,"context_line":"      * node 0 and node 1"},{"line_number":516,"context_line":"      * node 0 and node 2"},{"line_number":517,"context_line":"      * node 0 and node 3"}],"source_content_type":"text/x-rst","patch_set":12,"id":"3558eb17_c87c97a5","line":514,"range":{"start_line":514,"start_character":0,"end_line":514,"end_character":6},"in_reply_to":"50e13aea_8587b680","updated":"2021-02-24 11:18:09.000000000","message":"Done","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"c6fb471b177c3a1bd3bd75da88664a72bff0ed99","unresolved":true,"context_lines":[{"line_number":511,"context_line":"      0, and node 2 and node 3 on socket 1. There is a PCI device affined to"},{"line_number":512,"context_line":"      node 0. An PCI instance with 2 guest NUMA nodes and the ``socket`` policy"},{"line_number":513,"context_line":"      can be affined to either:"},{"line_number":514,"context_line":"      "},{"line_number":515,"context_line":"      * node 0 and node 1"},{"line_number":516,"context_line":"      * node 0 and node 2"},{"line_number":517,"context_line":"      * node 0 and node 3"}],"source_content_type":"text/x-rst","patch_set":14,"id":"617e6165_3c6f5e3e","line":514,"updated":"2021-02-24 10:41:23.000000000","message":"tab?","commit_id":"a1d7aa86fc70e7b4ea262f972bf4148cf0e7f079"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"6254c3a7_e25e8fdd","updated":"2021-02-24 11:18:09.000000000","message":"This doc really needs to go. The info on PCI NUMA Affinity Policies actually belongs in the pci-passthrough doc, and none of the other extra specs should be in the user guide (a non-admin user typically can\u0027t customize them as policy doesn\u0027t allow for that)","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":15,"id":"07996645_4391d893","in_reply_to":"6254c3a7_e25e8fdd","updated":"2021-03-04 14:02:06.000000000","message":"Fair point, though I guess we\u0027re saying \"document the new thing in the old place for now, and move the old place to a new place in a later patch\", right?","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"}],"nova/pci/stats.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"5fa22ed8064149912c9da672cca239aa600d5584","unresolved":true,"context_lines":[{"line_number":299,"context_line":"            return filtered_pools"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"        # The SOCKET policy is a bit of a special case. It\u0027s less strict than"},{"line_number":302,"context_line":"        # REQUIRED (so REQUIRED will automatically fulfill SOCKET, at least"},{"line_number":303,"context_line":"        # with our assumption of never having multiple sockets per NUMA node),"},{"line_number":304,"context_line":"        # but not always more strict than LEGACY: a PCI device with no NUMA"},{"line_number":305,"context_line":"        # affinity will fulfill LEGACY but not SOCKET. If we have SOCKET,"}],"source_content_type":"text/x-python","patch_set":12,"id":"c734d696_2d74bb1d","line":302,"range":{"start_line":302,"start_character":51,"end_line":302,"end_character":58},"updated":"2021-02-24 10:40:55.000000000","message":"fulfil","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":299,"context_line":"            return filtered_pools"},{"line_number":300,"context_line":""},{"line_number":301,"context_line":"        # The SOCKET policy is a bit of a special case. It\u0027s less strict than"},{"line_number":302,"context_line":"        # REQUIRED (so REQUIRED will automatically fulfill SOCKET, at least"},{"line_number":303,"context_line":"        # with our assumption of never having multiple sockets per NUMA node),"},{"line_number":304,"context_line":"        # but not always more strict than LEGACY: a PCI device with no NUMA"},{"line_number":305,"context_line":"        # affinity will fulfill LEGACY but not SOCKET. If we have SOCKET,"}],"source_content_type":"text/x-python","patch_set":12,"id":"81fcf12b_888d3417","line":302,"range":{"start_line":302,"start_character":51,"end_line":302,"end_character":58},"in_reply_to":"c734d696_2d74bb1d","updated":"2021-02-24 11:18:09.000000000","message":"Done","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":false,"context_lines":[{"line_number":302,"context_line":"        # REQUIRED (so REQUIRED will automatically fulfill SOCKET, at least"},{"line_number":303,"context_line":"        # with our assumption of never having multiple sockets per NUMA node),"},{"line_number":304,"context_line":"        # but not always more strict than LEGACY: a PCI device with no NUMA"},{"line_number":305,"context_line":"        # affinity will fulfill LEGACY but not SOCKET. If we have SOCKET,"},{"line_number":306,"context_line":"        # process it here and don\u0027t continue."},{"line_number":307,"context_line":"        if requested_policy \u003d\u003d fields.PCINUMAAffinityPolicy.SOCKET:"},{"line_number":308,"context_line":"            return self._filter_pools_for_socket_affinity(pools, numa_cells)"}],"source_content_type":"text/x-python","patch_set":12,"id":"eadc1931_6d2789a6","line":305,"range":{"start_line":305,"start_character":24,"end_line":305,"end_character":31},"updated":"2021-02-24 11:18:09.000000000","message":"Here too","commit_id":"dc22521c82797947f143a99d5789d516833e9dec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":345,"context_line":"        # for each pool, look up the socket of its host NUMA node and save it"},{"line_number":346,"context_line":"        # as the pool socket"},{"line_number":347,"context_line":"        for pool in pools:"},{"line_number":348,"context_line":"            pool[\u0027socket\u0027] \u003d None"},{"line_number":349,"context_line":"            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)"},{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"}],"source_content_type":"text/x-python","patch_set":15,"id":"4eac0bd6_36f3b6d2","line":348,"updated":"2021-02-24 11:18:09.000000000","message":"Isn\u0027t this unnecessary? It\u0027ll always be set, based on the above, unless we have a situation where a given \u0027numa_node\u0027 doesn\u0027t exist on the host in which case we probably want to crash and burn (programmer error)","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":true,"context_lines":[{"line_number":345,"context_line":"        # for each pool, look up the socket of its host NUMA node and save it"},{"line_number":346,"context_line":"        # as the pool socket"},{"line_number":347,"context_line":"        for pool in pools:"},{"line_number":348,"context_line":"            pool[\u0027socket\u0027] \u003d None"},{"line_number":349,"context_line":"            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)"},{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"}],"source_content_type":"text/x-python","patch_set":15,"id":"9b569324_f9e9b419","line":348,"in_reply_to":"4eac0bd6_36f3b6d2","updated":"2021-03-04 14:02:06.000000000","message":"You made me think about it, but yeah, it\u0027s necessary because the pool might not have numa_node information on L349 and L350. So if we never enter that if, we want a default value of None for pool[\u0027socket\u0027].","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b4445afba6d2124f87582fb6f2e22e9ba4ef6b44","unresolved":false,"context_lines":[{"line_number":345,"context_line":"        # for each pool, look up the socket of its host NUMA node and save it"},{"line_number":346,"context_line":"        # as the pool socket"},{"line_number":347,"context_line":"        for pool in pools:"},{"line_number":348,"context_line":"            pool[\u0027socket\u0027] \u003d None"},{"line_number":349,"context_line":"            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)"},{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"}],"source_content_type":"text/x-python","patch_set":15,"id":"bc71e4a0_47d50e3f","line":348,"in_reply_to":"9b569324_f9e9b419","updated":"2021-03-09 17:36:08.000000000","message":"Ack","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"},{"line_number":352,"context_line":"                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:"},{"line_number":353,"context_line":"                        pool[\u0027socket\u0027] \u003d cell.socket"},{"line_number":354,"context_line":""},{"line_number":355,"context_line":"        # get a list of host sockets that the guest cells are in. Since guest"},{"line_number":356,"context_line":"        # cell IDs map to host cell IDs, we can just lookup the latter\u0027s"}],"source_content_type":"text/x-python","patch_set":15,"id":"0436bd55_517f6017","line":353,"updated":"2021-02-24 11:18:09.000000000","message":"\u0027break\u0027? That allows you to add an else clause and a generic NovaException-derived error","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":true,"context_lines":[{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"},{"line_number":352,"context_line":"                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:"},{"line_number":353,"context_line":"                        pool[\u0027socket\u0027] \u003d cell.socket"},{"line_number":354,"context_line":""},{"line_number":355,"context_line":"        # get a list of host sockets that the guest cells are in. Since guest"},{"line_number":356,"context_line":"        # cell IDs map to host cell IDs, we can just lookup the latter\u0027s"}],"source_content_type":"text/x-python","patch_set":15,"id":"594f49df_288cae06","line":353,"in_reply_to":"0436bd55_517f6017","updated":"2021-03-04 14:02:06.000000000","message":"The break makes sense (don\u0027t continue iterating the inner if once we\u0027ve found the socket), but I don\u0027t understand the NovaException?","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b4445afba6d2124f87582fb6f2e22e9ba4ef6b44","unresolved":true,"context_lines":[{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"},{"line_number":352,"context_line":"                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:"},{"line_number":353,"context_line":"                        pool[\u0027socket\u0027] \u003d cell.socket"},{"line_number":354,"context_line":""},{"line_number":355,"context_line":"        # get a list of host sockets that the guest cells are in. Since guest"},{"line_number":356,"context_line":"        # cell IDs map to host cell IDs, we can just lookup the latter\u0027s"}],"source_content_type":"text/x-python","patch_set":15,"id":"16f2b659_2a565019","line":353,"in_reply_to":"594f49df_288cae06","updated":"2021-03-09 17:36:08.000000000","message":"It was based on the idea that if we had \u0027numa_node\u0027 pool attribute and we weren\u0027t able to map that to a host_cell object then we had hit an error condition and should raise an exception. This is really programmer error so it\u0027s not a massive deal","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":355,"context_line":"        # get a list of host sockets that the guest cells are in. Since guest"},{"line_number":356,"context_line":"        # cell IDs map to host cell IDs, we can just lookup the latter\u0027s"},{"line_number":357,"context_line":"        # socket."},{"line_number":358,"context_line":"        socket_ids \u003d []"},{"line_number":359,"context_line":"        for guest_cell in numa_cells:"},{"line_number":360,"context_line":"            for host_cell in host_cells:"},{"line_number":361,"context_line":"                if guest_cell.id \u003d\u003d host_cell.id:"}],"source_content_type":"text/x-python","patch_set":15,"id":"09b40dc7_2f35ed20","line":358,"updated":"2021-02-24 11:18:09.000000000","message":"Can we make this a set. Duplicates are no harm but set lookups are faster and it\u0027s more \"correct\"","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[{"line_number":355,"context_line":"        # get a list of host sockets that the guest cells are in. Since guest"},{"line_number":356,"context_line":"        # cell IDs map to host cell IDs, we can just lookup the latter\u0027s"},{"line_number":357,"context_line":"        # socket."},{"line_number":358,"context_line":"        socket_ids \u003d []"},{"line_number":359,"context_line":"        for guest_cell in numa_cells:"},{"line_number":360,"context_line":"            for host_cell in host_cells:"},{"line_number":361,"context_line":"                if guest_cell.id \u003d\u003d host_cell.id:"}],"source_content_type":"text/x-python","patch_set":15,"id":"3ad91f22_3e99dd78","line":358,"in_reply_to":"09b40dc7_2f35ed20","updated":"2021-03-04 14:02:06.000000000","message":"Done","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"446ce70edcc79ca3f08d77420451653cd2adcb8d","unresolved":true,"context_lines":[{"line_number":344,"context_line":""},{"line_number":345,"context_line":"        # for each pool, look up the socket of its host NUMA node and save it"},{"line_number":346,"context_line":"        # as the pool socket"},{"line_number":347,"context_line":"        for pool in pools:"},{"line_number":348,"context_line":"            pool[\u0027socket\u0027] \u003d None"},{"line_number":349,"context_line":"            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)"},{"line_number":350,"context_line":"            if pool_numa_node is not None:"}],"source_content_type":"text/x-python","patch_set":17,"id":"2a482e90_a2eeaabd","line":347,"range":{"start_line":347,"start_character":4,"end_line":347,"end_character":1},"updated":"2021-03-09 22:25:24.000000000","message":"you do not need to do this every time so this is quite ineeffecnt\n\n        for pool in pools:\n            pool[\u0027socket\u0027] \u003d None\n            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)\n            if pool_numa_node is not None:\n                for cell in host_cells:\n                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:\n                        pool[\u0027socket\u0027] \u003d cell.socket\n                        break\n\ni think you can just do this.\n\n        for pool in pools:\n           if poll.get(\u0027socket\u0027) is None:\n            pool_numa_node \u003d pool.get(\u0027numa_node\u0027, None)\n            if pool_numa_node is not None:\n                cell \u003d host_cells[pool_numa_node]:\n                pool[\u0027socket\u0027] \u003d cell.socket\n                \nthe host_cells are sorted in numa order.","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"038441d4f71ff9541c1492638bbec292518a5aa7","unresolved":true,"context_lines":[{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"},{"line_number":352,"context_line":"                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:"},{"line_number":353,"context_line":"                        pool[\u0027socket\u0027] \u003d cell.socket"},{"line_number":354,"context_line":"                        break"},{"line_number":355,"context_line":""},{"line_number":356,"context_line":"        # get a set of host sockets that the guest cells are in. Since guest"}],"source_content_type":"text/x-python","patch_set":17,"id":"8ca479e3_beae443a","line":353,"updated":"2021-03-10 22:13:39.000000000","message":"With Sean\u0027s post policy patch on top of this, his functional tests discovered an issue with this. By setting this pool[\u0027socket\u0027], we\u0027re modifying the pool. This side effect affects pool equality later on. It goes unnoticed in my patch because my functional tests don\u0027t test any \"parent-having\" PCI device. Sean\u0027s does. We suspect that because the parent device never gets a socket, the equality fails, and it blows up, with the following traceback:\n\nTraceback (most recent call last):\n  File \"/home/artom/src/nova/nova/compute/manager.py\", line 2363, in _build_and_run_instance\n    with self.rt.instance_claim(context, instance, node, allocs,\n  File \"/home/artom/src/nova/.tox/functional/lib/python3.9/site-packages/oslo_concurrency/lockutils.py\", line 360, in inner\n    return f(*args, **kwargs)\n  File \"/home/artom/src/nova/nova/compute/resource_tracker.py\", line 185, in instance_claim\n    self.pci_tracker.claim_instance(context, pci_requests,\n  File \"/home/artom/src/nova/nova/pci/manager.py\", line 311, in claim_instance\n    devs \u003d self._claim_instance(context, pci_requests,\n  File \"/home/artom/src/nova/nova/pci/manager.py\", line 282, in _claim_instance\n    devs \u003d self.stats.consume_requests(pci_requests.requests,\n  File \"/home/artom/src/nova/nova/pci/stats.py\", line 211, in consume_requests\n    self._handle_device_dependents(pci_dev)\n  File \"/home/artom/src/nova/nova/pci/stats.py\", line 238, in _handle_device_dependents\n    self.remove_device(parent)\n  File \"/home/artom/src/nova/nova/pci/stats.py\", line 170, in remove_device\n    raise exception.PciDevicePoolEmpty(\nnova.exception.PciDevicePoolEmpty: Attempt to consume PCI device 1:0000:81:00.0 from empty pool","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"9443f640f397d4cc862b13d726365402465f4754","unresolved":false,"context_lines":[{"line_number":350,"context_line":"            if pool_numa_node is not None:"},{"line_number":351,"context_line":"                for cell in host_cells:"},{"line_number":352,"context_line":"                    if pool[\u0027numa_node\u0027] \u003d\u003d cell.id:"},{"line_number":353,"context_line":"                        pool[\u0027socket\u0027] \u003d cell.socket"},{"line_number":354,"context_line":"                        break"},{"line_number":355,"context_line":""},{"line_number":356,"context_line":"        # get a set of host sockets that the guest cells are in. Since guest"}],"source_content_type":"text/x-python","patch_set":17,"id":"3bcd79ab_488cd5b2","line":353,"in_reply_to":"8ca479e3_beae443a","updated":"2021-03-10 22:14:29.000000000","message":"Done","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"446ce70edcc79ca3f08d77420451653cd2adcb8d","unresolved":true,"context_lines":[{"line_number":361,"context_line":"            for host_cell in host_cells:"},{"line_number":362,"context_line":"                if guest_cell.id \u003d\u003d host_cell.id:"},{"line_number":363,"context_line":"                    socket_ids.add(host_cell.socket)"},{"line_number":364,"context_line":""},{"line_number":365,"context_line":"        # filter out pools that are not affined to any guest cell socket"},{"line_number":366,"context_line":"        return ["},{"line_number":367,"context_line":"            pool for pool in pools if any("}],"source_content_type":"text/x-python","patch_set":17,"id":"4f01aec7_a9978535","line":364,"updated":"2021-03-09 22:25:24.000000000","message":"socket_ids \u003d {host_cells[cell.id].socket for cell in numa_cells}\ni think ^ is the same  again using the fact host_cells shoudl be sorted by numa node so we can just index directly\neven if it was not sorted we could sort it by numa node at the top of the function we iterate over it multiple time in current patch so it would be much faster to sort it our converted it to a dict but it should already be sorated as i said hence strait index with []","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"}],"nova/tests/functional/libvirt/test_pci_sriov_servers.py":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"c6fb471b177c3a1bd3bd75da88664a72bff0ed99","unresolved":true,"context_lines":[{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1075,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"75ae2c7b_044ea82f","line":1072,"updated":"2021-02-24 10:41:23.000000000","message":"drop it","commit_id":"a1d7aa86fc70e7b4ea262f972bf4148cf0e7f079"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1075,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"44be32c7_82232c98","line":1072,"in_reply_to":"75ae2c7b_044ea82f","updated":"2021-03-04 14:02:06.000000000","message":"Done","commit_id":"a1d7aa86fc70e7b4ea262f972bf4148cf0e7f079"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":1035,"context_line":"        # This should pass."},{"line_number":1036,"context_line":"        host_info \u003d fakelibvirt.HostInfo("},{"line_number":1037,"context_line":"            cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2, cpu_threads\u003d2,"},{"line_number":1038,"context_line":"            kB_mem\u003d(16 * units.Gi) // units.Ki)"},{"line_number":1039,"context_line":"        self.flags(cpu_dedicated_set\u003d\u00270-3\u0027, group\u003d\u0027compute\u0027)"},{"line_number":1040,"context_line":"        pci_info \u003d fakelibvirt.HostPCIDevicesInfo(num_pci\u003d1, numa_node\u003d1)"},{"line_number":1041,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"c4050496_c3b895db","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":46},"updated":"2021-02-24 11:18:09.000000000","message":"nit: I know this is copy-paste stuff but this is kind of irrelevant here, no? ditto below","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b4445afba6d2124f87582fb6f2e22e9ba4ef6b44","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"        # This should pass."},{"line_number":1036,"context_line":"        host_info \u003d fakelibvirt.HostInfo("},{"line_number":1037,"context_line":"            cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2, cpu_threads\u003d2,"},{"line_number":1038,"context_line":"            kB_mem\u003d(16 * units.Gi) // units.Ki)"},{"line_number":1039,"context_line":"        self.flags(cpu_dedicated_set\u003d\u00270-3\u0027, group\u003d\u0027compute\u0027)"},{"line_number":1040,"context_line":"        pci_info \u003d fakelibvirt.HostPCIDevicesInfo(num_pci\u003d1, numa_node\u003d1)"},{"line_number":1041,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"84b2f08b_1a77f24f","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":46},"in_reply_to":"171d91fd_5eb690d3","updated":"2021-03-09 17:36:08.000000000","message":"I don\u0027t agree that we must be explicit, but I do see that the default is too low to be usable and fixing that would require another change. We should bump that in a follow-up though","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"b8ad2c3d24448924bf37111d0204fea382d0be9e","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"        # This should pass."},{"line_number":1036,"context_line":"        host_info \u003d fakelibvirt.HostInfo("},{"line_number":1037,"context_line":"            cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2, cpu_threads\u003d2,"},{"line_number":1038,"context_line":"            kB_mem\u003d(16 * units.Gi) // units.Ki)"},{"line_number":1039,"context_line":"        self.flags(cpu_dedicated_set\u003d\u00270-3\u0027, group\u003d\u0027compute\u0027)"},{"line_number":1040,"context_line":"        pci_info \u003d fakelibvirt.HostPCIDevicesInfo(num_pci\u003d1, numa_node\u003d1)"},{"line_number":1041,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"2c7efbea_85eaa636","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":46},"in_reply_to":"84b2f08b_1a77f24f","updated":"2021-03-09 18:36:47.000000000","message":"So I\u0027ll do two follow ups: one to fix all the nits in this series, and one to change the default here, which stands more on its own.","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"626477c5f6506b06ebf48e3c0865da3a1c434231","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"        # This should pass."},{"line_number":1036,"context_line":"        host_info \u003d fakelibvirt.HostInfo("},{"line_number":1037,"context_line":"            cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2, cpu_threads\u003d2,"},{"line_number":1038,"context_line":"            kB_mem\u003d(16 * units.Gi) // units.Ki)"},{"line_number":1039,"context_line":"        self.flags(cpu_dedicated_set\u003d\u00270-3\u0027, group\u003d\u0027compute\u0027)"},{"line_number":1040,"context_line":"        pci_info \u003d fakelibvirt.HostPCIDevicesInfo(num_pci\u003d1, numa_node\u003d1)"},{"line_number":1041,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"171d91fd_5eb690d3","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":46},"in_reply_to":"b83016cc_658bf1de","updated":"2021-03-04 14:18:15.000000000","message":"Ah, so no, we actually need this. The default is kB_mem\u003d4096, which is... 4*MB*, right? And the default for integrated_helpers\u0027 create_flavor() is memory_mb\u003d2048. A 2GB server won\u0027t fit in 4MB of RAM. We should probably just bump the fakelibvirt default to something more sensible, but really we should be explicit everywhere.\n\nFor instance, the test below this continues to pass with the kB_mem argument removed, except the scheduling is failing because of not enough memory, not because of PCI policy.","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"        # This should pass."},{"line_number":1036,"context_line":"        host_info \u003d fakelibvirt.HostInfo("},{"line_number":1037,"context_line":"            cpu_nodes\u003d2, cpu_sockets\u003d1, cpu_cores\u003d2, cpu_threads\u003d2,"},{"line_number":1038,"context_line":"            kB_mem\u003d(16 * units.Gi) // units.Ki)"},{"line_number":1039,"context_line":"        self.flags(cpu_dedicated_set\u003d\u00270-3\u0027, group\u003d\u0027compute\u0027)"},{"line_number":1040,"context_line":"        pci_info \u003d fakelibvirt.HostPCIDevicesInfo(num_pci\u003d1, numa_node\u003d1)"},{"line_number":1041,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"b83016cc_658bf1de","line":1038,"range":{"start_line":1038,"start_character":12,"end_line":1038,"end_character":46},"in_reply_to":"c4050496_c3b895db","updated":"2021-03-04 14:02:06.000000000","message":"Done","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":1067,"context_line":"            \u0027hw:pci_numa_affinity_policy\u0027: \u0027socket\u0027"},{"line_number":1068,"context_line":"        }"},{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"}],"source_content_type":"text/x-python","patch_set":15,"id":"8505854e_a6bd73f1","line":1070,"range":{"start_line":1070,"start_character":8,"end_line":1070,"end_character":14},"updated":"2021-02-24 11:18:09.000000000","message":"\u0027response\u0027 or \u0027error\u0027?","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":true,"context_lines":[{"line_number":1067,"context_line":"            \u0027hw:pci_numa_affinity_policy\u0027: \u0027socket\u0027"},{"line_number":1068,"context_line":"        }"},{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"}],"source_content_type":"text/x-python","patch_set":15,"id":"5cdee0ea_3dc83594","line":1070,"range":{"start_line":1070,"start_character":8,"end_line":1070,"end_character":14},"in_reply_to":"8505854e_a6bd73f1","updated":"2021-03-04 14:02:06.000000000","message":"Well, we still get a server JSON object back... I guess \u0027response\u0027 could make sense, but if I call this \u0027error\u0027, L1073 would become self.assertIn(\u0027fault\u0027, error), which is tautologically meaningless :)","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":1068,"context_line":"        }"},{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"}],"source_content_type":"text/x-python","patch_set":15,"id":"ab3a6b5d_5c621041","line":1071,"updated":"2021-02-24 11:18:09.000000000","message":"nit: could you drag things down to avoid the hanging indent?","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[{"line_number":1068,"context_line":"        }"},{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"}],"source_content_type":"text/x-python","patch_set":15,"id":"31eb1b48_025dcbf8","line":1071,"in_reply_to":"ab3a6b5d_5c621041","updated":"2021-03-04 14:02:06.000000000","message":"Done","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1075,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"77790950_4d35a3ad","line":1072,"updated":"2021-02-24 11:18:09.000000000","message":"whoops","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b4445afba6d2124f87582fb6f2e22e9ba4ef6b44","unresolved":false,"context_lines":[{"line_number":1069,"context_line":"        flavor_id \u003d self._create_flavor(extra_spec\u003dextra_spec)"},{"line_number":1070,"context_line":"        server \u003d self._create_server(flavor_id\u003dflavor_id,"},{"line_number":1071,"context_line":"                                     expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        print(server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1074,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1075,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"f06d2181_681b26f8","line":1072,"in_reply_to":"77790950_4d35a3ad","updated":"2021-03-09 17:36:08.000000000","message":"Done","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"446ce70edcc79ca3f08d77420451653cd2adcb8d","unresolved":true,"context_lines":[{"line_number":1070,"context_line":"        server \u003d self._create_server("},{"line_number":1071,"context_line":"            flavor_id\u003dflavor_id, expected_state\u003d\u0027ERROR\u0027)"},{"line_number":1072,"context_line":"        self.assertIn(\u0027fault\u0027, server)"},{"line_number":1073,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1074,"context_line":""},{"line_number":1075,"context_line":"    def test_socket_policy_multi_numa_pass(self):"},{"line_number":1076,"context_line":"        # 2 sockets, 2 NUMA nodes each, with the PCI device on NUMA 0 and"}],"source_content_type":"text/x-python","patch_set":17,"id":"311af897_1c2e5b48","line":1073,"updated":"2021-03-09 22:25:24.000000000","message":"ya i guess this works.\n\nwe dont often look at teh fault but i guess this is better then just expecting error.\nim not sure how much extra value it adds however since you are not asserting its filtered out by the pcipassthough or numa toplogy filters just that it got a no valid host.\n\nyou should probaly also do \nself.assertTrue(self.mock_filter.called)","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"446ce70edcc79ca3f08d77420451653cd2adcb8d","unresolved":true,"context_lines":[{"line_number":1073,"context_line":"        self.assertIn(\u0027No valid host\u0027, server[\u0027fault\u0027][\u0027message\u0027])"},{"line_number":1074,"context_line":""},{"line_number":1075,"context_line":"    def test_socket_policy_multi_numa_pass(self):"},{"line_number":1076,"context_line":"        # 2 sockets, 2 NUMA nodes each, with the PCI device on NUMA 0 and"},{"line_number":1077,"context_line":"        # socket 0. If we restrict cpu_dedicated_set to NUMA 1, 2 and 3, we"},{"line_number":1078,"context_line":"        # should still be able to boot an instance with hw:numa_nodes\u003d3 and the"},{"line_number":1079,"context_line":"        # `socket` policy, because one of the instance\u0027s NUMA nodes will be on"}],"source_content_type":"text/x-python","patch_set":17,"id":"f7499063_70e20beb","line":1076,"updated":"2021-03-09 22:25:24.000000000","message":"its a littel contrived but that works i guess\nyou could have also don 1 socket but 3 numa nodes and created a 2 numa guest but this works too and tests the edgecase","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"}],"nova/tests/unit/pci/test_stats.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":95,"context_line":"        for dev in devs:"},{"line_number":96,"context_line":"            self.pci_stats.add_device(objects.PciDevice.create(None, dev))"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"    def _setup_pci_stats(self, numa_topology\u003dNone):"},{"line_number":99,"context_line":"        if not numa_topology:"},{"line_number":100,"context_line":"            numa_topology \u003d objects.NUMATopology()"},{"line_number":101,"context_line":"        self.pci_stats \u003d stats.PciDeviceStats(numa_topology)"}],"source_content_type":"text/x-python","patch_set":15,"id":"2ce37a29_d106f4f3","line":98,"updated":"2021-02-24 11:18:09.000000000","message":"Um, why?\n\nLater: ah, this is used for tests below. Fair. Can we move this after the \u0027setUp\u0027 call so? It\u0027s odd being here","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":false,"context_lines":[{"line_number":95,"context_line":"        for dev in devs:"},{"line_number":96,"context_line":"            self.pci_stats.add_device(objects.PciDevice.create(None, dev))"},{"line_number":97,"context_line":""},{"line_number":98,"context_line":"    def _setup_pci_stats(self, numa_topology\u003dNone):"},{"line_number":99,"context_line":"        if not numa_topology:"},{"line_number":100,"context_line":"            numa_topology \u003d objects.NUMATopology()"},{"line_number":101,"context_line":"        self.pci_stats \u003d stats.PciDeviceStats(numa_topology)"}],"source_content_type":"text/x-python","patch_set":15,"id":"742e5709_33f64a89","line":98,"in_reply_to":"2ce37a29_d106f4f3","updated":"2021-03-04 14:02:06.000000000","message":"Done","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4e8c98d233e17cdb192bca0064f788f954369245","unresolved":true,"context_lines":[{"line_number":7909,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":7910,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":7911,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":7912,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":7913,"context_line":""},{"line_number":7914,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":7915,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":15,"id":"496f8b1f_83471091","line":7912,"updated":"2021-02-24 11:18:09.000000000","message":"This works, but the way we typically do this is via driver capabilities. See \u0027supports_pcpu\u0027 for examples.","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"329f90c671de531c3091c502ca7029b3e732e758","unresolved":true,"context_lines":[{"line_number":7909,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":7910,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":7911,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":7912,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":7913,"context_line":""},{"line_number":7914,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":7915,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":15,"id":"bae46973_ebe7f4c7","line":7912,"in_reply_to":"496f8b1f_83471091","updated":"2021-03-04 14:02:06.000000000","message":"OK, but how does that get translated into traits, if at all? We still need to report the trait for the scheduler to be able to pick us...","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"b8ad2c3d24448924bf37111d0204fea382d0be9e","unresolved":true,"context_lines":[{"line_number":7909,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":7910,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":7911,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":7912,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":7913,"context_line":""},{"line_number":7914,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":7915,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":15,"id":"e83bcd41_19272294","line":7912,"in_reply_to":"b9fbc884_dd0b02bc","updated":"2021-03-09 18:36:47.000000000","message":"Ah, done then.","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b4445afba6d2124f87582fb6f2e22e9ba4ef6b44","unresolved":true,"context_lines":[{"line_number":7909,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":7910,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":7911,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":7912,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":7913,"context_line":""},{"line_number":7914,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":7915,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":15,"id":"b9fbc884_dd0b02bc","line":7912,"in_reply_to":"bae46973_ebe7f4c7","updated":"2021-03-09 17:36:08.000000000","message":"The base virt driver class does it for us [1][2]\n\n[1] https://github.com/openstack/nova/blob/31889ce296d1e1a62fe5825292479009118ddfab/nova/virt/driver.py#L103-L133\n[2] https://github.com/openstack/nova/blob/31889ce296d1e1a62fe5825292479009118ddfab/nova/virt/driver.py#L1082-L1101","commit_id":"09832bb700b6761980aab7be260ccb3388bfb5ec"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"16f22745e84c0ed0c31958d3f3905bd52f63a64b","unresolved":true,"context_lines":[{"line_number":8105,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":8106,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":8107,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":8108,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":8109,"context_line":""},{"line_number":8110,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":8111,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":17,"id":"3ae2a651_37170dae","line":8108,"updated":"2021-03-09 17:38:22.000000000","message":"I\u0027d still like to see this done via capabilities. Could you do this in a follow-up?\n\n[1] https://review.opendev.org/c/openstack/nova/+/772779/15/nova/virt/libvirt/driver.py#7912","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"},{"author":{"_account_id":8864,"name":"Artom Lifshitz","email":"notartom@gmail.com","username":"artom"},"change_message_id":"b8ad2c3d24448924bf37111d0204fea382d0be9e","unresolved":false,"context_lines":[{"line_number":8105,"context_line":"        traits.update(self._get_video_model_traits())"},{"line_number":8106,"context_line":"        traits.update(self._get_vif_model_traits())"},{"line_number":8107,"context_line":"        traits.update(self._get_tpm_traits())"},{"line_number":8108,"context_line":"        traits.update({ot.COMPUTE_SOCKET_PCI_NUMA_AFFINITY: True})"},{"line_number":8109,"context_line":""},{"line_number":8110,"context_line":"        _, invalid_traits \u003d ot.check_traits(traits)"},{"line_number":8111,"context_line":"        for invalid_trait in invalid_traits:"}],"source_content_type":"text/x-python","patch_set":17,"id":"dd7358a3_631f78a2","line":8108,"in_reply_to":"3ae2a651_37170dae","updated":"2021-03-09 18:36:47.000000000","message":"Done","commit_id":"f97d631f0f271711bf79ad396599e0c1d909ea0b"}]}
