)]}'
{"nova/pci/devspec.py":[{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"36d631393aae63469b86cbdd167ad0b5dc13be50","unresolved":true,"context_lines":[{"line_number":255,"context_line":"        return all(conditions)"},{"line_number":256,"context_line":""},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"class WhitelistPciAddress(object):"},{"line_number":259,"context_line":"    \"\"\"Manages the address fields of the whitelist."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    This class checks the address fields of the pci.device_spec"}],"source_content_type":"text/x-python","patch_set":1,"id":"f97734d6_df040867","side":"PARENT","line":258,"updated":"2022-06-04 00:24:43.000000000","message":"the whitelist pci adress is constructed form the whitelist enteries and then those objects are comparted to the adresses costucted form the hypervior data.","commit_id":"6597143164b6b5aab92b7ba540b148d49176b254"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"62f779345ede87a07df73d3ecadad6f835c441e5","unresolved":false,"context_lines":[{"line_number":255,"context_line":"        return all(conditions)"},{"line_number":256,"context_line":""},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"class WhitelistPciAddress(object):"},{"line_number":259,"context_line":"    \"\"\"Manages the address fields of the whitelist."},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    This class checks the address fields of the pci.device_spec"}],"source_content_type":"text/x-python","patch_set":1,"id":"2d765a56_09f15505","side":"PARENT","line":258,"in_reply_to":"f97734d6_df040867","updated":"2022-06-04 07:07:33.000000000","message":"Ack","commit_id":"6597143164b6b5aab92b7ba540b148d49176b254"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"36d631393aae63469b86cbdd167ad0b5dc13be50","unresolved":true,"context_lines":[{"line_number":265,"context_line":"        | [pci]"},{"line_number":266,"context_line":"        | device_spec \u003d {\"address\":\"*:0a:00.*\","},{"line_number":267,"context_line":"        |                \"physical_network\":\"physnet1\"}"},{"line_number":268,"context_line":"        | device_spec \u003d {\"address\": {\"domain\": \".*\","},{"line_number":269,"context_line":"                                     \"bus\": \"02\","},{"line_number":270,"context_line":"                                     \"slot\": \"01\","},{"line_number":271,"context_line":"                                     \"function\": \"[0-2]\"},"}],"source_content_type":"text/x-python","patch_set":1,"id":"8bcb13c0_6d95deb7","side":"PARENT","line":268,"updated":"2022-06-04 00:24:43.000000000","message":"and this form adress is a dict","commit_id":"6597143164b6b5aab92b7ba540b148d49176b254"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"62f779345ede87a07df73d3ecadad6f835c441e5","unresolved":true,"context_lines":[{"line_number":265,"context_line":"        | [pci]"},{"line_number":266,"context_line":"        | device_spec \u003d {\"address\":\"*:0a:00.*\","},{"line_number":267,"context_line":"        |                \"physical_network\":\"physnet1\"}"},{"line_number":268,"context_line":"        | device_spec \u003d {\"address\": {\"domain\": \".*\","},{"line_number":269,"context_line":"                                     \"bus\": \"02\","},{"line_number":270,"context_line":"                                     \"slot\": \"01\","},{"line_number":271,"context_line":"                                     \"function\": \"[0-2]\"},"}],"source_content_type":"text/x-python","patch_set":1,"id":"aacaed73_d9adab24","side":"PARENT","line":268,"in_reply_to":"8bcb13c0_6d95deb7","updated":"2022-06-04 07:07:33.000000000","message":"Nope, that is handle by PciAddressRegexSpec not PhysicalPciAddress","commit_id":"6597143164b6b5aab92b7ba540b148d49176b254"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"c9b2b4059623be748c0ea57a507d17653e9b8e38","unresolved":true,"context_lines":[{"line_number":152,"context_line":"            # single string"},{"line_number":153,"context_line":"            # TODO(gibi): When this can be a dict? We have unit tests"},{"line_number":154,"context_line":"            # explicitly calling it with dict, but removing the dict support"},{"line_number":155,"context_line":"            # does not cause any functional test to fail."},{"line_number":156,"context_line":"            if isinstance(pci_addr, dict):"},{"line_number":157,"context_line":"                domain \u003d pci_addr[\u0027domain\u0027]"},{"line_number":158,"context_line":"                bus \u003d pci_addr[\u0027bus\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"477dd511_b0f27978","line":155,"updated":"2022-06-04 00:13:48.000000000","message":"its a dict when we parse the adress in dict form from the pci whitelist\nthe whitelist is json and we support specifying the adress\nas a dict \nhttps://github.com/openstack/nova/blob/d86916360858daa06164ebc0d012b78d19ae6497/nova/pci/devspec.py#L205\n\nso when we load a whitelisht that has the adress in dict form with json utils then it will deserialise it into a python dict.","commit_id":"8dfe569dc7ba8eea90f09c6b08a7ca0f8420624d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"391890c5f6ed396735ddc2bc8e8b4422874e2af2","unresolved":true,"context_lines":[{"line_number":152,"context_line":"            # single string"},{"line_number":153,"context_line":"            # TODO(gibi): When this can be a dict? We have unit tests"},{"line_number":154,"context_line":"            # explicitly calling it with dict, but removing the dict support"},{"line_number":155,"context_line":"            # does not cause any functional test to fail."},{"line_number":156,"context_line":"            if isinstance(pci_addr, dict):"},{"line_number":157,"context_line":"                domain \u003d pci_addr[\u0027domain\u0027]"},{"line_number":158,"context_line":"                bus \u003d pci_addr[\u0027bus\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"882b5402_dd5f2142","line":155,"in_reply_to":"4297de0c_b155027c","updated":"2022-06-04 07:05:38.000000000","message":"Looking at it again I believe it is never called with dict.","commit_id":"8dfe569dc7ba8eea90f09c6b08a7ca0f8420624d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"05f4df1bcc247c451d1cc603fdd6c9ee4121bd35","unresolved":true,"context_lines":[{"line_number":152,"context_line":"            # single string"},{"line_number":153,"context_line":"            # TODO(gibi): When this can be a dict? We have unit tests"},{"line_number":154,"context_line":"            # explicitly calling it with dict, but removing the dict support"},{"line_number":155,"context_line":"            # does not cause any functional test to fail."},{"line_number":156,"context_line":"            if isinstance(pci_addr, dict):"},{"line_number":157,"context_line":"                domain \u003d pci_addr[\u0027domain\u0027]"},{"line_number":158,"context_line":"                bus \u003d pci_addr[\u0027bus\u0027]"}],"source_content_type":"text/x-python","patch_set":1,"id":"4297de0c_b155027c","line":155,"in_reply_to":"477dd511_b0f27978","updated":"2022-06-04 06:05:51.000000000","message":"\u003e its a dict when we parse the adress in dict form from the pci whitelist\n\u003e the whitelist is json and we support specifying the adress\n\u003e as a dict \n\u003e https://github.com/openstack/nova/blob/d86916360858daa06164ebc0d012b78d19ae6497/nova/pci/devspec.py#L205\n\nThat needs to be handled by PciAddressRegexSpec as it has a regexp. Also in general I think dicts are handled by PciAddressRegexSpec blindly even if they don\u0027t have a regex:\n\nhttps://github.com/openstack/nova/blob/d86916360858daa06164ebc0d012b78d19ae6497/nova/pci/devspec.py#L234-L235\n\nBut this code only runs if not self.is_physical_function. This is tricky as we only pass True for that to WhitelistPciAddress if the entry in the dev_spec config has an devname field that is resolved to a device via sysfs and that device is a VF capable PF. Othervise self.is_physical_function is False at this point, but later we will recalculate that with _check_physical_function() in WhitelistPciAddress:\n\nhttps://github.com/openstack/nova/blob/d86916360858daa06164ebc0d012b78d19ae6497/nova/pci/devspec.py#L238 \n\n\u003e \n\u003e so when we load a whitelisht that has the adress in dict form with json utils then it will deserialise it into a python dict.","commit_id":"8dfe569dc7ba8eea90f09c6b08a7ca0f8420624d"},{"author":{"_account_id":11604,"name":"sean mooney","email":"smooney@redhat.com","username":"sean-k-mooney"},"change_message_id":"36d631393aae63469b86cbdd167ad0b5dc13be50","unresolved":true,"context_lines":[{"line_number":270,"context_line":"    Example configs:"},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"        | [pci]"},{"line_number":273,"context_line":"        | device_spec \u003d {\"address\":\"*:0a:00.*\","},{"line_number":274,"context_line":"        |                \"physical_network\":\"physnet1\"}"},{"line_number":275,"context_line":"        | device_spec \u003d {\"address\": {\"domain\": \".*\","},{"line_number":276,"context_line":"                                     \"bus\": \"02\","}],"source_content_type":"text/x-python","patch_set":1,"id":"0b782e4a_2ed024f2","line":273,"updated":"2022-06-04 00:24:43.000000000","message":"basically when we parse tthis form its a string","commit_id":"8dfe569dc7ba8eea90f09c6b08a7ca0f8420624d"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"62f779345ede87a07df73d3ecadad6f835c441e5","unresolved":true,"context_lines":[{"line_number":270,"context_line":"    Example configs:"},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"        | [pci]"},{"line_number":273,"context_line":"        | device_spec \u003d {\"address\":\"*:0a:00.*\","},{"line_number":274,"context_line":"        |                \"physical_network\":\"physnet1\"}"},{"line_number":275,"context_line":"        | device_spec \u003d {\"address\": {\"domain\": \".*\","},{"line_number":276,"context_line":"                                     \"bus\": \"02\","}],"source_content_type":"text/x-python","patch_set":1,"id":"1c498b2d_2dc0c9a8","line":273,"in_reply_to":"0b782e4a_2ed024f2","updated":"2022-06-04 07:07:33.000000000","message":"Nope, that is handle by PciAddressGlobSpec not PhysicalPciAddress","commit_id":"8dfe569dc7ba8eea90f09c6b08a7ca0f8420624d"}]}
