Re:Python 3.4.0 released
by DanWaterworth on Monday March 17, 2014 @04:37AM
(#7413827)
I've been using asyncio in the last week. I've found it remarkable clean and intuitive. It's difficult to compare to channels in go, because it's such a different solution to the same problem - that of structuring concurrent programs.
If anyone's interested in testing out Asyncio/Tulip on Python 2, here's a mostly-compatible backport: https://pypi.python.org/pypi/trollius/
They aren't like channels. If you want something like channels, try out greenlets for CPython, Stackless Python (a modified version of CPython) or pypy.
Re:Python 3.4.0 released
by nostrademons on Monday March 17, 2014 @02:14PM
(#7416908)
I suspect that you could easily implement channels on top of asyncio - goroutines = coroutines, hide the yield-from inside 'send', select = asyncio.wait(return_when=FIRST_COMPLETED).
Go channels are the only experience I have with concurrent programming, but when I understood them it quickly became second nature to create everything using channels. Can techniques like websockets be used now as cleanly as in Go?