comparison MoinMoin/wsgiapp.py @ 4751:09c345615cd8

Put the finish method back on the context object so we can delay process such as thread joined until the end
author Andy Dawkins <andydawkins@gmail.com>
date Fri, 03 Jul 2009 15:17:23 +0100
parents edb6cb2cac43
children 5db0151a2df3
comparison
equal deleted inserted replaced
4750:617c9c236bf0 4751:09c345615cd8
36 36
37 context.user = setup_user(context, context.session) 37 context.user = setup_user(context, context.session)
38 38
39 context.lang = setup_i18n_postauth(context) 39 context.lang = setup_i18n_postauth(context)
40 40
41 def finish():
42 pass
43
44 context.finish = finish
45
41 context.reset() 46 context.reset()
42 47
43 context.clock.stop('init') 48 context.clock.stop('init')
44 return context 49 return context
45 50
66 context.cfg.session_service.finalize(context, context.session) 71 context.cfg.session_service.finalize(context, context.session)
67 return response 72 return response
68 except MoinMoinFinish: 73 except MoinMoinFinish:
69 return request 74 return request
70 finally: 75 finally:
76 context.finish()
71 context.clock.stop('run') 77 context.clock.stop('run')
72 78
73 def remove_prefix(path, prefix=None): 79 def remove_prefix(path, prefix=None):
74 """ Remove an url prefix from the path info and return shortened path. """ 80 """ Remove an url prefix from the path info and return shortened path. """
75 # we can have all action URLs like this: /action/ActionName/PageName?action=ActionName&... 81 # we can have all action URLs like this: /action/ActionName/PageName?action=ActionName&...