Make get-snapshots.py work with Python 3