Github user dgingrich commented on a diff in the pull request:
https://github.com/apache/spark/pull/16845#discussion_r100175968
--- Diff: python/pyspark/broadcast.py ---
@@ -82,7 +82,7 @@ def dump(self, value, f):
except pickle.PickleError:
raise
except Exception as e:
- msg = "Could not serialize broadcast: " + e.__class__.__name__
+ ": " + e.message
+ msg = "Could not serialize broadcast: " + e.__class__.__name__
+ ": " + str(e)
--- End diff --
Good call, I forgot about Python 2's `str`/`unicode` behavior. It could be
a problem if an exception includes user input as part of the message. IMO it's
worth handling it rigorously since throwing in the `except:` hides the original
error. I'll look at fixes tonight, in the worse case we could add a
`get_exception_message()` helper.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]