Python setuptools 0.7中项目名称中的连字符?
我有一个很好的小脚本库,名为,它使创建构建项目变得非常容易 然后,最新的构建声明依赖于Python setuptools 0.7中项目名称中的连字符?,python,setuptools,buildout,Python,Setuptools,Buildout,我有一个很好的小脚本库,名为,它使创建构建项目变得非常容易 然后,最新的构建声明依赖于setuptools>=0.7,因此我必须在这里升级我的setuptools,以符合要求 升级后,setuptools现在与我的构建一起失败。虽然以下内容在0.7之前可以工作,但现在它失败了: from setuptools import setup, find_packages setup( name = "tornado-chat-example", version = "0.0.1-SN
setuptools>=0.7
,因此我必须在这里升级我的setuptools
,以符合要求
升级后,setuptools
现在与我的构建一起失败。虽然以下内容在0.7之前可以工作,但现在它失败了:
from setuptools import setup, find_packages
setup(
name = "tornado-chat-example",
version = "0.0.1-SNAPSHOT",
packages = find_packages('src'),
package_dir = { '': 'src'},
install_requires = [ 'setuptools', ],
)
我的src
目录如下所示:
src
├── tornadochatexample
└── tornado_chat_example.egg-info
下面是我得到的错误:
Develop: '/home/naftuli/tornado-chat-example/.'
Installing python_section.
Couldn't find index page for 'tornadochatexample' (maybe misspelled?)
Getting distribution for 'tornadochatexample'.
Couldn't find index page for 'tornadochatexample' (maybe misspelled?)
While:
Installing python_section.
Getting distribution for 'tornadochatexample'.
Error: Couldn't find a distribution for 'tornadochatexample'.
正如我前面提到的,这个示例似乎在
setuptools
0.6上运行,但现在在最新的setuptools
0.7中失败。我怎样才能让它工作?我想将我的项目命名为tornado chat example
,但有一个tornado chat example
包。我怎样才能做到这一点呢?这里不太清楚,也许你应该直接联系setuptools
人员?这也可能是一个bug。是否有可能0.7正在强制执行?“包和模块名称模块应该有短的、全小写的名称。如果可以提高可读性,可以在模块名称中使用下划线。Python包也应该有短的、全小写的名称,尽管不鼓励使用下划线。”我不知道,但是我上面提到的实际包名是example
。PyPI名称是tornado chat example。以前,在内部,该名称将更改为使用下划线。该隐式转换现在似乎失败了。请参阅和。尽管如此,如果这项技术现在不再有效,那么在某个地方还是有一个bug。