加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 编程开发 > Python > 正文

python – Gittle – “意外的关键字参数’pkey’”

发布时间:2020-12-16 23:53:21 所属栏目:Python 来源:网络整理
导读:我正在尝试使用库gittle来克隆git存储库,我按照自述文件中的示例进行操作,这是我的代码. repo_path = '/path/to/dir/'repo_url = 'git@gitlab.myproject/proj.git'key = open('/path/to/.ssh/id_rsa')auth = GittleAuth(pkey=key)repo = Gittle.clone(repo_u

我正在尝试使用库gittle来克隆git存储库,我按照自述文件中的示例进行操作,这是我的代码.

repo_path = '/path/to/dir/'
repo_url  = 'git@gitlab.myproject/proj.git'
key = open('/path/to/.ssh/id_rsa')
auth = GittleAuth(pkey=key)
repo = Gittle.clone(repo_url,repo_path,auth=auth)

当我尝试运行它时,我遇到了这个异常:

Traceback (most recent call last):
  File "gitCmd2.py",line 26,in 

pip冻结的结果(python2.7):

dulwich==0.9.5
funky==0.0.2
gittle==0.3.0
mimer==0.0.1
paramiko==1.10.0
pycrypto==2.6
wsgiref==0.1.2

谢谢.

最佳答案
这是在github as TypeError: init() got an unexpected keyword argument ‘pkey’提交的问题

也在那里描述了解决方法 – 使用一些克隆版本的dulwich

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读