How do I parse an item from the list in python?
I need to get a HOSTNAME from:
{'Key': 'Name', 'Value': 'HOSTNAME'}
tag = [{'Key': 'Backup Initiator Rule', 'Value': 'Daily-6d-retention'},
{'Key': 'delete_On', 'Value': '2019-08-31'},
{'Key': 'Backup_Type', 'Value': 'Demo'},
{'Key': 'Name', 'Value': 'HOSTNAME'},
{'Key': 'Disaster_Recovery', 'Value': 'Full'}]
tag["Tags"]then scan the list for a dictionary where Key == Name. Useast.literal_evalon it first since it seems to be a string'StartTime': datetime.datetime(2019, 8, 28, 13, 56, 8, 269000, tzinfo=tzutc()),