starlette-werkzeug-debugger


Namestarlette-werkzeug-debugger JSON
Version 0.2.0 PyPI version JSON
download
home_page
SummaryWerkzeug debugger middleware for Starlette
upload_time2023-09-11 12:55:03
maintainer
docs_urlNone
author
requires_python>=3.10
licenseMIT
keywords starlette debugger middleware werkzeug
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ==========================================
Werkzeug debugger middleware for Starlette
==========================================

|codecov| |version| |downloads| |license|

This package contains interactive debuger middleware for Starlette / FastAPI.

Install
-------

.. code:: bash

	pip install starlette_werkzeug_debugger

Usage with Starlette
--------------------

.. code:: python

	from starlette.applications import Starlette
	from starlette.middleware import Middleware
	from starlette.routing import Route
	import starlette_werkzeug_debugger


	async def raise_error(request):
		local_var = 3
		raise RuntimeError("Raised error")


	middleware = [
		Middleware(starlette_werkzeug_debugger.WerkzeugDebugMiddleware, evalex=True)
	]


	app = Starlette(debug=True, middleware=middleware, routes=[
		Route('/', raise_error),
	])


Usage with FastAPI
------------------

.. code:: python

	from fastapi import FastAPI
	import starlette_werkzeug_debugger


	app = FastAPI()


	app.add_middleware(starlette_werkzeug_debugger.WerkzeugDebugMiddleware, evalex=True)


	@app.get("/")
	async def raise_error():
		local_var = 3
		raise RuntimeError("Raised error")


Screenshots
-----------

.. image:: https://raw.github.com/wiki/mireq/starlette-werkzeug-debugger/debugger.png?v=2023-06-20


.. |codecov| image:: https://codecov.io/gh/mireq/starlette-werkzeug-debugger/branch/master/graph/badge.svg?token=QGY5B5X0F3
	:target: https://codecov.io/gh/mireq/starlette-werkzeug-debugger

.. |version| image:: https://badge.fury.io/py/starlette-werkzeug-debugger.svg
	:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/

.. |downloads| image:: https://img.shields.io/pypi/dw/starlette-werkzeug-debugger.svg
	:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/

.. |license| image:: https://img.shields.io/pypi/l/starlette-werkzeug-debugger.svg
	:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "starlette-werkzeug-debugger",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": "",
    "keywords": "starlette,debugger,middleware,werkzeug",
    "author": "",
    "author_email": "Miroslav Bend\u00edk <miroslav.bendik@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/24/0d/131e4e8f6e425953aca1c8f6111792f5f3a853a449059530f95999d9ef5f/starlette_werkzeug_debugger-0.2.0.tar.gz",
    "platform": null,
    "description": "==========================================\nWerkzeug debugger middleware for Starlette\n==========================================\n\n|codecov| |version| |downloads| |license|\n\nThis package contains interactive debuger middleware for Starlette / FastAPI.\n\nInstall\n-------\n\n.. code:: bash\n\n\tpip install starlette_werkzeug_debugger\n\nUsage with Starlette\n--------------------\n\n.. code:: python\n\n\tfrom starlette.applications import Starlette\n\tfrom starlette.middleware import Middleware\n\tfrom starlette.routing import Route\n\timport starlette_werkzeug_debugger\n\n\n\tasync def raise_error(request):\n\t\tlocal_var = 3\n\t\traise RuntimeError(\"Raised error\")\n\n\n\tmiddleware = [\n\t\tMiddleware(starlette_werkzeug_debugger.WerkzeugDebugMiddleware, evalex=True)\n\t]\n\n\n\tapp = Starlette(debug=True, middleware=middleware, routes=[\n\t\tRoute('/', raise_error),\n\t])\n\n\nUsage with FastAPI\n------------------\n\n.. code:: python\n\n\tfrom fastapi import FastAPI\n\timport starlette_werkzeug_debugger\n\n\n\tapp = FastAPI()\n\n\n\tapp.add_middleware(starlette_werkzeug_debugger.WerkzeugDebugMiddleware, evalex=True)\n\n\n\t@app.get(\"/\")\n\tasync def raise_error():\n\t\tlocal_var = 3\n\t\traise RuntimeError(\"Raised error\")\n\n\nScreenshots\n-----------\n\n.. image:: https://raw.github.com/wiki/mireq/starlette-werkzeug-debugger/debugger.png?v=2023-06-20\n\n\n.. |codecov| image:: https://codecov.io/gh/mireq/starlette-werkzeug-debugger/branch/master/graph/badge.svg?token=QGY5B5X0F3\n\t:target: https://codecov.io/gh/mireq/starlette-werkzeug-debugger\n\n.. |version| image:: https://badge.fury.io/py/starlette-werkzeug-debugger.svg\n\t:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/\n\n.. |downloads| image:: https://img.shields.io/pypi/dw/starlette-werkzeug-debugger.svg\n\t:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/\n\n.. |license| image:: https://img.shields.io/pypi/l/starlette-werkzeug-debugger.svg\n\t:target: https://pypi.python.org/pypi/starlette-werkzeug-debugger/\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Werkzeug debugger middleware for Starlette",
    "version": "0.2.0",
    "project_urls": {
        "changelog": "https://github.com/mireq/starlette-werkzeug-debugger/blob/master/CHANGELOG.md",
        "documentation": "https://github.com/mireq/starlette-werkzeug-debugger",
        "homepage": "https://github.com/mireq/starlette-werkzeug-debugger",
        "repository": "https://github.com/mireq/starlette-werkzeug-debugger"
    },
    "split_keywords": [
        "starlette",
        "debugger",
        "middleware",
        "werkzeug"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5d06b0a838a116ebbfe84a9db58b98953be336bc617fb595b4139883d2f0c25e",
                "md5": "d82c38991f8fdaeb654a0f63bd98ae97",
                "sha256": "7fc46b4d85c8d568b7ddcd30f4ee3cadb82054118151d12a1285b91c0fd62c29"
            },
            "downloads": -1,
            "filename": "starlette_werkzeug_debugger-0.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "d82c38991f8fdaeb654a0f63bd98ae97",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 4290,
            "upload_time": "2023-09-11T12:55:00",
            "upload_time_iso_8601": "2023-09-11T12:55:00.863971Z",
            "url": "https://files.pythonhosted.org/packages/5d/06/b0a838a116ebbfe84a9db58b98953be336bc617fb595b4139883d2f0c25e/starlette_werkzeug_debugger-0.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "240d131e4e8f6e425953aca1c8f6111792f5f3a853a449059530f95999d9ef5f",
                "md5": "808172cb8c7075e619b44cebf98c478e",
                "sha256": "f0d436dcf4509a32b752e829766bbaf53e918a093e80367626042521384322cd"
            },
            "downloads": -1,
            "filename": "starlette_werkzeug_debugger-0.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "808172cb8c7075e619b44cebf98c478e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 15660,
            "upload_time": "2023-09-11T12:55:03",
            "upload_time_iso_8601": "2023-09-11T12:55:03.253103Z",
            "url": "https://files.pythonhosted.org/packages/24/0d/131e4e8f6e425953aca1c8f6111792f5f3a853a449059530f95999d9ef5f/starlette_werkzeug_debugger-0.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-09-11 12:55:03",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mireq",
    "github_project": "starlette-werkzeug-debugger",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "starlette-werkzeug-debugger"
}
        
Elapsed time: 0.12396s