{ "info": { "author": "Alex (Oleksii) Markov", "author_email": "alex@markovs.me", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "importable\n==========\n\n.. image:: https://travis-ci.org/malexer/importable.svg?branch=master\n :target: https://travis-ci.org/malexer/importable\n :alt: Test Status\n\nAllows to import zip-compressed Python package by URL.\n\nDownload remote zip-compressed Python package, unzip and add to Python\npath.\n\nAll temp files will be removed on exit unless Python process was\nterminated.\n\nNote: ``import`` should be called separatelly after calling\n``importable``. All we do here - just adding package to local python path.\n\n\nSupported URL types\n-------------------\n\nimportable supports a limited set of URL types:\n\n1. Http url to zip file: ``http(s):///.zip``\n\n The module, which you are going to import, should be located on the\n first level of .zip\n\n See section Example.\n\n2. Http url to zip file on GitHub:\n ``http(s)://github.com//.zip``\n\n Similar to the previous type except that module is located inside an\n additional directory (in .zip).\n\n3. Hdfs url to zip file: ``webhdfs://://.zip``\n\n Similar to #1 except that file will be downloaded from HDFS.\n\n ```` - hostname or IP address of Hdfs namenode\n ```` - WebHdfs port of namenode\n\n\nInstall\n-------\n\nUsing pip::\n\n $ pip install importable\n\n\nUsage\n-----\n\nMake remote package importable, then import it and use:\n\n.. code-block:: python\n\n from importable import importable\n\n\n # add contents of \".zip\" to python path\n importable('http:///.zip')\n\n # now you can import your module\n import \n\n\nExample\n-------\n\nAssuming that you have local nginx serving ``/var/www/html/`` on port 80.\n\n.. code-block:: shell\n\n $ mkdir mymodule\n $ echo \"my_var = 'I want to import this one!'\" > mymodule/__init__.py\n $ zip -r mymodule.zip mymodule\n $ mv mymodule.zip /var/www/html\n\nThen execute the python code:\n\n.. code-block:: python\n\n >>> import mymodule\n Traceback (most recent call last):\n File \"\", line 1, in \n ImportError: No module named 'mymodule'\n >>> from importable import importable\n >>> importable('http://localhost/mymodule.zip')\n >>> import mymodule\n >>> print(mymodule.my_var)\n I want to import this one!\n\n\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/malexer/importable", "keywords": "import url http hdfs zip importable python_path", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "importable", "package_url": "https://pypi.org/project/importable/", "platform": "", "project_url": "https://pypi.org/project/importable/", "project_urls": { "Homepage": "https://github.com/malexer/importable" }, "release_url": "https://pypi.org/project/importable/0.2.2/", "requires_dist": [ "hdfs", "requests" ], "requires_python": "", "summary": "Allows to import zip-compressed Python package by URL (http, hdfs).", "version": "0.2.2" }, "last_serial": 3361009, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "1141a914a62d0bebe569d5682b20b186", "sha256": "e9d319987764eb83daacaa249a774cdca90caf3082787a33c5dc45817d7c5e51" }, "downloads": -1, "filename": "importable-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "1141a914a62d0bebe569d5682b20b186", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 3539, "upload_time": "2017-10-13T13:04:40", "url": "https://files.pythonhosted.org/packages/ce/cc/f7dd79274b5d22318b95e66f9a9d385e5e39e5ae7071736561823831fb0f/importable-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c9bacf3d0e9da8bc7f271937d79a93d3", "sha256": "d5348efc6746f30775c7969425a71a8ebbd5bb297400a385c5f07192c67c8ff8" }, "downloads": -1, "filename": "importable-0.1.0.tar.gz", "has_sig": false, "md5_digest": "c9bacf3d0e9da8bc7f271937d79a93d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2015, "upload_time": "2017-10-13T13:04:41", "url": "https://files.pythonhosted.org/packages/ab/0a/93fb205ad83d3ead5096d720b2e30f09a99f0f56f7da88f97e8a426ed09b/importable-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "a11041d50ea3a52e7d44ec2bd75a0ee5", "sha256": "c89d3738e26dd07a622f205a808a509cbe41f241b4f3a01f02064330f581405b" }, "downloads": -1, "filename": "importable-0.2.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "a11041d50ea3a52e7d44ec2bd75a0ee5", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4016, "upload_time": "2017-10-25T11:11:26", "url": "https://files.pythonhosted.org/packages/68/38/4c469c30badf9c57e859fc0f9f6d5e1a6cc3ecfae691bee2a4db64286143/importable-0.2.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "a5941b1a124f85e22afa8d726f73525e", "sha256": "a61e7027740e56a4e4ca111365f5003482136397e9db7c14402470097d6f6ac0" }, "downloads": -1, "filename": "importable-0.2.0.tar.gz", "has_sig": false, "md5_digest": "a5941b1a124f85e22afa8d726f73525e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2324, "upload_time": "2017-10-25T11:11:27", "url": "https://files.pythonhosted.org/packages/31/68/8211926f874acce755cab932aaab865c77544309e4abb37648869e3a3768/importable-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "36da4f798629e7a4f565cf4f77da427c", "sha256": "404df5918356e373977aefefd96c647f4b9cb1fa1cda21527974ea2b58c6ae92" }, "downloads": -1, "filename": "importable-0.2.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "36da4f798629e7a4f565cf4f77da427c", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4137, "upload_time": "2017-11-01T10:42:46", "url": "https://files.pythonhosted.org/packages/a7/38/2b5c0063c464fc9fd2d8f42f06e0610da3c263e26f76b668788115860a31/importable-0.2.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "7ccebb7f15b177dbc411fc41215ef0dd", "sha256": "6b0b8885af446a93a0f99ad32c5d2353a865218fd5f86d92a277b40f46c00848" }, "downloads": -1, "filename": "importable-0.2.1.tar.gz", "has_sig": false, "md5_digest": "7ccebb7f15b177dbc411fc41215ef0dd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2436, "upload_time": "2017-11-01T10:42:47", "url": "https://files.pythonhosted.org/packages/52/3d/2876609317d92906d5cf9a320935444608fc059d53eef5a04527f765768b/importable-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "95f39e370f87ba512bc184fbd962518b", "sha256": "d2c3aeac8ca7d06fea82b6f69f7e68d44f8e568ab74cd073a18408928854a9e6" }, "downloads": -1, "filename": "importable-0.2.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "95f39e370f87ba512bc184fbd962518b", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 6597, "upload_time": "2017-11-24T14:29:38", "url": "https://files.pythonhosted.org/packages/62/58/47a32098f98c6c57a6847dbab2771f49c78475a651103892f8ec4fd0f132/importable-0.2.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ce6081e05cd0120562bdd81100f1be56", "sha256": "ba126c273f78dfc9bcaef59902b0a232ad8cd129b7604e2e226ed968d22b6b6d" }, "downloads": -1, "filename": "importable-0.2.2.tar.gz", "has_sig": false, "md5_digest": "ce6081e05cd0120562bdd81100f1be56", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4427, "upload_time": "2017-11-24T14:30:06", "url": "https://files.pythonhosted.org/packages/ef/0f/a64c5a0537032ada7fc9518add94237929a1461814ca1c5dc4450e3f2e49/importable-0.2.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "95f39e370f87ba512bc184fbd962518b", "sha256": "d2c3aeac8ca7d06fea82b6f69f7e68d44f8e568ab74cd073a18408928854a9e6" }, "downloads": -1, "filename": "importable-0.2.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "95f39e370f87ba512bc184fbd962518b", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 6597, "upload_time": "2017-11-24T14:29:38", "url": "https://files.pythonhosted.org/packages/62/58/47a32098f98c6c57a6847dbab2771f49c78475a651103892f8ec4fd0f132/importable-0.2.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ce6081e05cd0120562bdd81100f1be56", "sha256": "ba126c273f78dfc9bcaef59902b0a232ad8cd129b7604e2e226ed968d22b6b6d" }, "downloads": -1, "filename": "importable-0.2.2.tar.gz", "has_sig": false, "md5_digest": "ce6081e05cd0120562bdd81100f1be56", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4427, "upload_time": "2017-11-24T14:30:06", "url": "https://files.pythonhosted.org/packages/ef/0f/a64c5a0537032ada7fc9518add94237929a1461814ca1c5dc4450e3f2e49/importable-0.2.2.tar.gz" } ] }