Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(agent): return SerializationError instead of aborting #121

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions src/isolate/connections/grpc/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,11 +108,8 @@ def execute_function(
# TODO: technically any sort of exception could be raised here, since
# depickling is basically involves code execution from the *user*.
function = from_grpc(function)
except SerializationError:
yield from self.log(traceback.format_exc(), level=LogLevel.ERROR)
raise AbortException(
f"The {function_kind} function could not be deserialized."
)
except SerializationError as exc:
return exc, True, traceback.format_exc()

if not callable(function):
raise AbortException(
Expand Down
Loading