错误的后端子过程试图调用get_requires_for_build_sdist

发布于 2025-01-25 18:24:03 字数 1672 浏览 1 评论 0原文

我使用 上传python Package github上的工作流程上传存储在 to pypi

如您在上面的链接上所见,我遵循 packaging.python.org ,要更具体地我使用


无论如何,在

Run python -m build
      python -m build
      shell: /usr/bin/bash -e {0}
      env:
        pythonLocation: /opt/hostedtoolcache/Python/3.10.4/x64
        LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.10.4/x64/lib
    running egg_info
    creating src/classevivaAPI.egg-info
    writing src/classevivaAPI.egg-info/PKG-INFO
    writing dependency_links to src/classevivaAPI.egg-info/dependency_links.txt
    writing top-level names to src/classevivaAPI.egg-info/top_level.txt
    writing manifest file 'src/classevivaAPI.egg-info/SOURCES.txt'
    error: package directory 'src/classevivaAPI' does not exist
    * Creating venv isolated environment...
    * Installing packages in isolated environment... (selenium>=4.1.3, setuptools>=42)
    * Getting dependencies for sdist...
 


ERROR Backend subproccess exited when trying to invoke get_requires_for_build_sdist
Error: Process completed with exit code 1.

特别是我想知道以下行是什么意思:

错误后端子过程试图调用get_requires_for_build_sdist


您是否遇到过同样的问题?您知道如何解决并上传我的包裹吗?先感谢您。

I used the Upload Python Package workflow on GitHub to upload the module stored in the repository to PyPI.

As you can see at the link above, I followed the tutorial given by packaging.python.org, to be more specific I used setup.py instead of setup.cfg.


Anyway an error occurred during the last deploy, which gave me the following error:

Run python -m build
      python -m build
      shell: /usr/bin/bash -e {0}
      env:
        pythonLocation: /opt/hostedtoolcache/Python/3.10.4/x64
        LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.10.4/x64/lib
    running egg_info
    creating src/classevivaAPI.egg-info
    writing src/classevivaAPI.egg-info/PKG-INFO
    writing dependency_links to src/classevivaAPI.egg-info/dependency_links.txt
    writing top-level names to src/classevivaAPI.egg-info/top_level.txt
    writing manifest file 'src/classevivaAPI.egg-info/SOURCES.txt'
    error: package directory 'src/classevivaAPI' does not exist
    * Creating venv isolated environment...
    * Installing packages in isolated environment... (selenium>=4.1.3, setuptools>=42)
    * Getting dependencies for sdist...
 


ERROR Backend subproccess exited when trying to invoke get_requires_for_build_sdist
Error: Process completed with exit code 1.

In particular I was wondering what does the following line mean:

ERROR Backend subproccess exited when trying to invoke get_requires_for_build_sdist


Have you ever had the same problem? Do you know how to solve it and upload my package? Thank you in advance.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

好听的两个字的网名 2025-02-01 18:24:03

我只是遇到了这个问题,并通过在pyproject.toml中使用“ setuptools”解决了问题
和setup.py文件,而不是“孵化”。

I just had that problem and fixed it by using "setuptools" in the pyproject.toml
and setup.py files, instead of "hatchling".

没︽人懂的悲伤 2025-02-01 18:24:03

例如,将包装包装在文件夹中,例如SRC。
因此,与其仅具有my_package,还应在项目目录中具有src \ my_package之类的东西。

wrap your package in a folder, for instance, src.
so instead of having only my_package, you should have something like src\my_package in your project directory.

节枝 2025-02-01 18:24:03

我认为问题在于

package_dir={'':"src"},
packages=find_packages("src")

我也遇到了类似的问题,但是能够通过纠正Package_dir来解决它。

以下是我的回购,我也做了同样的事情。

I think the problem is with

package_dir={'':"src"},
packages=find_packages("src")

I also faced similar issues, but was able to fix it by correcting the package_dir.

Below is my repo, where I have done the same.
Hello World Python Package

娇女薄笑 2025-02-01 18:24:03

我收到了此错误,因为我试图将(Databricks)笔记本作为模块包含;有关此文件类型格式的一些内容启动了此错误。

我通过确保仅将直python文件作为模块包含来解决。

其次,当使用Databricks中的云计算时,共享的计算集群将产生相同的错误 - 单用户群集将在没有错误的情况下工作。

I received this error because I was attempting to include (DataBricks) notebooks as modules; something about the format of this file type kicks this error.

I resolved by ensuring that I include only straight python files as modules.

Secondarily, when using cloud compute in DataBricks, a shared compute cluster will generate the same error - a single-user cluster will work without error.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文