MCPcopy Create free account
hub / github.com/Tencent/CodeAnalysis / stderr_callback

Method stderr_callback

client/tool/flake8.py:162–171  ·  view source on GitHub ↗

报错回调处理 :param line: :return:

(self, line)

Source from the content-addressed store, hash-verified

160 return log
161
162 def stderr_callback(self, line):
163 """
164 报错回调处理
165 :param line:
166 :return:
167 """
168 self.print_log(line)
169 if line.find("UnicodeDecodeError")!=-1 and sys.platform=="win32":
170 logger.error("遇到编码问题!猜测是在windows、Python2下无法处理中文文件路径BUG, 建议改为在Mac、Linux下运行。")
171 raise AnalyzeTaskError('工具编码BUG,建议改为在Mac、Linux下运行')
172
173 def on_status(self, pid, rtcode):
174 """

Callers

nothing calls this directly

Calls 3

AnalyzeTaskErrorClass · 0.90
errorMethod · 0.80
print_logMethod · 0.45

Tested by

no test coverage detected