Github user JoshRosen commented on a diff in the pull request:
https://github.com/apache/spark/pull/2492#discussion_r17993070
--- Diff: python/pyspark/context.py ---
@@ -183,10 +183,9 @@ def _do_init(self, master, appName, sparkHome,
pyFiles, environment, batchSize,
for path in self._conf.get("spark.submit.pyFiles", "").split(","):
if path != "":
(dirname, filename) = os.path.split(path)
- self._python_includes.append(filename)
- sys.path.append(path)
- if dirname not in sys.path:
- sys.path.append(dirname)
+ if filename.lower().endswith("zip") or
filename.lower().endswith("egg"):
--- End diff --
Do we explicitly add `root_dir` to `sys.path`? I don't think we can always
assume that the Python driver / worker are executed from inside of `root_dir`.
---
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]