Hi,

I missed that discussion. 

IMHO, the renaming further complicates matters, since now selecting 
networking library must be done consistently in both library and app code.

E.g. if we add

try: 
    # Use Tulip on Python 3.3, or builtin asyncio on Python 3.4+ 
    import asyncio 
except ImportError: 
    # Use Trollius on Python <= 3.2 
    import trollius as asyncio 

to AutobahnPython, what if the user (running Py 3.4 with Trollius 
installed) does

import trollius as asyncio 

in his user code? Stuff will likely break.

A library (AutobahnPython) cannot know which one the user is running.

Either the choice is made canonically (and hence consistently between 
library and user code), or the choice is made by the library, and then user 
code would look like

from autobahn import asyncio

Mmh.

/Tobias



Am Dienstag, 20. Mai 2014 15:55:25 UTC+2 schrieb Victor Stinner:
>
> Hi, 
>
> I synchronized Trollius with Tulip 3.4.1. As discussed on this list, I 
> also chose to rename "asyncio" to "trollius" to make it possible to 
> use Trollius on Python 3.4+. 
>
> It is now more explicit than Trollius and Tulip are two different 
> projects which are "almost the same" but are different (yield from ... 
> vs yield From(...)). 
>
> It's still a beta version. I plan to release a new version this week. 
> I hesitate between the version "0.3" and the version "1.0". 
>
> It would be nice if someone can test the folllowing projects which are 
> known to work on Tulip and Trollius: 
>
> - AutobahnPython 
> - Pulsar 
> - Tornado 
> - aiodns 
>
> You will need to modify the source code to add the following code at 
> the top of files using asyncio: 
> --- 
> try: 
>     # Use Trollius on Python <= 3.2 
>     import trollius as asyncio 
> except ImportError: 
>     # Use Tulip on Python 3.3, or builtin asyncio on Python 3.4+ 
>     import asyncio 
> --- 
>
> Victor 
>

Reply via email to