{ "info": { "author": "Zachary Voase", "author_email": "z@zacharyvoase.com", "bugtrack_url": null, "classifiers": [], "description": "Teena: UNIX in Python\n=====================\n\nTeena aims to be a collection of ports of UNIX and Linux syscalls to\npure Python, with an emphasis on performance and correctness. Windows\nsupport is not a primary concern\u2014I\u2019m initially targeting only\nPOSIX-compliant operating systems. The library uses\n`Tornado `_ to do efficient asynchronous\nI/O.\n\nThe first version of this library will contain implementations of\n``tee`` and ``splice`` which operate on files, sockets, and file\ndescriptors. There\u2019s also a ``Capture`` class which behaves like\n``StringIO``, but it has a ``fileno()`` and so can be used where a real\nfile descriptor is needed.\n\nExample\n-------\n\nI\u2019ll demonstrate how to capture the result of an HTTP request, whilst\nefficiently streaming the response to ``stderr``.\n\nDo the necessary imports:\n\n::\n\n >>> from contextlib import closing\n >>> import teena\n >>> import os\n >>> import sys\n >>> import urllib2\n\nCreate a ``teena.Capture()`` object to capture the output:\n\n::\n\n >>> capture = teena.Capture()\n\nOpen a connection using ``urllib2.urlopen()``. This connection object\nhas an associated file descriptor, so you can pass it directly into\n``tee()``:\n\n::\n\n >>> with closing(urllib2.urlopen('http://whatthecommit.com/index.txt')) as conn:\n ... teena.tee(conn, (sys.stderr, capture.input))\n This really should not take 19 minutes to build.\n >>> print repr(capture.getvalue())\n 'This really should not take 19 minutes to build.\\n'\n\nInstallation\n------------\n\n::\n\n pip install teena\n\nLicense\n-------\n\nCopyright (C) 2012 Zachary Voase\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be included\nin all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\nOR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/zacharyvoase/teena", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "teena", "package_url": "https://pypi.org/project/teena/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/teena/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/zacharyvoase/teena" }, "release_url": "https://pypi.org/project/teena/0.0.2/", "requires_dist": null, "requires_python": null, "summary": "Python ports of useful syscalls, using asynchronous I/O.", "version": "0.0.2" }, "last_serial": 800412, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "1fbc09649a1309acecba40c0bbb0431e", "sha256": "366aa7f1ac29719441546245e40dca32177d1bb65782a3dd35f48b16d6a70d5e" }, "downloads": -1, "filename": "teena-0.0.1.tar.gz", "has_sig": false, "md5_digest": "1fbc09649a1309acecba40c0bbb0431e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13909, "upload_time": "2012-06-25T15:40:09", "url": "https://files.pythonhosted.org/packages/de/36/93f0f67b5c07027d03faa0d2efefbc8423613c7f9daf1075ff60801b8a1b/teena-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "7c2d05abed561fe0c9da892f1b83b7b5", "sha256": "90ef3756d41cca625c83bb02c0377b74baf526fdb94df60d6421c5a1ccddc4f1" }, "downloads": -1, "filename": "teena-0.0.2.tar.gz", "has_sig": false, "md5_digest": "7c2d05abed561fe0c9da892f1b83b7b5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14826, "upload_time": "2012-06-25T15:46:33", "url": "https://files.pythonhosted.org/packages/51/ca/c9d24e70b30e7d7b998586f25b6bad695e66ac4f25005b1843610edd9140/teena-0.0.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7c2d05abed561fe0c9da892f1b83b7b5", "sha256": "90ef3756d41cca625c83bb02c0377b74baf526fdb94df60d6421c5a1ccddc4f1" }, "downloads": -1, "filename": "teena-0.0.2.tar.gz", "has_sig": false, "md5_digest": "7c2d05abed561fe0c9da892f1b83b7b5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14826, "upload_time": "2012-06-25T15:46:33", "url": "https://files.pythonhosted.org/packages/51/ca/c9d24e70b30e7d7b998586f25b6bad695e66ac4f25005b1843610edd9140/teena-0.0.2.tar.gz" } ] }