removed idna encoding (not supported by jython), and fix on zlib