--
You received this message because you are subscribed to the Google Groups "Django developers" group.
To post to this group, send email to django-d...@googlegroups.com.
To unsubscribe from this group, send email to django-develop...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.
> I track trunk while developing new projects, and I just picked up the
> new contrib.staticfiles app. I was disappointed how repetitive and
> redundant the configuration is. I already have MEDIA_ROOT and
> MEDIA_URL defined, so now I have to add
>
> STATICFILES_ROOT = MEDIA_ROOT
> STATICFILES_URL = MEDIA_URL
> STATICFILES_DIRS = (STATICFILES_ROOT,)
Please refer to the documentation for a description of those settings.
> just to get things back working like before. What is the purpose of
> having both MEDIA_* *and* STATICFILES_* settings? Don't they mean the
> same thing? If there's a good reason to have all these settings, can
> we not have the settings I had to enter above as defaults, similar to
> how MANAGERS = ADMINS by default?
No, MEDIA_* and STATICFILES_* settings aren't the same, the former is for user generated content (like file uploads), the latter for general static files your site needs to work (such as css/js files). The distinction is also well described in the dev documentation.
Jannis
> On Nov 3, 4:12 am, Jannis Leidel <jan...@leidel.info> wrote:
>>
>> No, MEDIA_* and STATICFILES_* settings aren't the same, the former is for user generated content (like file uploads), the latter for general static files your site needs to work (such as css/js files). The distinction is also well described in the dev documentation.
>
> Where is this distinction in the docs? I read over the staticfiles
> documentation trying to figure out how it related to MEDIA_* and it
> was not clear to me. I think the docs need some improving to explain
> the purpose of this app and the problem it is trying to solve
> (separation of user uploaded media and app media). It just kind of
> landed in trunk. It wasn't obvious to me, for example, that the dev
> server would continue to serve media in MEDIA_ROOT or if I had to add
> MEDIA_ROOT to STATICFILES_DIRS and enable the FileSystemFinder. I
> realize it might be too early for release notes, but that would be
> helpful for me at least.
Ok, thanks for your input, would you mind creating a ticket describing the discrepancy in more detail? I thought the how to [1] explains enough of purpose of the app, so any further input would be much appreciated.
> I'd be glad to help, but I'm still trying to figure it out. I'll try
> to write a blog post or a doc patch.
If you could specify what can't be understood it'd be easier to extend the docs, indeed.
Jannis