You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implemented in v2.0 (#754): return a (data, status) tuple from the handler, e.g. return {"id": new_id}, 201. A ready web.json_response(...) / StreamResponse is also passed through untouched if you need full control.
Activity
dchaplinsky commentedon Mar 12, 2019
Are you sure that the problem is with library? I think normal aiohttp way should work just fine.
What you've tried already?
alvassin commentedon Mar 12, 2019
Normally, i return Response with some body, custom headers, custom status.
With aiohttp-validate decorator i have to return directly only body. There is no way to define http status or headers.
See: https://github.com/dchaplinsky/aiohttp_validate/blob/master/aiohttp_validate/__init__.py#L138
dchaplinsky commentedon Mar 12, 2019
Yes, you are right. Well, cannot say I have too much time on this project now.
Happy to review PR as long as it'll keep backward compatibility.
alvassin commentedon Mar 12, 2019
Okay, asked just in case if you have workaround :)
dchaplinsky commentedon Jul 19, 2026
Implemented in v2.0 (#754): return a
(data, status)tuple from the handler, e.g.return {"id": new_id}, 201. A readyweb.json_response(...)/StreamResponseis also passed through untouched if you need full control.Generated by Claude Code