gpt4 book ai didi

python - 当我尝试注册 pypi 时,为什么 setup.py 失败?

转载 作者:太空宇宙 更新时间:2023-11-03 19:07:51 24 4
gpt4 key购买 nike

我在使用 PyPI 注册我的最新项目时遇到了一些麻烦,我希望你们中的一个人可以告诉我我做错了什么。

我的目录结构如下:

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

我的 manifest.in 文件的结构如下:

include README.md
include scrappy/scrappy.conf

我的 setup.py 文件的结构如下:

from setuptools import setup

setup(
name='Scrappy',
version='0.2.1 alpha',
author='Blz McBlz',
author_email='xxxx@xxxx.com',
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()
)

可以找到完整的回溯 here

我尝试通过 lines = open('README.md').read() 在 python shell 中加载 README.md。没有引发错误,并且文本确实按预期位于 lines 变量中。

编辑: here是有问题的 README.md 文件。

最佳答案

问题是 setuptools 在 long_description 字段中需要 reStructuredText 而不是 markdown 语法。

关于python - 当我尝试注册 pypi 时,为什么 setup.py 失败?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14132413/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com