{ "info": { "author": "Bruce Merry", "author_email": "", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2", "Programming Language :: Python :: 3", "Topic :: System :: Networking" ], "description": "# trollius2asyncio\n\nA tool based on lib2to3 for converting code using trollius to use\nasyncio. After installation, run *trollius2asyncio*. It works in the\nsame way as 2to3.\n\nFor example, it will transform this:\n```python\nimport trollius\nfrom trollius import From, Return\n\n@trollius.coroutine\ndef double_future(future):\n value = yield From(future)\n raise Return(2 * value)\n```\ninto\n```python\nimport asyncio\n\n\nasync def double_future(future):\n value = await future\n return 2 * value\n```\n\n## Usage\n\nAfter installation, run `trollius2asyncio` as you would `2to3`. It takes the\nsame command-line arguments, including `-h` for help.\n\n## Limitations\n\nIt recognises `From`, `trollius.From`, `Return` and `trollius.Return`, without\ntaking the imports into consideration. Thus, importing trollius as a different\nname will confuse it, and `from tornado.gen import Return` will cause the\nreturns from Tornado to also be rewritten (which should still be a legal\ntransformation).\n\nIt recognises `@trollius.coroutine`, again without taking imports into\nconsideration. If the decorator is omitted, it won't turn the function into a\ncoroutine, which will lead to syntax errors if it ends up containing `await`\nstatements. It also won't apply the transformation if there are additional\ndecorators inside (i.e., between `@trollius.coroutine` and the definition)\nsince that would alter the semantics.\n\nThe resulting code is not necessarily well-styled e.g., the extra blank line\nin the example above. These are limitations of lib2to3 and won't be easy to fix\nwithout risking breaking code in corner cases.\n\n## Release history\n\n### 0.2\n\n- Drop Python 3.4 support (output code uses async and await).\n\n### 0.1.1\n\n- Add licence.\n\n### 0.1\n\n- Initial release.\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/bmerry/trollius-fixers", "keywords": "2to3 asyncio trollius", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "trollius-fixers", "package_url": "https://pypi.org/project/trollius-fixers/", "platform": "", "project_url": "https://pypi.org/project/trollius-fixers/", "project_urls": { "Homepage": "https://github.com/bmerry/trollius-fixers" }, "release_url": "https://pypi.org/project/trollius-fixers/0.2/", "requires_dist": null, "requires_python": "", "summary": "Convert trollius code to asyncio", "version": "0.2" }, "last_serial": 5831423, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "dd5f23ec09624d9dacc4a8551d2e5df8", "sha256": "9b15df2d05622d3bd4d08344d58059bf00f4a9587c7b67d762db85d3b40957d0" }, "downloads": -1, "filename": "trollius-fixers-0.1.tar.gz", "has_sig": false, "md5_digest": "dd5f23ec09624d9dacc4a8551d2e5df8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3708, "upload_time": "2017-11-03T07:26:45", "url": "https://files.pythonhosted.org/packages/7f/28/b247a9510f6d564e57d710370a79c189db6bc6b6d5ed90f724d3987a6e76/trollius-fixers-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "272ea93744bb8241682078f0163a3da0", "sha256": "4bc6e54988a67887b3f0502348111d64c088e21becf728d361bce4218cc17b49" }, "downloads": -1, "filename": "trollius-fixers-0.1.1.tar.gz", "has_sig": false, "md5_digest": "272ea93744bb8241682078f0163a3da0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4713, "upload_time": "2017-11-03T18:23:27", "url": "https://files.pythonhosted.org/packages/75/f9/8d91a22ada6cb90a5d73b6e29469d976381ffdeee3b6c821bab709ee4bdd/trollius-fixers-0.1.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "c14b11e721fa4c7f85c6e7c0009c1076", "sha256": "b67c5218b5f25e888a7eb4b204631192cd6264bf91b2a9a9e0cae77c80b4ab5d" }, "downloads": -1, "filename": "trollius_fixers-0.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c14b11e721fa4c7f85c6e7c0009c1076", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 10091, "upload_time": "2019-09-15T10:45:58", "url": "https://files.pythonhosted.org/packages/48/80/ab43f03268aa23c61d6592b4e69ea6f4c922685e137bc8781e346f1ddd7b/trollius_fixers-0.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "5e0afa010697608f2ab056e60211da0c", "sha256": "85d8230dc137fbe43031a5c695a42d22c17e92b26a4bfc0582132f251f78acf9" }, "downloads": -1, "filename": "trollius-fixers-0.2.tar.gz", "has_sig": false, "md5_digest": "5e0afa010697608f2ab056e60211da0c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4595, "upload_time": "2019-09-15T10:46:26", "url": "https://files.pythonhosted.org/packages/ef/3c/4aac6cc24b2fbcaabd269c5634f91956756668384f59a64f50b69620edc2/trollius-fixers-0.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c14b11e721fa4c7f85c6e7c0009c1076", "sha256": "b67c5218b5f25e888a7eb4b204631192cd6264bf91b2a9a9e0cae77c80b4ab5d" }, "downloads": -1, "filename": "trollius_fixers-0.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c14b11e721fa4c7f85c6e7c0009c1076", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 10091, "upload_time": "2019-09-15T10:45:58", "url": "https://files.pythonhosted.org/packages/48/80/ab43f03268aa23c61d6592b4e69ea6f4c922685e137bc8781e346f1ddd7b/trollius_fixers-0.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "5e0afa010697608f2ab056e60211da0c", "sha256": "85d8230dc137fbe43031a5c695a42d22c17e92b26a4bfc0582132f251f78acf9" }, "downloads": -1, "filename": "trollius-fixers-0.2.tar.gz", "has_sig": false, "md5_digest": "5e0afa010697608f2ab056e60211da0c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4595, "upload_time": "2019-09-15T10:46:26", "url": "https://files.pythonhosted.org/packages/ef/3c/4aac6cc24b2fbcaabd269c5634f91956756668384f59a64f50b69620edc2/trollius-fixers-0.2.tar.gz" } ] }