flask_injector icon indicating copy to clipboard operation
flask_injector copied to clipboard

Enhancement: Provide alias for `request` scope

Open Chratho opened this issue 5 years ago • 0 comments

The request scope name directly clashes with the global request variable in Flask. Even when using the injector-style approach and injecting flask.Request into your handlers/services, the developer might still want to use a descriptive name like request for it, raising an issue again.

Since renaming the scope would not be backwards-compatible, it would be nice if Flask-Injector could at least provide a second alias like request_scoped to avoid stuff like

from flask_injector import request as request_scoped .

Chratho avatar Feb 25 '20 20:02 Chratho