formatted the the code in host_collection.py