This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ethan.furman
Recipients amaury.forgeotdarc, ethan.furman, facundobatista, jcea
Date 2013-10-16.17:50:44
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1381945845.42.0.979206073436.issue19272@psf.upfronthosting.co.za>
In-reply-to
Content
According to the docs[1]:

12.1.4. What can be pickled and unpickled?

The following types can be pickled:

    - None, True, and False
    - integers, floating point numbers, complex numbers
    - strings, bytes, bytearrays
    - tuples, lists, sets, and dictionaries containing only picklable objects
    - functions defined at the top level of a module
    - built-in functions defined at the top level of a module
    - classes that are defined at the top level of a module
    - instances of such classes whose __dict__ or the result of calling
      __getstate__() is picklable 

Notice that lambda is not in that list.


The docs for concurrent.futures.ProcessPoolExecutor[2] state:

17.4.3. ProcessPoolExecutor

The ProcessPoolExecutor class is an Executor subclass that uses a pool of processes to execute calls asynchronously. ProcessPoolExecutor uses the multiprocessing module, which allows it to side-step the Global Interpreter Lock but also means that only picklable objects can be executed and returned.



[1] http://docs.python.org/3/library/pickle.html#what-can-be-pickled-and-unpickled
[2] http://docs.python.org/dev/libraryconcurrent.futures.html?highlight=concurrent#processpoolexecutor
History
Date User Action Args
2013-10-16 17:50:45ethan.furmansetrecipients: + ethan.furman, facundobatista, jcea, amaury.forgeotdarc
2013-10-16 17:50:45ethan.furmansetmessageid: <1381945845.42.0.979206073436.issue19272@psf.upfronthosting.co.za>
2013-10-16 17:50:45ethan.furmanlinkissue19272 messages
2013-10-16 17:50:44ethan.furmancreate