由于 Google 使用其 apiclient 模块的命名约定,我收到以下错误:
$ sudo ./setup.py install
Traceback (most recent call last):
File "./setup.py", line 37, in <module>
scripts = [ 'bin/gsync' ],
File "/usr/lib/python2.7/distutils/core.py", line 112, in setup
_setup_distribution = dist = klass(attrs)
File "/usr/lib/python2.7/dist-packages/setuptools/dist.py", line 225, in __init__
_Distribution.__init__(self,attrs)
File "/usr/lib/python2.7/distutils/dist.py", line 259, in __init__
getattr(self.metadata, "set_" + key)(val)
File "/usr/lib/python2.7/distutils/dist.py", line 1220, in set_requires
distutils.versionpredicate.VersionPredicate(v)
File "/usr/lib/python2.7/distutils/versionpredicate.py", line 113, in __init__
raise ValueError("expected parenthesized list: %r" % paren)
ValueError: expected parenthesized list: '-api-python-client'
我如何指示 setuptools 该库不应视为版本谓词,基本上忽略连字符并将所有内容都包含为库名称?