为了账号安全,请及时绑定邮箱和手机立即绑定

我怎样才能让 pipenv 安装包子依赖项

我怎样才能让 pipenv 安装包子依赖项

慕桂英3389331 2023-06-06 17:37:54
我有一个包,它有一个依赖项 B (sg_wrapper),它本身有一个依赖项 C (shotgun_api3)。使用 pipenv 安装时,我可以访问 B(sg_wrapper),但 B 本身无法导入 C。这是我的文件[[source]]name = "pypi"url = "https://pypi.org/simple"verify_ssl = true[dev-packages][packages]edl = "*"timecode="*"sg_wrapper = {git = "git+https://gitlab.com/kickstartent/sg_wrapper.git", editable=true}[requires]python_version = "3.7"这是包 B setup.pyimport setuptoolswith open("README.md", "r") as fh:    long_description = fh.read()setuptools.setup(    name="Shotgun wrapper",    version="0.0.1",    author="",    author_email="",    description="shotgun wrapper",    long_description=long_description,    long_description_content_type="text/markdown",    url="hidden",    packages=setuptools.find_packages(),    classifiers=[        "Programming Language :: Python :: 3",        "License :: OSI Approved :: MIT License",        "Operating System :: OS Independent",    ],    python_requires='>=3.6',    install_requires=[        'package_name @ git+https://github.com/shotgunsoftware/python-api.git'    ])
查看完整描述

1 回答

?
沧海一幻觉

TA贡献1824条经验 获得超5个赞

您需要键入真实的包名称。

install_requires=[
        'package_name @ git+https://github.com/shotgunsoftware/python-api.git'
    ]

但是你输入的是 package_name 而不是!!!😆🤗

例如:

install_requires=[
    pycocotools @ git+https://github.com/cocodataset/cocoapi.git#subdirectory=PythonAPI
    ]


查看完整回答
反对 回复 2023-06-06
  • 1 回答
  • 0 关注
  • 136 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信