{ "info": { "author": "mikey", "author_email": "mikey@corleone.it", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "====\ncoid\n====\n\n.. image:: https://travis-ci.org/bninja/coid.png\n :target: https://travis-ci.org/bninja/coid\n\n.. image:: https://coveralls.io/repos/bninja/ciao/badge.png\n :target: https://coveralls.io/r/bninja/ciao\n\nSimple resource throttling. Get it:\n\n.. code:: bash\n\n $ pip install coid\n\nuse it e.g. like:\n\n.. code:: python\n\n import datetime\n \n import ciao\n import sqlalchemy as sa\n\n db_engine = sa.create_engine('postgres://mikey:corleone@localhost/study')\n \n db_throttle = ciao.Throttle(\n duration=datetime.timedelta(seconds=30),\n exc=(\n sa.exc.OperationalError,\n sa.exc.DisconnectionError,\n sa.exc.InvalidRequestError,\n sa.exc.InterfaceError,\n sa.exc.DatabaseError,\n sa.exc.DBAPIError,\n ),\n )\n \n if not db_throttle:\n with db_throttle:\n db_engine.execute('SELECT * FROM slippers WHERE name = \"mine\"')", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/bninja/ciao", "keywords": null, "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "ciao", "package_url": "https://pypi.org/project/ciao/", "platform": "any", "project_url": "https://pypi.org/project/ciao/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/bninja/ciao" }, "release_url": "https://pypi.org/project/ciao/0.1.0/", "requires_dist": null, "requires_python": null, "summary": "Michael Corleone says ...", "version": "0.1.0" }, "last_serial": 1238236, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "506bdb150aa658522303fb17076dfd7d", "sha256": "1001c265c652ab5d5bf53b943d5bce1c42b83b8caf580a2dcd4d577f4648bcbd" }, "downloads": -1, "filename": "ciao-0.1.0.tar.gz", "has_sig": false, "md5_digest": "506bdb150aa658522303fb17076dfd7d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2702, "upload_time": "2014-09-25T22:52:37", "url": "https://files.pythonhosted.org/packages/7b/37/858c0e3513df8445915135a3a59ac1e40d2990a5397bf36bdec5fe9b17de/ciao-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "506bdb150aa658522303fb17076dfd7d", "sha256": "1001c265c652ab5d5bf53b943d5bce1c42b83b8caf580a2dcd4d577f4648bcbd" }, "downloads": -1, "filename": "ciao-0.1.0.tar.gz", "has_sig": false, "md5_digest": "506bdb150aa658522303fb17076dfd7d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2702, "upload_time": "2014-09-25T22:52:37", "url": "https://files.pythonhosted.org/packages/7b/37/858c0e3513df8445915135a3a59ac1e40d2990a5397bf36bdec5fe9b17de/ciao-0.1.0.tar.gz" } ] }