Opened 8 years ago

Closed 8 years ago

#5772 closed (fixed)

GzipMiddleware compresses JavaScript by accident

Reported by: Simon Law <simon@…> Owned by: nobody
Component: Core (Other) Version: master
Severity: Keywords: gzip middleware javascript
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


A small typo in GZipMiddleware causes it to compress files of Content-Type: */javascript, even though it shouldn't.

I've attached a patch that should fix this problem.

Attachments (1)

django-gzip.patch (558 bytes) - added by Simon Law <simon@…> 8 years ago.

Download all attachments as: .zip

Change History (6)

Changed 8 years ago by Simon Law <simon@…>


comment:1 Changed 8 years ago by durdinator

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Ready for checkin

Looks good from here.

comment:2 Changed 8 years ago by ramiro

See also #5754.

comment:3 Changed 8 years ago by mboersma

Doesn't this conflict with #5313? They're both in the "Ready for checkin" stage yet seem to be at cross purposes.

comment:4 Changed 8 years ago by Simon Law <simon@…>

I'm more than happy if you apply the patch in #5772, before clobbering it with #5313.

comment:5 Changed 8 years ago by mtredinnick

  • Resolution set to fixed
  • Status changed from new to closed

(In [6537]) Changed HttpResponse.get() to lower case the header value before looking it up. This makes it consistent will other header accesses. Fixed #5754, #5772.

Note: See TracTickets for help on using tickets.
Back to Top