psutil compatibility issue in gaffer==0.5.2

未关闭
#60 5 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
1/5
预计耗时
1 小时以内
新手友好度
45/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
python
领域
tooling

调研方向

检查 setup.py 第 62 行附近不受版本限制的 psutil 依赖项,然后使用已安装的依赖项重现导入失败,并通过 gaffer --version 命令验证行为。完成的标准是全新安装使用兼容的 psutil 版本,并且 gaffer --version 成功运行。

由索引模型根据 Issue 内容生成。

描述

$ pip install gaffer
...
Successfully built gaffer pyuv psutil tornado colorama setproctitle
Installing collected packages: pyuv, psutil, tornado, colorama, setproctitle, gaffer
Successfully installed colorama-0.3.3 gaffer-0.5.2 psutil-3.0.1 pyuv-1.1.0 setproctitle-1.1.8 tornado-2.4.1

So far so good. Trying things out...

$ gaffer --version
Traceback (most recent call last):
  File "/tmp/ashald/.venvs/tmp-17f0a3d67a1d4821/bin/gaffer", line 7, in <module>
    from gaffer.cli.main import main
  File "/tmp/ashald/.venvs/tmp-17f0a3d67a1d4821/lib/python2.7/site-packages/gaffer/cli/main.py", line 40, in <module>
    from ..httpclient import Server, GafferUnauthorized, GafferForbidden
  File "/tmp/ashald/.venvs/tmp-17f0a3d67a1d4821/lib/python2.7/site-packages/gaffer/httpclient/__init__.py", line 38, in <module>
    from .job import Job
  File "/tmp/ashald/.venvs/tmp-17f0a3d67a1d4821/lib/python2.7/site-packages/gaffer/httpclient/job.py", line 7, in <module>
    from ..process import ProcessConfig
  File "/tmp/ashald/.venvs/tmp-17f0a3d67a1d4821/lib/python2.7/site-packages/gaffer/process.py", line 18, in <module>
    from psutil.error import AccessDenied
ImportError: No module named error

Quick googling leads to "psutil.error.py module was removed in 2.0.0 version"

Second attempt:

$ pip install "psutil<2"
...
Successfully installed psutil-1.2.1

$ gaffer --version
gaffer version 0.5.2

Looking at setup.py in master there is version-unbounded dependency on psutil.

主要语言
Python
星标
365
派生
32
PR 合并指标
30 天内没有已合并 PR

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

benoitc/gaffer 的其他 Issue

查看 benoitc/gaffer 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。