當tring改變目錄時,我總是收到以下錯誤:任何人都可以幫助解決問題以及如何解決這個問題?更改目錄時輸入錯誤
代碼片段: -
print "changing dir..."
print "BUILDDIR: " + BuildDir
os.chdir(BuildDir)
print "Done changing dir..."
錯誤: -
changing dir...
BUILDDIR: /local/mnt/workspace/username/AU_LINUX_ANDROID_CHO_3.5.04.03.00.003.047_msm8216/
Traceback (most recent call last):
File "Main.py", line 682, in <module>
flist = fd.readlines()
File "Main.py", line 654, in main
picked_gerrits = []
File "Main.py", line 126, in RepoSync
TypeError: must be encoded string without NULL bytes, not str
可能重複:http://stackoverflow.com/questions/12591575/python-typeerror-must-be-encoded-string-without -null-bytes-not-str – sPaz
@spaz - 我看着它..am使用前斜槓「/」,你從錯誤鏡頭看到.. – user2955256