Code review comment for lp:~bac/launchpad/bug-490224-content-type

Revision history for this message
Brad Crittenden (bac) wrote :

= Summary =

The mimetypes standard library in python2.5 does not know about the bzip2 encoding.
This branch provides a centralized place for extending the library so that the
encoding is recognized which will allow files to be served properly.

== Proposed fix ==

Provide a 'customizedMimetypes' method and call it from site.py.

== Pre-implementation notes ==

Long chat with Gary and talks with Curtis.

== Implementation details ==

As above.

== Tests ==

bin/test -vvt test_mime

== Demo and Q/A ==

Add a .tar.bz2 file to a download and ensure it has the proper content type when
downloading using 'wget -S'

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/lp/services/tests/test_mime.py
  lib/lp/services/mime.py
  lib/site.py
  lib/lp/bugs/model/bug.py

== Pylint notices ==

lib/lp/bugs/model/bug.py
    24: [F0401] Unable to import 'email.Utils' (No module named Utils)
    37: [F0401] Unable to import 'lazr.lifecycle.event' (No module named lifecycle)
    39: [F0401] Unable to import 'lazr.lifecycle.snapshot' (No module named lifecycle)

« Back to merge proposal