{ "info": { "author": "Fedora Infrastructure Team and Szymon M", "author_email": "infrastructure@lists.fedoraproject.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Environment :: Web Environment", "Framework :: Twisted", "Intended Audience :: Developers", "License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "FMN is a family of systems to manage end-user notifications triggered by\nfedmsg, the Federated Message bus.\n\nThe FMN Server-Sent Events server allows users to view their fedmsg feed in realtime\nusing [server-sent events](https://html.spec.whatwg.org/multipage/comms.html#server-sent-events).\nIt relies on a service to populate the RabbitMQ message queues for it. Typically, this is\ndone with the FMN core services.\n\n## Install\n\nTo get ``fmn.sse`` directly from PyPi you can use pip:\n\n```\npip install fmn.sse\n```\n\nIf you're using Fedora, you can install it with DNF:\n\n```\nsudo dnf install python-fmn-sse\n```\n\nIf you're using CentOS 7, you can install it from EPEL 7 with yum:\n\n```\nsudo yum install python-fmn-sse\n```\n\n## Development Environment\n\nTo set up the development environment, you can either use Vagrant to provision\na virtual machine and automatically configure it, or you can manually set up\nthe environment.\n\n### Vagrant\n\nThe easiest way to get a development environment set up is with Vagrant. Refer\nto the [fmn repository](https://github.com/fedora-infra/fmn) for the Vagrantfile\nand instructions on how to set up Vagrant.\n\n\n### Manual\n\n1. Install the system dependencies. For Fedora:\n```\nsudo dnf install python python-devel python3-devel python-virtualenvwrapper \\\nrabbitmq-server python-pip gcc libffi-devel openssl-devel zeromq-devel\n```\n\n2. Install the Python dependencies:\n```\npip install -r requirements.txt\n```\n\n3. Install the ``fmn.sse`` package:\n```\npip install -e .\n```\n\n## Running\n\n1. Ensure RabbitMQ is running:\n```\nsudo systemctl start rabbitmq-server\n```\n\n2. Start the SSE server:\n```\ntwistd -n -l - -y usr/share/fmn.sse/server.tac\n```\n\n3. Make sure the server is available. This should return a HTTP 404:\n```\ncurl -v http://localhost:8080/\n```\n\n## Test Data\n\n```\nworkon sse-py2\npip install pytz\npython dev-data.py\n```\n\n## Manual Testing\n\n`sse_webserver.py` curl seems to work okay for me `curl http://localhost:8080/user/bob`\n\nand/or\n\nopen up `sse_test_subscriber.html` in a browser and look at the JS console\n\n## Running unittests\n```\nworkon sse-py2\npython setup.py test\n```\n\nwith coverage\n\n```\nworkon sse-py2\npip install -r requirements-test.txt\npy.test --cov=fmn tests/\n```\n\n### Common issues\n\nQ: I can't connect to rabbitmq with pika\n\nA: Make sure you are running rabbitmq `sudo systemctl start rabbitmq-server`\n\nQ: I get the following error\n```\npika.exceptions.ChannelClosed: (406, \"PRECONDITION_FAILED - inequivalent arg 'x-message-ttl' for queue 'skrzepto.id.fedoraproject.org' in vhost '/': received '60000' but current is '86400000'\")\n```\n\nA: You have set the queue a ttl that is not the same. You need to either match the ttl or delete the queue and retry.\n\nGo into http://localhost:15672/ and delete the queue. Thats assuming you enabled the management plugin https://www.rabbitmq.com/management.html\n\nQ: Nothing is being displayed on the curl\n\nA: Wait a few more seconds, it takes a moment to display the data. If it's more\nthan a minute check to see if the queue has data via the web ui http://localhost:15672/", "description_content_type": null, "docs_url": null, "download_url": "https://pypi.python.org/pypi/fmn_sse/", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/fedora-infra/fmn.sse/", "keywords": "", "license": "GPLv2+", "maintainer": "", "maintainer_email": "", "name": "fmn-sse", "package_url": "https://pypi.org/project/fmn-sse/", "platform": "", "project_url": "https://pypi.org/project/fmn-sse/", "project_urls": { "Download": "https://pypi.python.org/pypi/fmn_sse/", "Homepage": "https://github.com/fedora-infra/fmn.sse/" }, "release_url": "https://pypi.org/project/fmn-sse/0.2.1/", "requires_dist": null, "requires_python": "", "summary": "Real time feed for fedmsg", "version": "0.2.1" }, "last_serial": 2570382, "releases": { "0.2.1": [ { "comment_text": "", "digests": { "md5": "11cb204c226228b9085724413a5b7c55", "sha256": "bf5be09fe113f326adf15baab7edc53d50bb6deb57d57f36c1c262598bac629d" }, "downloads": -1, "filename": "fmn_sse-0.2.1.tar.gz", "has_sig": true, "md5_digest": "11cb204c226228b9085724413a5b7c55", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16550, "upload_time": "2017-01-12T18:47:43", "url": "https://files.pythonhosted.org/packages/36/b3/16cee495581b35a2b80505fdb60c86b6e2cf8338db5faeb74acbd88368c1/fmn_sse-0.2.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "11cb204c226228b9085724413a5b7c55", "sha256": "bf5be09fe113f326adf15baab7edc53d50bb6deb57d57f36c1c262598bac629d" }, "downloads": -1, "filename": "fmn_sse-0.2.1.tar.gz", "has_sig": true, "md5_digest": "11cb204c226228b9085724413a5b7c55", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16550, "upload_time": "2017-01-12T18:47:43", "url": "https://files.pythonhosted.org/packages/36/b3/16cee495581b35a2b80505fdb60c86b6e2cf8338db5faeb74acbd88368c1/fmn_sse-0.2.1.tar.gz" } ] }