我有一个名为pyuvm
的包。源文件在pyuvm/pyuvm
中
当我构建它并将其发送到pypi.org
时,我没有看到任何错误,当我安装它时,我也没有看到任何错误,但是在site-packages
中没有pyuvm
目录,而是有一个pyuvm-2.0a3.dist-info
文件。
我有这个setup.cfg
[metadata]
name = pyuvm
version = 2.0a3
author = Ray Salemi
author_email = ray@raysalemi.com
description = Python implementation of the Universal Verification Methodology (UVM) using cocotb
long_description = file: README.md
long_description_content_type = text/markdown
url = https://github.com/pyuvm/pyuvm
project_urls=
Bug Tracker=https://github.com/pyuvm/pyuvm/issues
classifiers =
Programming Language :: Python :: 3
License :: OSI Approved :: Apache Software License
Operating System :: OS Independent
[options]
packages = find:
python_requires = >=3.6
install_requires =
cocotb >= 1.5.2
[options.packages.find]
where = pyuvm
知道我做错了什么吗?
发布于 2021-08-13 13:47:43
我通过切换回setup.py
使其正常工作
import setuptools
with open("README.md", "r", encoding="utf-8") as fh:
long_description = fh.read()
setuptools.setup(
name="pyuvm",
version="2.0a8",
author="Ray Salemi",
author_email="ray@raysalemi.com",
description="A Python implementation of the UVM using cocotb",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/pyuvm/pyuvm",
project_urls={
"Bug Tracker": "https://github.com/pyuvm/pyuvm/issues",
},
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Topic :: Scientific/Engineering :: Electronic Design Automation (EDA)",
],
packages=setuptools.find_packages(),
python_requires=">=3.6",
install_requires="cocotb>=1.5.2",
)
关键是从安装程序中完全删除package_dir
参数,并将find_packages
设置为没有参数。
https://stackoverflow.com/questions/68777841
复制