Always query the static storage for paths, and remove media serials.

Review Request #2962 — Created March 15, 2012 and submitted

Information

Review Board
master

Reviewers

Always query the static storage for paths, and remove media serials.

We now always go through the static storage module (using the static()
templatetag) to get the path to a media file. This will allow us to get
versioning as part of the filename for free. Since we now have
versioning, we can nuke usage of MEDIA_SERIAL.

JavaScript no longer tries to build up static media paths itself. Now it
uses this STATIC_URLS dictionary that maps known media files to paths.
Later, once we have a sprite image, we should be able to remove even
this.

We do still generate cache serials at startup, though, since we use
AJAX_SERIAL in places. However, we no longer scan the media files at
all, only templates, meaning we get a small performance boost.
Played around with the UI. I didn't see any problems.

Verified that the paths we were generating for JavaScript were correct.

Unit tests pass, but these are mostly template changes, so no big surprise
there.
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to master (49f2f48)
Loading...