-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-46308] Forbid recursive error handling by adding recursion guards #44210
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
Changes from 6 commits
285b85c
eaa16e6
8b707fd
3565443
8ed9134
a9433bd
c7f2130
e4f9280
8220c46
e0dfa86
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -20,6 +20,7 @@ | |||
| from collections.abc import Generator | ||||
| from typing import Optional, Any | ||||
|
|
||||
| from pyspark.sql.connect.client.core import ForbidRecursion | ||||
| from pyspark.testing.connectutils import should_test_connect, connect_requirement_message | ||||
| from pyspark.testing.utils import eventually | ||||
|
|
||||
|
|
@@ -133,6 +134,26 @@ def test_channel_builder_with_session(self): | |||
| client = SparkConnectClient(chan) | ||||
| self.assertEqual(client._session_id, chan.session_id) | ||||
|
|
||||
| def test_forbid_recursion(self): | ||||
|
||||
| status = rpc_status.from_call(cast(grpc.Call, rpc_error)) |
This seems hard to create a mock exception which would pass this without poking grpc's internals significantly. Alternatively we could introduce some testing clutches here, i.e. check if exception is from testing code, but that's not great either.
Uh oh!
There was an error while loading. Please reload this page.