well i have run it and yes there are errors!!
no idea what IndexError means but having a look on web to see
does not like the import socket line or host = sys.argv [1]