Substitute proxy IP address for relay
Add base class with a workaround for overriding methods in Python 2