parameters: (self)
docstring: Run cleanup code. (Core)
docstring_summary: Run cleanup code. (Core)
docstring_tokens: Run cleanup code . ( Core )
function: def close(self):
          """Run cleanup code. (Core)"""
          if not self.closed:
              self.closed = True
              self.stage = 'on_end_request'
              self.hooks.run('on_end_request')
              self.stage = 'close'
function_tokens: def close ( self ) : if not self . closed : self . closed = True self . stage = 'on_end_request' self . hooks . run ( 'on_end_request' ) self . stage = 'close'