def read_long_description(readme_file):
try:<EOL><INDENT>import pypandoc<EOL><DEDENT>except (ImportError, OSError) as exception:<EOL><INDENT>print('<STR_LIT>' % (exception,))<EOL>if sys.version_info.major == <NUM_LIT:3>:<EOL><INDENT>handle = open(readme_file, encoding='<STR_LIT:utf-8>')<EOL><DEDENT>else:<EOL><INDENT>handle = open(readme_file)<EOL><DEDENT>long_description = handle.read()<EOL>handle.close()<EOL>return long_description<EOL><DEDENT>else:<EOL><INDENT>return pypandoc.convert(readme_file, '<STR_LIT>')<EOL><DEDENT>
Read package long description from README file