Code review comment for lp:~gary/launchpad/launchpad-templates-3

Revision history for this message
Gary Poster (gary) wrote :

This branch removes seven templates, and changes 6 to match 3.0.

These files are removed. The majority of the diff consists of these. bigjools identified sourcepackagerelease-body-summary.pt as one that could be removed. I identified the other six by looking through .py files and .zcml files to try to find any usage. I did not find any usage, and salgado confirmed that I could remove them.

  lib/canonical/launchpad/templates/default-editform.pt
  lib/canonical/launchpad/templates/message-add.pt
  lib/canonical/launchpad/templates/sourcepackagerelease-body-summary.pt
  lib/canonical/launchpad/templates/template-addform.pt
  lib/canonical/launchpad/templates/template-editform.pt
  lib/canonical/launchpad/templates/template-form.pt
  lib/canonical/launchpad/templates/template-page.pt

Most of the six template modifications have an exception of one sort or another that I'll mention below. This one is fairly normal though.

  lib/canonical/launchpad/templates/notification-test.pt

To test, log in as an admin (<email address hidden>:test) and look at launchpad.dev/+notificationtest1, launchpad.dev/+notificationtest2, launchpad.dev/+notificationtest3, and launchpad.dev/+notificationtest4. I'm not sure why the last three redirect and did not investigate, but the behavior before and after my change seems the same.

These two are only used for their macros.

  lib/canonical/launchpad/templates/launchpad-addform.pt
  lib/canonical/launchpad/templates/launchpad-editform.pt

These two templates use the add form:

./lib/lp/registry/templates/signedcodeofconduct-acknowledge.pt:11: <div metal:use-macro="context/@@launchpad_addform/addform"/>
./lib/lp/blueprints/templates/specification-requestfeedback.pt:23: <div metal:use-macro="context/@@launchpad_addform/addform">

These two use the edit form:

./lib/lp/registry/templates/signedcodeofconduct-activate.pt:11: <div metal:use-macro="context/@@launchpad_editform/editform"/>
./lib/lp/registry/templates/signedcodeofconduct-deactivate.pt:11: <div metal:use-macro="context/@@launchpad_editform/editform"/>

The macros these use (addform and editform, respectively) do not actually include the <html> tag of the launchpad-addform.pt and launchpad-editform.pt templates, so the change I made to these templates is really only for statistics: changing it to 3.0 does not affect anything.

Finally, these three templates are all for bugs: hwdb functionality.

  lib/canonical/launchpad/templates/hwdb-fingerprint-submissions.pt
  lib/canonical/launchpad/templates/hwdb-submit-hardware-data.pt
  lib/canonical/launchpad/templates/person-hwdb-submissions.pt

I didn't know how to view these, and at least one of them appears to be for machine usage, and deryck didn't know how to view them either, so rather than digging into the code to figure out what was going on so I could see the pages, I opted to make the mechanical changes.

Thank you!

Gary

« Back to merge proposal