#32891: runserver serve static files cached in debug
-------------------------------------+-------------------------------------
     Reporter:  TZanke               |                    Owner:  TZanke
         Type:  Bug                  |                   Status:  new
    Component:  contrib.staticfiles  |                  Version:  3.2
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  1                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Dan Swain):

 * status:  closed => new
 * resolution:  wontfix =>


Comment:

 I would like to revisit this issue and make a distinction between static
 assets held by the Django site vs CDN-delivered content.  Using the
 Disable cache option in the Network tab of developer tools DOES accomplish
 reloading static assets, BUT it causes ALL static assets to be reloaded
 including CDN-delivered content.  I like to set up libraries to be
 delivered via CDN, even in development mode.  Therefore, I would like to
 see runserver deliver new versions of ONLY the static assets that are
 housed in the Django project but NOT the CDN-delivered content.  This
 behavior would allow development to continue even if an Internet
 connection is interrupted since CDN-delivered content would always be
 pulled from the cache.  If this behavior is not the desired default for
 runserver (though I can't see why it wouldn't be), then perhaps a flag
 such as ''--always-refresh-static'' would be in order to trigger this
 behavior.

 Finally, I know that I could use a bundler such as Vite or Snowpack to do
 hot reloading of static files, but I'm not currently using a bundler and
 so would like to see the above-described behavior included with runserver.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/32891#comment:5>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/064.475c6d03593a6421f9f8a6c203a7a1fa%40djangoproject.com.

Reply via email to