Update Gate.py