Search code examples
pythonmarkdownsetuptoolsrestructuredtextpypi

Why is setup.py failing when I try to register with pypi?


I'm having a bit of trouble getting my latest project registered with PyPI, and I'm hoping one of you guys can tell me what I'm doing wrong.

My directory is structured as follows:

Scrappy/
|-- README.md
|-- setup.py
|-- manifest.in
|-- scrappy
|   |-- __init__.py
|   |-- core.py
|   |-- formatters.py
|   |-- docopty.py
|   |-- gui.py
|   |-- scrappy.py
|   |-- scrappy.conf

My manifest.in file is structured as follows:

include README.md
include scrappy/scrappy.conf

and my setup.py file is structured as follows:

from setuptools import setup

setup(
    name='Scrappy',
    version='0.2.1 alpha',
    author='Blz McBlz',
    author_email='[email protected]',
    packages=['scrappy'],
    include_package_data=True,
    install_requires=['guessit', 'tvdb_api', 'ez_setup', 'titlecase', 'hachoir-metadata'],
    url='https://github.com/louist87/scrappy',
    license='GPL 3.0',
    description='Rename video files based on information scraped from thetvdb.com',
    keywords=["TVDB", "thetvdb", "rename", "broadcatching", "media"],
    long_description=open('README.md').read()
)

A full traceback can be found here

I tried loading README.md in a python shell via lines = open('README.md').read(). No error was raised and the text was indeed in the lines variable as expected.

EDIT: here is the README.md file in question.


Solution

  • The issue is that setuptools requires reStructuredText and not markdown syntax in the long_description field.