我剛剛從git倉庫中取回用戶在Python 2上。我的系統運行的是Python 3,並且沒有更改代碼,出現此錯誤:將.py文件轉換爲正確的Python編碼3
TabError: inconsistent use of tabs and spaces in indentation
看來解決方案是更改.py
文件的字符集編碼,但在emacs中工作,我不清楚如何執行此操作。我看到這些說明:
https://www.emacswiki.org/emacs/ChangingEncodings
,但我不明白如何應用這些爲UTF-8。我會很感激任何建議。
[Make Emacs在Python交互模式下使用UTF-8]的可能副本(http://stackoverflow.com/questions/888406/make-emacs-use-utf-8-with-python-interactive-mode) – JackCC