2016-08-31 2 views
0

를 당겨,이 오류가 발생했습니다. 클론 fonction 완벽하게 여기파이썬 dulwich 오류 나는 dulwich있는 폴더를 끌어하려고하면

작동하는 것은 내 코드입니다 :

from dulwich import porcelain 
import ssl 

depot_maj = "https://github.com/jelmer/dulwich.git" 

#Disable SSL verification for private server 
ssl._create_default_https_context = ssl._create_unverified_context 


#porcelain.clone(depot_maj, "test") 
porcelain.pull("test", depot_maj) 

나는이 함께 풀 fonction 변경하는 경우 :

porcelain.pull("test", depot_maj, "refs/heads/master") 

내가 가진 :

TypeError: startswith first arg must be str or a tuple of str, not bytes 

을 내가 뭘 내가 잘못 했니?

편집 : 임

+0

아마도 파이썬 2에서 실행 중일 것입니다. 파일의 시작 부분에 ['__future__ import unicode_literals'] (http://python-future.org/unicode_literals.html)를 파일의 시작 부분에 추가하고 문제가 사라지면 파이썬 3을 사용 중이라면 내부 API가 파이썬 3 로의 불완전한 마이그레이션으로 인해 발생했을 수 있습니다. – metatoaster

+0

파이썬 3을 실행 중입니다 – Salamafet

+0

덜 리치의 내부 버그처럼 보이지만 완전히 파이썬 3과 호환되지 않습니다. – metatoaster

답변

0

이 문제가 Dulwich의 최신 버전에서 해결 FWIW을 파이썬 3.5을 실행.