view.py icon indicating copy to clipboard operation
view.py copied to clipboard

More detailed error 400's

Open ZeroIntensity opened this issue 2 years ago • 2 comments
trafficstars

Right now, it just says "Bad Request". Some other information could probably be added (at least for debug mode).

ZeroIntensity avatar Sep 24 '23 14:09 ZeroIntensity

Example API, could integrate with #95

from view import new_app

app = new_app()

@app.get("/")
async def index():
    ...

@app.error(400)
@context
async def error(ctx: Context):
    ...

ZeroIntensity avatar Nov 28 '23 15:11 ZeroIntensity

Partially implemented by #137

ZeroIntensity avatar Jan 25 '24 21:01 ZeroIntensity