Bug 674025 - [RFE] Always show task specified by anchor
Summary: [RFE] Always show task specified by anchor
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Beaker
Classification: Retired
Component: web UI
Version: 0.6
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: 0.10.0
Assignee: Amit Saha
QA Contact:
URL:
Whiteboard: UX
Depends On:
Blocks: 545868
TreeView+ depends on / blocked
 
Reported: 2011-01-31 11:30 UTC by Šimon Lukašík
Modified: 2018-02-06 00:41 UTC (History)
6 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2012-11-22 06:44:37 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 872094 0 unspecified CLOSED avoid using cookies to store visible state of recipe results on recipe/job page 2021-02-22 00:41:40 UTC

Internal Links: 872094

Description Šimon Lukašík 2011-01-31 11:30:13 UTC
Description of problem:
On Beaker webui we can determinate particular test run by url like:

    http://fqdn/recipes/$recipe_id/task$task_id

For instance:

    https://beaker.engineering.redhat.com/recipes/100990#task1112067

Unfortunately such #task anchor is working only when tasks drop-down
list is expanded. In case it's not expanded you won't be navigated to
specified task.

User is forced to click on "Show All results" button and then reload
a page.

Is it possible to show requested task, no matter of expanded/not expanded?

Comment 1 Dan Callaghan 2011-01-31 20:59:35 UTC
I imagine we could add some onload js which looks for a #task1234 anchor and expands the results if one is present.

Comment 2 Amit Saha 2012-10-25 06:30:17 UTC
A cookie (unique to the Recipe) is being set when "Show All Results" is clicked. And hence, all subsequent visits to this page goes to the particular task referred to the by the #taskid. However, once the "Hide Results" is clicked, the cookie is forgotten and hence the next reference to the #taskid doesn't show the specific task.

I am going to think, how we can work around this.

Comment 3 Dan Callaghan 2012-10-25 06:38:57 UTC
If an anchor is present (check window.location.hash) can we just ignore the cookie, and always display the relevant results?

I guess the problem is we won't know which recipe's results has the task ID we want...

Comment 4 Amit Saha 2012-10-26 01:32:30 UTC
Yeah, so if an anchor is present, we simply display the results, even if the cookie is not present. 

Your second problem is not a problem, because from what it seems like the result is already on the client side -- its a matter of hiding/displaying it, which the cookie controls -- with its values ('all','fail') if present, else its absence.

I gerrit: http://gerrit.beaker-project.org/#/c/1443/

Comment 5 Raymond Mancy 2012-10-29 00:25:15 UTC
Amit, (In reply to comment #4)
> Yeah, so if an anchor is present, we simply display the results, even if the
> cookie is not present. 
> 
> Your second problem is not a problem, because from what it seems like the
> result is already on the client side -- its a matter of hiding/displaying
> it, which the cookie controls -- with its values ('all','fail') if present,
> else its absence.
> 

Is that right? IIRC this _was_ the default behaviour but we had to change it due to slow loading times of result pages due to task results having to be loaded (regardless of whether the user wanted to view them). I thought we had changed it to load only on clicking 'Show X results'.

> I gerrit: http://gerrit.beaker-project.org/#/c/1443/

Comment 6 Amit Saha 2012-10-30 02:14:11 UTC
(In reply to comment #5)
> Amit, (In reply to comment #4)
> > Yeah, so if an anchor is present, we simply display the results, even if the
> > cookie is not present. 
> > 
> > Your second problem is not a problem, because from what it seems like the
> > result is already on the client side -- its a matter of hiding/displaying
> > it, which the cookie controls -- with its values ('all','fail') if present,
> > else its absence.
> > 
> 
> Is that right? IIRC this _was_ the default behaviour but we had to change it
> due to slow loading times of result pages due to task results having to be
> loaded (regardless of whether the user wanted to view them). I thought we
> had changed it to load only on clicking 'Show X results'.

You are right. The results are loaded by issuing a remoteRequest() on the specific recipe.

Comment 7 Amit Saha 2012-10-31 08:21:08 UTC
In Gerrit: http://gerrit.beaker-project.org/1443

Comment 10 Raymond Mancy 2012-11-22 06:44:37 UTC
This has now been released


Note You need to log in before you can comment on or make changes to this bug.