prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Rendering on PyPI is broken
  **Description:**
  Rendering of the README on PyPI is broken because it expects RST by default and Markdown is being uploaded.
  
  **Steps to reproduce the issue:**
  
  1. Go to https://pypi.org/project/aws-sam-translator/
  
  **Observed result:**
  
  Raw markdown
  
  **Expected result:**
  
  Links and images working
  
  
  </issue>
  <code>
  [start of setup.py]
  1 # -*- coding: utf-8 -*-
  2 #
  3 # setup.py
  4 #
  5 # Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
  6 #
  7 # Licensed under the Apache License, Version 2.0 (the "License");
  8 # you may not use this file except in compliance with the License.
  9 # You may obtain a copy of the License at
  10 #
  11 #     http://www.apache.org/licenses/LICENSE-2.0
  12 #
  13 # Unless required by applicable law or agreed to in writing, software
  14 # distributed under the License is distributed on an "AS IS" BASIS,
  15 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  16 # See the License for the specific language governing permissions and
  17 # limitations under the License.
  18 #
  19 
  20 """
  21 AWS SAM Serverless Application Model
  22 """
  23 import io
  24 import os
  25 import re
  26 
  27 from setuptools import setup, find_packages
  28 
  29 
  30 def read(*filenames, **kwargs):
  31     encoding = kwargs.get('encoding', 'utf-8')
  32     sep = kwargs.get('sep', os.linesep)
  33     buf = []
  34     for filename in filenames:
  35         with io.open(filename, encoding=encoding) as f:
  36             buf.append(f.read())
  37     return sep.join(buf)
  38 
  39 
  40 def read_version():
  41     content = read(os.path.join(
  42         os.path.dirname(__file__), 'samtranslator', '__init__.py'))
  43     return re.search(r"__version__ = '([^']+)'", content).group(1)
  44 
  45 
  46 def read_requirements(req='base.txt'):
  47     content = read(os.path.join('requirements', req))
  48     return [line for line in content.split(os.linesep)
  49             if not line.strip().startswith('#')]
  50 
  51 
  52 setup(
  53     name='aws-sam-translator',
  54     version=read_version(),
  55     description='AWS SAM Translator is a library that transform SAM templates into AWS CloudFormation templates',
  56     long_description=read('README.md'),
  57     author='Amazon Web Services',
  58     author_email='aws-sam-developers@amazon.com',
  59     url='https://github.com/awslabs/serverless-application-model',
  60     license='Apache License 2.0',
  61     # Exclude all but the code folders
  62     packages=find_packages(exclude=('tests', 'docs', 'examples', 'versions')),
  63     install_requires=read_requirements('base.txt'),
  64     include_package_data=True,
  65     extras_require={
  66         'dev': read_requirements('dev.txt')
  67     },
  68     keywords="AWS SAM Serverless Application Model",
  69     classifiers=[
  70         'Development Status :: 4 - Beta',
  71         'Environment :: Console',
  72         'Environment :: Other Environment',
  73         'Intended Audience :: Developers',
  74         'Intended Audience :: Information Technology',
  75         'License :: OSI Approved :: Apache Software License',
  76         'Operating System :: OS Independent',
  77         'Programming Language :: Python',
  78         'Programming Language :: Python :: 2.7',
  79         'Topic :: Internet',
  80         'Topic :: Software Development :: Build Tools',
  81         'Topic :: Utilities'
  82     ]
  83 )
  84
  [end of setup.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/setup.py b/setup.py
  --- a/setup.py
  +++ b/setup.py
  @@ -54,6 +54,7 @@
       version=read_version(),
       description='AWS SAM Translator is a library that transform SAM templates into AWS CloudFormation templates',
       long_description=read('README.md'),
  +    long_description_content_type='text/markdown',
       author='Amazon Web Services',
       author_email='aws-sam-developers@amazon.com',
       url='https://github.com/awslabs/serverless-application-model',
  
verification_info: {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -54,6 +54,7 @@\n     version=read_version(),\n     description='AWS SAM Translator is a library that transform SAM templates into AWS CloudFormation templates',\n     long_description=read('README.md'),\n+    long_description_content_type='text/markdown',\n     author='Amazon Web Services',\n     author_email='aws-sam-developers@amazon.com',\n     url='https://github.com/awslabs/serverless-application-model',\n", "issue": "Rendering on PyPI is broken\n**Description:**\r\nRendering of the README on PyPI is broken because it expects RST by default and Markdown is being uploaded.\r\n\r\n**Steps to reproduce the issue:**\r\n\r\n1. Go to https://pypi.org/project/aws-sam-translator/\r\n\r\n**Observed result:**\r\n\r\nRaw markdown\r\n\r\n**Expected result:**\r\n\r\nLinks and images working\r\n\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\n#\n# setup.py\n#\n# Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n#\n\n\"\"\"\nAWS SAM Serverless Application Model\n\"\"\"\nimport io\nimport os\nimport re\n\nfrom setuptools import setup, find_packages\n\n\ndef read(*filenames, **kwargs):\n    encoding = kwargs.get('encoding', 'utf-8')\n    sep = kwargs.get('sep', os.linesep)\n    buf = []\n    for filename in filenames:\n        with io.open(filename, encoding=encoding) as f:\n            buf.append(f.read())\n    return sep.join(buf)\n\n\ndef read_version():\n    content = read(os.path.join(\n        os.path.dirname(__file__), 'samtranslator', '__init__.py'))\n    return re.search(r\"__version__ = '([^']+)'\", content).group(1)\n\n\ndef read_requirements(req='base.txt'):\n    content = read(os.path.join('requirements', req))\n    return [line for line in content.split(os.linesep)\n            if not line.strip().startswith('#')]\n\n\nsetup(\n    name='aws-sam-translator',\n    version=read_version(),\n    description='AWS SAM Translator is a library that transform SAM templates into AWS CloudFormation templates',\n    long_description=read('README.md'),\n    author='Amazon Web Services',\n    author_email='aws-sam-developers@amazon.com',\n    url='https://github.com/awslabs/serverless-application-model',\n    license='Apache License 2.0',\n    # Exclude all but the code folders\n    packages=find_packages(exclude=('tests', 'docs', 'examples', 'versions')),\n    install_requires=read_requirements('base.txt'),\n    include_package_data=True,\n    extras_require={\n        'dev': read_requirements('dev.txt')\n    },\n    keywords=\"AWS SAM Serverless Application Model\",\n    classifiers=[\n        'Development Status :: 4 - Beta',\n        'Environment :: Console',\n        'Environment :: Other Environment',\n        'Intended Audience :: Developers',\n        'Intended Audience :: Information Technology',\n        'License :: OSI Approved :: Apache Software License',\n        'Operating System :: OS Independent',\n        'Programming Language :: Python',\n        'Programming Language :: Python :: 2.7',\n        'Topic :: Internet',\n        'Topic :: Software Development :: Build Tools',\n        'Topic :: Utilities'\n    ]\n)\n", "path": "setup.py"}]}