stop flask duplicating a loaded variable
问题 I'm building a basic cloud infrastructure management site and have a problem with the page that lists virtual machines. The flask app pulls a list that is generated via various cloud platform's APIs, and is in the below format: vm_list = { 'vmid': [], 'name': [], 'state': [], 'platform': [] } the list is populated by looping through the API output and appending each value like so: def zip_list(): ... for node in driver.list_nodes(): vm_list["vmid"].append(node.uuid) vm_list["name"].append