我在 iTerm2 終端中使用重新運行的 Go 包并出現錯誤讀取要收聽的文件列表時出錯!錯誤的文件描述符此錯誤來自 filepath.Walk 函數。問題是在集成的 VSCode 終端中一切正常,但在 iTerm2 中卻不行。我可以保證配置文件是 100% 正確的(重新運行說配置在其他方面不正確,而且我們在一個團隊中使用這個配置幾年)。另外我想提一下,iTerm2 在 MacOS 隱私設置中具有全盤訪問權限。非常感謝有關我的問題的任何信息或幫助。我在 macOS Monterey 12.1,M1 Max 上。完整錯誤:rerun -c rerun.jsongit/ivp/rer 21:40:28 ?[PANI] ? Error while reading list of files to listen! bad file descriptorpanic: Error while reading list of files to listen! %sgoroutine 1 [running]:github.com/ivpusic/golog.(*Logger).Panicf(0xc000166100, {0x12024a8, 0x2f}, {0xc00015de98, 0x1e51ff8, 0x18}) /Users/greenwookez/go/pkg/mod/github.com/ivpusic/[email protected]/logger.go:315 +0x134main.(*watcher).start(0xc0001261e0) /Users/greenwookez/go/pkg/mod/github.com/ivpusic/[email protected]/watcher.go:147 +0x2efmain.main() /Users/greenwookez/go/pkg/mod/github.com/ivpusic/[email protected]/main.go:51 +0x2af
1 回答

UYOU
TA貢獻1878條經驗 獲得超4個贊
通過默認的 Mac OS 終端重現了相同的問題,因此我決定從頭開始重新安裝 Mac OS(而不是從具有大量不同配置的舊 Mac 遷移)并添加unlim -n <more than 256>
到.zprofile
. 希望它會幫助某人。
- 1 回答
- 0 關注
- 127 瀏覽
添加回答
舉報
0/150
提交
取消