Open CaselIT opened 4 years ago
Hi @G-Sheridan ! And thanks for sharing. Sounds like a cool AI/DL project to tinker with!
That being said, I'm afraid this issue falls into the remaining gap towards 1.00 AUC, and towards artificial general intelligence.
Despite a really well written description by @CaselIT, it feels like an open ended issue requiring a principal architectural decision on how we want to organize the core parts of the framework. Maybe when these decisions are made and documented, it could be a relatively easy issue, but I still think we could find more fitting stuff to onboard newcomers. We actually do happen to have 12 issues labeled as such :slightly_smiling_face:
Response has a series of utility methods for setting complex headers, like
Set-Cookie
orLink
.It would be nice to have a similar ability also in the
HttpStatus
and in theHttpError
.While ideally the interface could be duplicated/shared in a common superclass, I think that most of the benefits could be achieved by making the
_wsgi_headers
and_asgi_headers
public and setting the headers of theHttpStatus
/HttpError
to that value. https://github.com/falconry/falcon/blob/113eea113844058816ed745d8dc9cb197e75cb95/falcon/response.py#L1049 https://github.com/falconry/falcon/blob/113eea113844058816ed745d8dc9cb197e75cb95/falcon/asgi/response.py#L390