{ "info": { "author": "Adam Brenecki", "author_email": "adam@brenecki.id.au", "bugtrack_url": null, "classifiers": [ "Development Status :: 2 - Pre-Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3 :: Only", "Topic :: Documentation :: Sphinx", "Topic :: Software Development" ], "description": "Walter\n======\n\n.. warning::\n\n Walter is pre-release software. Expect the API to change without notice, and expect this documentation to have lots of sharp edges.\n\nWalter is a configuration library, inspired by `python-decouple `_, and intended to replace direct access to ``os.environ`` in Django ``settings.py`` files (although it is by no means Django-specific). It currently supports Python 3.5+.\n\nIt differs from other, similar libraries for two reasons:\n\n- It will let you specify your configuration parameters in one place and have auto-generated Sphinx documentation, just like with Python code. (Work on this hasn't been started yet.)\n- When your users try to start up your app with invalid configuration, the error message they get shows a list of **all of the errors** with every configuration parameter, not just the first one.\n\nInstallation\n------------\n\n::\n\n pip install walter\n\nUsage\n-----\n\n::\n\n from walter.config import Config\n\n # Your configuration needs to be wrapped in a context manager,\n # so Walter can collect all the errors and display them at the end.\n with Config(\"SGC\", \"Dialer\") as config:\n\n # Read a configuration value with config.get()\n SECRET_KEY = config.get('SECRET_KEY')\n\n # Convert the returned value to something other than a string with cast.\n DEBUG = config.get('DEBUG', cast=bool)\n\n # You can pass any function that takes a string to `cast`.\n # Here, we're using a third party function to parse a database URL\n # string into a Django-compatible dictionary.\n DATABASES = {\n 'default': config.get('DATABASE_URL', cast=dj_database_url.parse),\n }\n\n # You can also make a parameter optional by giving it a default.\n RAVEN_DSN = config.get('RAVEN_DSN', default=None)\n\n # Last but not least, help_text is displayed in your Sphinx docs.\n SITE_NAME = config.get('SITE_NAME',\n help_text=\"Displayed to users in the admin\")\n\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://walterconf.readthedocs.io/", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "walter", "package_url": "https://pypi.org/project/walter/", "platform": "", "project_url": "https://pypi.org/project/walter/", "project_urls": { "Homepage": "https://walterconf.readthedocs.io/" }, "release_url": "https://pypi.org/project/walter/0.2/", "requires_dist": [ "appdirs", "attrs", "begins", "hypothesis; extra == 'dev'", "hypothesis-pytest; extra == 'dev'", "prospector; extra == 'dev'", "pytest; extra == 'dev'", "pytest-asyncio; extra == 'dev'", "sphinx (<1.6,>=1.5); extra == 'docs'", "sphinx-rtd-theme (>=0.1.9,<0.2); extra == 'docs'" ], "requires_python": "", "summary": "A better configuration library for Django and other Python projects", "version": "0.2" }, "last_serial": 3106073, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "8b99c569089e9411bbf9f4e54dd43e26", "sha256": "c3d55a4bdfef4d6830f4fca667bfab5943ec67a165490e9730d6b106e39547d4" }, "downloads": -1, "filename": "walter-0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "8b99c569089e9411bbf9f4e54dd43e26", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13360, "upload_time": "2017-08-18T10:22:13", "url": "https://files.pythonhosted.org/packages/49/d8/21d0bb15f0af7396f85289a1d037592d1577319ffff8cc0a96cefac9a544/walter-0.1-py3-none-any.whl" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "b4f600661d4d9a50d4ad10f0134c33b7", "sha256": "4236e23306f0cb7be42cf270c89808b9f91d31d09c1a1658dbdde963a4659a6c" }, "downloads": -1, "filename": "walter-0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "b4f600661d4d9a50d4ad10f0134c33b7", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13600, "upload_time": "2017-08-18T10:46:01", "url": "https://files.pythonhosted.org/packages/cf/31/360b4f1cc6a2aba658f188d88ff7ae35737a311fedf634fd4231c399074c/walter-0.2-py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b4f600661d4d9a50d4ad10f0134c33b7", "sha256": "4236e23306f0cb7be42cf270c89808b9f91d31d09c1a1658dbdde963a4659a6c" }, "downloads": -1, "filename": "walter-0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "b4f600661d4d9a50d4ad10f0134c33b7", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13600, "upload_time": "2017-08-18T10:46:01", "url": "https://files.pythonhosted.org/packages/cf/31/360b4f1cc6a2aba658f188d88ff7ae35737a311fedf634fd4231c399074c/walter-0.2-py3-none-any.whl" } ] }