<s> """<STR_LIT>""" <EOL> from contextlib import contextmanager <EOL> import sys <EOL> import zlib <EOL> try : <EOL> from . import ssl_compat <EOL> except ImportError : <EOL> ssl_compat = None <EOL> _ver = sys . version_info <EOL> is_py2 = _ver [ <NUM_LIT:0> ] == <NUM_LIT:2> <EOL> is_py2_7_9_or_later = _ver [ <NUM_LIT:0> ] >= <NUM_LIT:2> and _ver [ <NUM_LIT:1> ] >= <NUM_LIT:7> and _ver [ <NUM_LIT:2> ] >= <NUM_LIT:9> <EOL> is_py3 = _ver [ <NUM_LIT:0> ] == <NUM_LIT:3> <EOL> is_py3_3 = is_py3 and _ver [ <NUM_LIT:1> ] == <NUM_LIT:3> <EOL> @ contextmanager <EOL> def ignore_missing ( ) : <EOL> try : <EOL> yield <EOL> except ( AttributeError , NotImplementedError ) : <EOL> pass <EOL> if is_py2 : <EOL> if is_py2_7_9_or_later : <EOL> import ssl <EOL> else : <EOL> ssl = ssl_compat <EOL> from urllib import urlencode <EOL> from urlparse import urlparse , urlsplit <EOL> from itertools import imap <EOL> def to_byte ( char ) : <EOL> return ord ( char ) <EOL> def decode_hex ( b ) : <EOL> return b . decode ( '<STR_LIT>' ) <EOL> def write_to_stdout ( data ) : <EOL> sys . stdout . write ( data + '<STR_LIT:\n>' ) <EOL> sys . stdout . flush ( ) <EOL> def zlib_compressobj ( level = <NUM_LIT:6> , method = zlib . DEFLATED , wbits = <NUM_LIT:15> , memlevel = <NUM_LIT:8> , <EOL> strategy = zlib . Z_DEFAULT_STRATEGY ) : <EOL> return zlib . compressobj ( level , method , wbits , memlevel , strategy ) <EOL> unicode = unicode <EOL> bytes = str <EOL> elif is_py3 : <EOL> from urllib . parse import urlencode , urlparse , urlsplit <EOL> imap = map <EOL> def to_byte ( char ) : <EOL> return char <EOL> def decode_hex ( b ) : <EOL> return bytes . fromhex ( b ) <EOL> def write_to_stdout ( data ) : <EOL> sys . stdout . buffer . write ( data + b'<STR_LIT:\n>' ) <EOL> sys . stdout . buffer . flush ( ) <EOL> zlib_compressobj = zlib . compressobj <EOL> if is_py3_3 : <EOL> ssl = ssl_compat <EOL> else : <EOL> import ssl <EOL> unicode = str <EOL> bytes = bytes </s>
