def delete_contact_group(gd_client, contact_group_url): # Retrieving the contact group is required in order to get the Etag. group = gd_client.GetGroup(contact_group_url) try: gd_client.Delete(group) except gdata.client.RequestError, e: if e.status == 412: # Etags mismatch: handle the exception. pass