)]}'
{"nova/virt/libvirt/driver.py":[{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e3542dd5a51c4bd8b926f60d8c23862dfac3ffd3","unresolved":false,"context_lines":[{"line_number":4750,"context_line":"        # cell and don\u0027t try to count sockets/cores/threads"},{"line_number":4751,"context_line":"        if caps.host.topology is not None:"},{"line_number":4752,"context_line":"            totals \u003d self._get_cpu_totals(caps.host.topology)"},{"line_number":4753,"context_line":"            cpu_info[\u0027totals\u0027] \u003d totals"},{"line_number":4754,"context_line":"        else:"},{"line_number":4755,"context_line":"            totals \u003d {\u0027cells\u0027: 1}"},{"line_number":4756,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_49165856","line":4753,"updated":"2015-09-16 09:00:38.000000000","message":"I don\u0027t see any compelling reason to include this. I understand why the current nodes/sockets/cores/thread data is sub-optimal due to it being an inexact representation of asymmetric topologies. This is mildly improves on it by reporting more data, but you are still reporting a subset of the full topology information. We already report the host NUMA topology against the compute_node table. If that is still not detailed enough, we should expand the NUMA topology object to include the required detail, rather than continuing to extend this cpu info with new adhoc fields. \n\nEssentially the \u0027cpu_info\u0027 topology is considered to be deprecated in favour of the numa_topology info, and as such we don\u0027t want to continue extending cpu_info topology\n\nIf the problem is that the NUMA topology info is not exposed to the user via the API, then we should solve that at the API level, to allow it to be reported.","commit_id":"f3a5798c7aae371e638ed40e6136c9d95e76cff7"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e3542dd5a51c4bd8b926f60d8c23862dfac3ffd3","unresolved":false,"context_lines":[{"line_number":4755,"context_line":"            totals \u003d {\u0027cells\u0027: 1}"},{"line_number":4756,"context_line":""},{"line_number":4757,"context_line":"        topology \u003d dict()"},{"line_number":4758,"context_line":"        topology[\u0027cells\u0027] \u003d totals[\u0027cells\u0027]"},{"line_number":4759,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4760,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4761,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_096aa01a","line":4758,"updated":"2015-09-16 09:00:38.000000000","message":"As a minimum fix, we should just be using the caps.host.cpu.nodes value for \u0027cells\u0027 here, so we are consistent with the data wrt reporting for sockets/cores/threads. I\u0027d ack a patch which merely added the \u0027cells\u0027 field based on caps.host.cpu.nodes.","commit_id":"f3a5798c7aae371e638ed40e6136c9d95e76cff7"},{"author":{"_account_id":5280,"name":"Nicolas Simonds","email":"nic@metacloud.com","username":"nicolas.simonds"},"change_message_id":"59cdf6fd5bac3a1b50320e4c2b8a0de7558c34d9","unresolved":false,"context_lines":[{"line_number":4755,"context_line":"            totals \u003d {\u0027cells\u0027: 1}"},{"line_number":4756,"context_line":""},{"line_number":4757,"context_line":"        topology \u003d dict()"},{"line_number":4758,"context_line":"        topology[\u0027cells\u0027] \u003d totals[\u0027cells\u0027]"},{"line_number":4759,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4760,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4761,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_464b812a","line":4758,"in_reply_to":"ba15a1d1_096aa01a","updated":"2015-09-16 22:03:42.000000000","message":"As you wish.","commit_id":"f3a5798c7aae371e638ed40e6136c9d95e76cff7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"10597db32746b84260aa99e06ad83d9c8d702f25","unresolved":false,"context_lines":[{"line_number":4755,"context_line":"            totals \u003d {\u0027cells\u0027: 1}"},{"line_number":4756,"context_line":""},{"line_number":4757,"context_line":"        topology \u003d dict()"},{"line_number":4758,"context_line":"        topology[\u0027cells\u0027] \u003d totals[\u0027cells\u0027]"},{"line_number":4759,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4760,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4761,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba15a1d1_cedd87e1","line":4758,"in_reply_to":"ba15a1d1_096aa01a","updated":"2015-09-16 11:03:53.000000000","message":"agreed - in addition, this can be seen from the API but it\u0027s a json blob in the response so it really makes no sense to say that this requires some kind of API versioning changes.","commit_id":"f3a5798c7aae371e638ed40e6136c9d95e76cff7"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"d03f37cb73ee4767dfdb0389530e87d6b37a502d","unresolved":false,"context_lines":[{"line_number":4717,"context_line":"        cpu_info[\u0027vendor\u0027] \u003d caps.host.cpu.vendor"},{"line_number":4718,"context_line":""},{"line_number":4719,"context_line":"        topology \u003d dict()"},{"line_number":4720,"context_line":"        topology[\u0027cells\u0027] \u003d len(getattr(caps.host.topology, \u0027cells\u0027, [1]))"},{"line_number":4721,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4722,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4723,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_df40a136","line":4720,"updated":"2015-09-17 09:46:46.000000000","message":"Should we guard against topology being None here as well? Probably unlikely to happen with any version of libvirt we care about but since it can be None in theory, might be a nice defensive style?","commit_id":"9aec873f75389c676af1b87f6455bf95a6813290"},{"author":{"_account_id":5511,"name":"Nikola Dipanov","email":"ndipanov@redhat.com","username":"ndipanov"},"change_message_id":"2ad48bee526b3e84b8eb81efaae9763e13fb7e1a","unresolved":false,"context_lines":[{"line_number":4717,"context_line":"        cpu_info[\u0027vendor\u0027] \u003d caps.host.cpu.vendor"},{"line_number":4718,"context_line":""},{"line_number":4719,"context_line":"        topology \u003d dict()"},{"line_number":4720,"context_line":"        topology[\u0027cells\u0027] \u003d len(getattr(caps.host.topology, \u0027cells\u0027, [1]))"},{"line_number":4721,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4722,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4723,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_f328fc87","line":4720,"in_reply_to":"ba15a1d1_c67c43ee","updated":"2015-09-18 16:00:59.000000000","message":"This is a guard against cells being None, this will still blow up with \u0027NoneType has no attribute cells\u0027 if topology is None me thinks.","commit_id":"9aec873f75389c676af1b87f6455bf95a6813290"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"d19b183739be2c98ed489d4a4cba0c0ccda391b8","unresolved":false,"context_lines":[{"line_number":4717,"context_line":"        cpu_info[\u0027vendor\u0027] \u003d caps.host.cpu.vendor"},{"line_number":4718,"context_line":""},{"line_number":4719,"context_line":"        topology \u003d dict()"},{"line_number":4720,"context_line":"        topology[\u0027cells\u0027] \u003d len(getattr(caps.host.topology, \u0027cells\u0027, [1]))"},{"line_number":4721,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4722,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4723,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_1f3e19da","line":4720,"in_reply_to":"ba15a1d1_df40a136","updated":"2015-09-17 10:04:53.000000000","message":"It is actually possible for topology to be None, eg on Arm architecture IIRC it will be, so yeah, we should guard against it.","commit_id":"9aec873f75389c676af1b87f6455bf95a6813290"},{"author":{"_account_id":5280,"name":"Nicolas Simonds","email":"nic@metacloud.com","username":"nicolas.simonds"},"change_message_id":"6004b0a9c9df0d1e4c4cdce9e5eb17a8f02f964e","unresolved":false,"context_lines":[{"line_number":4717,"context_line":"        cpu_info[\u0027vendor\u0027] \u003d caps.host.cpu.vendor"},{"line_number":4718,"context_line":""},{"line_number":4719,"context_line":"        topology \u003d dict()"},{"line_number":4720,"context_line":"        topology[\u0027cells\u0027] \u003d len(getattr(caps.host.topology, \u0027cells\u0027, [1]))"},{"line_number":4721,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4722,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4723,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_c67c43ee","line":4720,"in_reply_to":"ba15a1d1_df40a136","updated":"2015-09-17 16:45:40.000000000","message":"This is a guard against topology being a NoneType; otherwise I\u0027d just say \"len(caps.host.topology.cells)\".\n\nThe FakeLibvirt driver doesn\u0027t always populate topology either, which is how I found out I needed to guard this at all.","commit_id":"9aec873f75389c676af1b87f6455bf95a6813290"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"e9934963fb623afdd6451832eeaf5b0b4010ac2d","unresolved":false,"context_lines":[{"line_number":4717,"context_line":"        cpu_info[\u0027vendor\u0027] \u003d caps.host.cpu.vendor"},{"line_number":4718,"context_line":""},{"line_number":4719,"context_line":"        topology \u003d dict()"},{"line_number":4720,"context_line":"        topology[\u0027cells\u0027] \u003d len(getattr(caps.host.topology, \u0027cells\u0027, [1]))"},{"line_number":4721,"context_line":"        topology[\u0027sockets\u0027] \u003d caps.host.cpu.sockets"},{"line_number":4722,"context_line":"        topology[\u0027cores\u0027] \u003d caps.host.cpu.cores"},{"line_number":4723,"context_line":"        topology[\u0027threads\u0027] \u003d caps.host.cpu.threads"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba15a1d1_b3b28404","line":4720,"in_reply_to":"ba15a1d1_f328fc87","updated":"2015-09-18 16:08:25.000000000","message":"That\u0027s what i thought too, but it actually seems getattr handles this\n\n\u003e\u003e\u003e getattr(None, \"cells\", [])\n[]","commit_id":"9aec873f75389c676af1b87f6455bf95a6813290"}]}
