yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #59576
[Bug 1595095] Re: Horizon tabbed view returns rendered read-only response
Reviewed: https://review.openstack.org/333345
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=019e5490fbd8475483e9f33a74e127522426bec6
Submitter: Jenkins
Branch: master
commit 019e5490fbd8475483e9f33a74e127522426bec6
Author: Timur Sufiev <tsufiev@xxxxxxxxx>
Date: Mon Dec 5 21:05:06 2016 +0300
Remove additional response.render() for tabs
Right now TabbedView has additional .render() call. Thus
get_context_data() for TabbedView returns already rendered response
with rendered=True flag, which makes it read-only. This blocks
Profiler middleware in modifying the response. For example, we cannot
add any messages to response from tabbed view.
Simple views have no additional rendering. It was done because of
issues with raising redirect exceptions from tabbed views long
ago. Looks like now there is no such issues and raising redirects from
tabbed views is covered with unit tests. To ensure that nothing broke,
a test with a tab raising Http302 was added - it still redirects to
the url provided as before.
Change-Id: I37076abc15008a523f37da0d09b5b041ef77844e
Closes-Bug: #1595095
** Changed in: horizon
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1595095
Title:
Horizon tabbed view returns rendered read-only response
Status in OpenStack Dashboard (Horizon):
Fix Released
Bug description:
Horizon tabbed view returns rendered read-only response. It happens because of this string: https://github.com/openstack/horizon/blob/master/horizon/tabs/views.py#L81
And for simple view we do not call additional response: https://github.com/openstack/horizon/blob/master/horizon/views.py#L65
Described tabs view behaviour makes impossible to modify response via
middleware. For example, we cannot add messages from middleware
despite the fact we can do it if we handing simple view request.
To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1595095/+subscriptions
References