python-web-sig / wsgi-ng

Working group for wsgi-ng
39 stars 3 forks source link

call it `request`, not `environ` #17

Open chadwhitacre opened 9 years ago

chadwhitacre commented 9 years ago

And make it a (low-level but) true Request object. We're not looking for "one true request," but rather, "requests all the way down." The WSGI NG request object should be pretty basic, and should be designed to support an ecosystem of more advanced request objects at the framework layer.

For comparison, consider Node: they have a core IncomingMessage prototype that gets passed to http.Server callbacks as request, and then frameworks wrap that in their own request or req objects: Express, Sails (wraps Express, actually), Total, Koa. Fundamentally, though, every framework is using the same request object at bottom.

In a sense WSGI's environ has been our base request object. Let's start calling it that, and design it as such.

Reticketed from #13.