equal
deleted
inserted
replaced
1 # copyright 2003-2010 LOGILAB S.A. (Paris, FRANCE), all rights reserved. |
1 # copyright 2003-2011 LOGILAB S.A. (Paris, FRANCE), all rights reserved. |
2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr |
2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr |
3 # |
3 # |
4 # This file is part of CubicWeb. |
4 # This file is part of CubicWeb. |
5 # |
5 # |
6 # CubicWeb is free software: you can redistribute it and/or modify it under the |
6 # CubicWeb is free software: you can redistribute it and/or modify it under the |
172 else: |
172 else: |
173 view_func = self.call |
173 view_func = self.call |
174 stream = self.set_stream(w) |
174 stream = self.set_stream(w) |
175 try: |
175 try: |
176 view_func(**context) |
176 view_func(**context) |
177 except: |
177 except Exception: |
178 self.debug('view call %s failed (context=%s)', view_func, context) |
178 self.debug('view call %s failed (context=%s)', view_func, context) |
179 raise |
179 raise |
180 # return stream content if we have created it |
180 # return stream content if we have created it |
181 if stream is not None: |
181 if stream is not None: |
182 return self._stream.getvalue() |
182 return self._stream.getvalue() |