简体   繁体   English

尝试从github移植存储库时出错

[英]Error while trying to port a repo from github

There is a github code I am trying to use that is located here . 我尝试使用的github代码位于此处

I am trying to run params.py which is a code that will take a binary file and converts it so that I can plot it (or so I think). 我正在尝试运行params.py ,这是一个将获取二进制文件并将其转换的代码,以便我可以对其进行绘图(或我认为)。

I tried to run: 我试着跑:

pip install git+https://github.com/PX4/pyulog.git

However, that gave me an error: 但是,这给了我一个错误:

C:\Users\Mike\Documents>pip install git+https://github.com/PX4/pyulog.git
Collecting git+https://github.com/PX4/pyulog.git
  Cloning https://github.com/PX4/pyulog.git to c:\users\mike\appdata\local\temp\pip-t_vvh_b0-build
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Anaconda3\lib\tokenize.py", line 454, in open
        buffer = _builtin_open(filename, 'rb')
    FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\Mike\\AppData\\Local\\Temp\\pip-t_vvh_b0-build\\setup.py'

Pip install tries to install the module from : Pip install尝试从以下位置安装模块:

  • PyPI (and other indexes) using requirement specifiers. 使用需求说明符的PyPI(和其他索引)。
  • VCS project urls. VCS项目网址。
  • Local project directories. 本地项目目录。
  • Local or remote source archives. 本地或远程源档案。

When looking at the items to be installed, pip checks what type of item each is, in the following order: 在查看要安装的物品时,pip按以下顺序检查每种物品的类型:

  • Project or archive URL. 项目或存档URL。
  • local directory (which must contain a setup.py , or pip will report an error). 本地目录(必须包含setup.py ,否则pip将报告错误)。
  • Local file (a sdist or wheel format archive, following the naming conventions for those formats). 本地文件(sdist或wheel格式存档,遵循这些格式的命名约定)。
  • A requirement, as specified in PEP 440. PEP 440中指定的要求。

In your case, git repo doesn't meet the requirement. 您的情况是,git repo不符合要求。 It doesn't have setup.py that's why you get the error. 它没有setup.py,这就是为什么您会收到错误消息。
Instead try cloning the repo on your local machine. 而是尝试在本地计算机上克隆存储库。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM