GitHub user mortada opened a pull request:
https://github.com/apache/spark/pull/10867
[SPARK-12760] [DOCS] invalid lambda expression in python example for â¦
â¦local vs cluster
@srowen thanks for the PR at https://github.com/apache/spark/pull/10866!
sorry it took me a while.
This is related to https://github.com/apache/spark/pull/10866, basically
the assignment in the lambda expression in the python example is actually
invalid
```
In [1]: data = [1, 2, 3, 4, 5]
In [2]: counter = 0
In [3]: rdd = sc.parallelize(data)
In [4]: rdd.foreach(lambda x: counter += x)
File "<ipython-input-4-fcb86c182bad>", line 1
rdd.foreach(lambda x: counter += x)
^
SyntaxError: invalid syntax
```
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/mortada/spark doc_python_fix
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/10867.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #10867
----
commit fc9f16a2ffb5846ecc03c4df584f611e6728573d
Author: Mortada Mehyar <[email protected]>
Date: 2016-01-21T16:51:28Z
[SPARK-12760] [DOCS] invalid lambda expression in python example for local
vs cluster
----
---
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]