{ "info": { "author": "Emils Solmanis", "author_email": "emils.solmanis@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# What is this?\n\nA streaming async API to 4chan boards. You create a handler class, implement some callbacks and get informed when new\nposts and images arrive in threads. There's a bundled `FileHandler` that saves content to the file system and a\n`SQLiteHandler` that saves posts in per-date SQLite DBs.\n\n**NOTE**: the `FileHandler` will eat up your `inode`s, a default Debian install scraping */b/* got exhausted in ~ 6\nmonths. Use the `SQLiteHandler` unless you plan to clean the file root regularly.\n\n# How?\n\nThe bundled executable called `hurr-durr` is a scraper. You use it as\n\n hurr-durr --directory /tmp/4chan/sqlite-files --board b\n\nThere's an optional `-i` flag to also download the images and a `-v` flag to see logging information.\n\nStorage defaults to SQLite DB per day, unless overridden via `-f file`, which produces 1 JSON file per thread in a \nstructure of `data_dir/YYYYmmdd/threadID/threadID.json`.\n\nAll this info is also available via the `-h` flag.\n\nAs for the API part, the main entry point is `hurr_durr.ChanWatcher`. You have to implement a handler class and then\ndo something along the lines of\n\n```python\nfrom hurr_durr import FileHandler, ChanWatcher\n\nwatcher = ChanWatcher(FileHandler('/tmp/4chan/b'), 'b', images=True)\nwatcher.start()\n```\n\nor\n\n```python\nfrom hurr_durr import SQLiteHandler, ChanWatcher\n\nwatcher = ChanWatcher(SQLiteHandler('/tmp/4chan/b'), 'b')\nwatcher.start()\n```\n\nThe handlers currently bundled are `FileHandler` which saves content to disk in files and `SQLiteHandler`, which saves\nposts in SQLite DBs. To implement your own handler, you need to create a class inheriting from `Handler`, \ncontaining 4 methods:\n\n * `post(thread_id, new_post)` -- gets called when a new post is made in a thread\n * `pruned(thread_id)` -- gets called when a thread is pruned from 4chan\n * `img(thread_id, filename, data)` -- gets called with downloaded image data, only relevant if images are downloaded\n * `download_img(thread_id, filename)` -- gets called to check if a particular image should be downloaded, only relevant\n if images are downloaded\n\n# Installing\n\nIt's in PyPI, just use pip\n\n pip install hurr-durr\n\n# Why?\n\nBecause I needed a 4chan scraper, everything else sucked, and I wanted to give Tornado a ride around the block.\n\n# License\n\n Copyright 2014 Emils Solmanis\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.", "description_content_type": null, "docs_url": null, "download_url": "https://github.com/emilssolmanis/hurr-durr/archive/0.2.2.tar.gz", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/emilssolmanis/hurr-durr", "keywords": "4chan stream async", "license": "Apache License (2.0)", "maintainer": null, "maintainer_email": null, "name": "hurr-durr", "package_url": "https://pypi.org/project/hurr-durr/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/hurr-durr/", "project_urls": { "Download": "https://github.com/emilssolmanis/hurr-durr/archive/0.2.2.tar.gz", "Homepage": "https://github.com/emilssolmanis/hurr-durr" }, "release_url": "https://pypi.org/project/hurr-durr/0.2.2/", "requires_dist": null, "requires_python": null, "summary": "Streaming async interface to 4chan boards", "version": "0.2.2" }, "last_serial": 1283232, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "65c45f62fdfbd3c997c94a3533936ec8", "sha256": "29156e0855f4a081453de85f58873cb5eb69358a5851dd940870ed6dc8e94b63" }, "downloads": -1, "filename": "hurr-durr-0.0.1.tar.gz", "has_sig": false, "md5_digest": "65c45f62fdfbd3c997c94a3533936ec8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5231, "upload_time": "2014-01-18T20:25:41", "url": "https://files.pythonhosted.org/packages/ad/6f/47ffb01b4f423f03f07e27a6c7e0dda19819a100b71b7b4ed0cd39ed4196/hurr-durr-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "ebaded5361aa61067cee5bf20092c7c1", "sha256": "d721108106d00592d3dcab2c67b589a5bc57741e752c045199f552010ee9b1a4" }, "downloads": -1, "filename": "hurr-durr-0.0.2.tar.gz", "has_sig": false, "md5_digest": "ebaded5361aa61067cee5bf20092c7c1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5267, "upload_time": "2014-01-18T20:27:27", "url": "https://files.pythonhosted.org/packages/01/43/121f42b734ae5a9049552bb92c68cd8715f2c9bf5dd26ab1039ce2d157f0/hurr-durr-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "b9381c29204fedb4a2a69104a3466535", "sha256": "fb562d879b782d8bcd4a96b54b28a4998c68e85a895772bcd8028c618e3ee440" }, "downloads": -1, "filename": "hurr-durr-0.0.3.tar.gz", "has_sig": false, "md5_digest": "b9381c29204fedb4a2a69104a3466535", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5511, "upload_time": "2014-01-18T20:40:13", "url": "https://files.pythonhosted.org/packages/78/88/96ae4738ed29332a12775206458be44130662e34db77145049fc3d7cebdc/hurr-durr-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "8e923cef9580f4e153a7033c4809d790", "sha256": "f5d06dcc302d98cf32db3c242b5ee876c5ca268115d80a6bb055a99fbd0a66b9" }, "downloads": -1, "filename": "hurr-durr-0.0.4.tar.gz", "has_sig": false, "md5_digest": "8e923cef9580f4e153a7033c4809d790", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5614, "upload_time": "2014-01-18T21:18:13", "url": "https://files.pythonhosted.org/packages/c0/86/afb5188018cb10efcc28920f9eb5348ca3ae34e3b2530dc3747f8147dfc8/hurr-durr-0.0.4.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "83e9a168ac3da7f5e64a829f693c457a", "sha256": "73580af7dcb7118b763ae3b19e7c0569bf530122c905ba8ee6e9e5bfbe66bdab" }, "downloads": -1, "filename": "hurr-durr-0.0.5.tar.gz", "has_sig": false, "md5_digest": "83e9a168ac3da7f5e64a829f693c457a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5663, "upload_time": "2014-01-19T16:28:36", "url": "https://files.pythonhosted.org/packages/18/47/5246b92b3467ad26ef38cb0da0fe714260fb7297965e799f4f6fd427ba5f/hurr-durr-0.0.5.tar.gz" } ], "0.1.0": [ { "comment_text": "", "digests": { "md5": "388e0ae1381b75a6080072187ac5eb7b", "sha256": "6944dfb131fdc51eb383cf9dced76f95f4df9ae3acfcf1355fbefa51aa35a020" }, "downloads": -1, "filename": "hurr-durr-0.1.0.tar.gz", "has_sig": false, "md5_digest": "388e0ae1381b75a6080072187ac5eb7b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5931, "upload_time": "2014-05-05T15:56:02", "url": "https://files.pythonhosted.org/packages/11/55/bef718f5f671a2111fde02b77c8a401535c1de623a8d2a1e38ae78989d11/hurr-durr-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "0892d7249379123c49b44263556d7a4d", "sha256": "76588473f6c23f27b9054e336ad855cf2e71390f1a396ffe2e6a8b9262511b10" }, "downloads": -1, "filename": "hurr-durr-0.1.1.tar.gz", "has_sig": false, "md5_digest": "0892d7249379123c49b44263556d7a4d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5959, "upload_time": "2014-05-05T15:59:01", "url": "https://files.pythonhosted.org/packages/80/92/3d4c2c7b44a2666f2d6fdc69c34c1667a6661157e54d281fba54aa36a1e0/hurr-durr-0.1.1.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "bfd3a90d5e7d4f40ad42e10f61ccc1fe", "sha256": "dc5f954ffedb09b76cd7dd5becf695480f50318d824a670a0d454440f36ea246" }, "downloads": -1, "filename": "hurr-durr-0.2.0.tar.gz", "has_sig": false, "md5_digest": "bfd3a90d5e7d4f40ad42e10f61ccc1fe", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7687, "upload_time": "2014-10-25T16:09:45", "url": "https://files.pythonhosted.org/packages/ef/08/e77429ad0b04979f3e9395c8a3dcc129396c354c8d8620e82218088fbce7/hurr-durr-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "22b48f794f2871aaedadfcbd70ded651", "sha256": "18489f98d54aeac612dd9627b6d45e0635b483ad63ea5efb2ae1419a7bc54590" }, "downloads": -1, "filename": "hurr-durr-0.2.1.tar.gz", "has_sig": false, "md5_digest": "22b48f794f2871aaedadfcbd70ded651", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7981, "upload_time": "2014-10-25T16:21:09", "url": "https://files.pythonhosted.org/packages/44/b1/bb56c43aee22dd09b31625e4112102990f91b1823441c26dcef30659373a/hurr-durr-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "4021b831e5a82ae5b13c1758b59b2b4c", "sha256": "ef2c3d9d6073369c8f1f3a2153ebe480a610b57888de8de0309d99c125aa844f" }, "downloads": -1, "filename": "hurr_durr-0.2.2-py2.7.egg", "has_sig": false, "md5_digest": "4021b831e5a82ae5b13c1758b59b2b4c", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 17532, "upload_time": "2014-10-26T14:36:28", "url": "https://files.pythonhosted.org/packages/10/88/db37eb11a6a53f33ff210ebfcbc22dd1a96187d873dbde49dc6836af09a2/hurr_durr-0.2.2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "26e8ef209690458539f7ac970021a4ce", "sha256": "008f1d1dd49d183cd915ee75d12cee28df1f112f96ae365f9c945f53b991d75b" }, "downloads": -1, "filename": "hurr-durr-0.2.2.tar.gz", "has_sig": false, "md5_digest": "26e8ef209690458539f7ac970021a4ce", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9398, "upload_time": "2014-10-26T14:39:03", "url": "https://files.pythonhosted.org/packages/11/84/2450b496530dcd89e6f9446462517af3c5908f678e56a4ca48666ddcac61/hurr-durr-0.2.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "4021b831e5a82ae5b13c1758b59b2b4c", "sha256": "ef2c3d9d6073369c8f1f3a2153ebe480a610b57888de8de0309d99c125aa844f" }, "downloads": -1, "filename": "hurr_durr-0.2.2-py2.7.egg", "has_sig": false, "md5_digest": "4021b831e5a82ae5b13c1758b59b2b4c", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 17532, "upload_time": "2014-10-26T14:36:28", "url": "https://files.pythonhosted.org/packages/10/88/db37eb11a6a53f33ff210ebfcbc22dd1a96187d873dbde49dc6836af09a2/hurr_durr-0.2.2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "26e8ef209690458539f7ac970021a4ce", "sha256": "008f1d1dd49d183cd915ee75d12cee28df1f112f96ae365f9c945f53b991d75b" }, "downloads": -1, "filename": "hurr-durr-0.2.2.tar.gz", "has_sig": false, "md5_digest": "26e8ef209690458539f7ac970021a4ce", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9398, "upload_time": "2014-10-26T14:39:03", "url": "https://files.pythonhosted.org/packages/11/84/2450b496530dcd89e6f9446462517af3c5908f678e56a4ca48666ddcac61/hurr-durr-0.2.2.tar.gz" } ] }