pygit2.GitError: failed to parse supported auth schemes: The operation identifier is not valid.
オープン
まだ誰も着手していません。
- 主要言語
- Python
- スター
- 1.7k
- フォーク
- 408
- 平均マージ
- 2日 57分
- マージ済み PR(30日)
- 7
説明
I am trying to clone private github repository using pygit2 module but getting the below error.
Traceback (most recent call last):
File ".\test2.py", line 29, in <module>
repoClone = pygit2.clone_repository(repo_from_template.clone_url, 'C://TestRepo', callbacks=callbacks)
File "C:\Anaconda3\lib\site-packages\pygit2\__init__.py", line 222, in clone_repository
payload.check_error(err)
File "C:\Anaconda3\lib\site-packages\pygit2\callbacks.py", line 93, in check_error
check_error(error_code)
File "C:\Anaconda3\lib\site-packages\pygit2\errors.py", line 65, in check_error
raise GitError(message)
_pygit2.GitError: failed to parse supported auth schemes: The operation identifier is not valid.
Below is the source code I am using
import pygit2
import config_
from github import Github
g = Github(<personal access token>,base_url='https://api.github.com')
github_user = g.get_user()
org = g.get_organization(<org-name>)
repo_from_template=org.create_repo(name='TestRepo',private=True)
credentials = pygit2.UserPass(github_user.login, <personal access token>)
callbacks = pygit2.RemoteCallbacks(credentials=credentials)
repoClone = pygit2.clone_repository(repo_from_template.clone_url, 'C://TestRepo', callbacks=callbacks)
I am using python 3.9 and have tried pygit2 version 1.10.1 and 1.12.0 and both are giving the same error.
Are there any changes made to the callbacks recently which is creating this issue?
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
Python 3.9 上で pygit2 1.10.1 と 1.12.0 をテストし、RemoteCallbacks と UserPass 認証情報を使ってプライベートな GitHub リポジトリに対する issue の clone_repository 呼び出しの失敗を再現する。traceback に示された callback と認証の経路を追跡する。原因が特定され、プライベートリポジトリのクローンに成功するか、互換性の問題が明確に文書化されれば完了とする。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- git, github, python
- 領域
- authentication, devtools
- issue の種類
- バグ
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100