pytorch/torch/csrc/jit/python
Rohan Varma a727bf2851 Refactor RPC matchBuiltInOp to get rid of exception swallowing (#49009)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/49009

As per the title, we should generally not have exception swalling and
this commit makes it so that if there is a true error in JIT operator
resolution, it is propagated back to the RPC callee and we don't silently
swallow any other exceptions that may happen. Swallowing the exceptions
previously resulted in hard to debug issues such as unexpected ops showing up
in profiler, and flaky tests which were fixed by
https://github.com/pytorch/pytorch/pull/41287

Added a unittest that validates the error that comes from `jit/pybind_utils.h`.
ghstack-source-id: 118794661

Test Plan: CI

Reviewed By: mrshenli

Differential Revision: D25392905

fbshipit-source-id: 6f93251635740bcf902824548b2bc6f9249be5f0
2020-12-17 11:37:21 -08:00
..
init.cpp Remove unused reconstruct_scopes function (#48822) 2020-12-11 23:43:36 -08:00
init.h
module_python.h
pybind_utils.h Refactor RPC matchBuiltInOp to get rid of exception swallowing (#49009) 2020-12-17 11:37:21 -08:00
pybind.h
python_arg_flatten.cpp [JIT] Fix clang-tidy warnings in jit/python (#47985) 2020-12-02 12:35:36 -08:00
python_arg_flatten.h Move torch/csrc/utils/hash.h to c10/util/hash.h. (#42503) 2020-08-29 17:47:00 -07:00
python_custom_class.cpp Support doc_string for TorchBind custom classes (#46576) 2020-10-24 12:51:35 -07:00
python_custom_class.h
python_interpreter.cpp Unify boxed function signature between jit and c10 (#37034) 2020-06-29 19:24:26 -07:00
python_ir.cpp [ONNX] Remove usage of isCompleteTensor() in symbolic functions (#48162) 2020-12-09 11:37:19 -08:00
python_ir.h
python_ivalue.h
python_sugared_value.cpp [JIT] Fix clang-tidy warnings in jit/python (#47985) 2020-12-02 12:35:36 -08:00
python_sugared_value.h [JIT] Fix clang-tidy warnings in jit/python (#47985) 2020-12-02 12:35:36 -08:00
python_tracer.cpp [JIT] Fix clang-tidy warnings in jit/python (#47985) 2020-12-02 12:35:36 -08:00
python_tracer.h Source code level attribution in profiler (#43898) 2020-09-30 00:57:35 -07:00
python_tree_views.cpp [JIT] Allow del statements with multiple targets (#48876) 2020-12-08 15:39:42 -08:00
python_tree_views.h
script_init.cpp Support torchbind as attribute in torch.fx symbolic tracing (#48732) 2020-12-04 16:21:44 -08:00
script_init.h
update_graph_executor_opt.cpp
update_graph_executor_opt.h