解决UnicodeEncodeError: 'ascii' codec can't encode character2024-01-26 21:01:34 直接上代码: import os import sys import importlib importlib.reload(sys) import codecs sys.stdout = codecs.getwriter("utf-8")(sys.stdout.detach()) sys.path.append(os.getcwd()) 上一篇:importlib之import_module下一篇:importlib.import_module