django-downloadview icon indicating copy to clipboard operation
django-downloadview copied to clipboard

Add development backend

Open pkaczynski opened this issue 8 years ago • 2 comments

It would be nice to have feature, such as in django-sendfile, to have some kind of development backend which does not specify a backend and basically does nothing with the response.

Maybe it is possible to configure SmartDownloadMiddleware like that? SMartDownloadMiddleware checks if BACKEND and RULES are difined. My goal is to have some kind of basic settings which is extended by local settings. However, having MIDDLEWARE_CLASSES in base settings makes it impossible to extend it in local ones.

pkaczynski avatar Aug 25 '16 15:08 pkaczynski

You are right, SmartDownloadMiddleware raises error if settings.DOWNLOADVIEW_BACKEND is not set. And yes, a "development" backend would make it possible to avoid modifying MIDDLEWARE_CLASSES and just adapt DOWNLOADVIEW_BACKEND. Looks like a good idea :)

benoitbryon avatar Aug 25 '16 15:08 benoitbryon

Tagging as "medium priority" because it is not blocker. That said, it looks like a nice idea and a quite easy change.

benoitbryon avatar Aug 25 '16 15:08 benoitbryon