HeadMiddleware breaks HTTP redirects

Bug #758618 reported by John A Meinel on 2011-04-12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
John A Meinel

Bug Description

I don't really know why this is happening, but in the latest loggerhead trunk, if I do "bzr serve --http", then go browse to "/" which usually redirects to "/changes", I get a traceback in the terminal. If I change the line:

=== modified file '__init__.py'
--- __init__.py 2011-03-19 08:35:57 +0000
+++ __init__.py 2011-04-11 19:36:51 +0000
@@ -86,7 +86,7 @@
         config = LoggerheadConfig(argv)
         setup_logging(config, init_logging=False, log_file=sys.stderr)
         app = BranchesFromTransportRoot(transport.base, config)
- app = HeadMiddleware(app)
+ # app = HeadMiddleware(app)
         app = HTTPExceptionHandler(app)
         serve(app, host=host, port=port)

Then my web browser redirects as expected.

This doesn't affect Launchpad, since it uses its own Application stack that doesn't include HeadMiddleware.

Related branches

Martin Pool (mbp) on 2011-04-13
Changed in loggerhead:
assignee: nobody → John A Meinel (jameinel)
status: Triaged → In Progress
John A Meinel (jameinel) wrote :

landed in trunk

Changed in loggerhead:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers