提交 58782af5 authored 作者: Frederic's avatar Frederic

Fix error reporting when the error is reported by the input, not by an op.

上级 4af40ea8
...@@ -1392,6 +1392,7 @@ class _CThunk(object): ...@@ -1392,6 +1392,7 @@ class _CThunk(object):
trace = () trace = ()
try: try:
exc_type, _exc_value, exc_trace = self.error_storage exc_type, _exc_value, exc_trace = self.error_storage
if task in self.nodes:
self.position_of_error = self.nodes.index(task) self.position_of_error = self.nodes.index(task)
# this can be used to retrieve the location the Op was declared # this can be used to retrieve the location the Op was declared
exc_value = exc_type(_exc_value) exc_value = exc_type(_exc_value)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论