input.py
line 28
if int(value) in range(65536):
should be
if int(value) in range(65535):
https://networkengineering.stackexchange.com/questions/42011/network-port-number-why-16-bit-has-65535-not-65536