Bug 1169838 - job page is broken when visiting /jobs/<id>/ instead of /jobs/<id>
Summary: job page is broken when visiting /jobs/<id>/ instead of /jobs/<id>
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Beaker
Classification: Retired
Component: web UI
Version: 0.18
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: 23.0
Assignee: Dan Callaghan
QA Contact: tools-bugs
URL:
Whiteboard:
Depends On: 1263917
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-12-02 14:45 UTC by PaulB
Modified: 2018-02-06 00:41 UTC (History)
7 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-07-07 23:12:09 UTC
Embargoed:


Attachments (Terms of Use)
Beaker_BZ1169838 (115.41 KB, image/png)
2014-12-02 14:46 UTC, PaulB
no flags Details

Description PaulB 2014-12-02 14:45:08 UTC
Description of problem:
 Selecting "Show Results" in web UI displays "Internal error".

Version-Release number of selected component (if applicable):
 Beaker 0.18.4 

How reproducible:
 Unknown

Steps to Reproduce:
1. Look at the following job:
   https://beaker.engineering.redhat.com/jobs/801440/
2. Click on display results for any of the three recipes.
  
Actual results:
 See attached pic

Expected results:
 The recipe task results displayed.

Additional info:

Comment 1 PaulB 2014-12-02 14:46:40 UTC
Created attachment 963771 [details]
Beaker_BZ1169838

Comment 2 Dan Callaghan 2014-12-02 23:13:31 UTC
Paul, the problem is with the URL you are visiting. It has a trailing slash.

https://beaker.engineering.redhat.com/jobs/801440/

If you remove the trailing slash it will work:

https://beaker.engineering.redhat.com/jobs/801440

This is the same as bug 1019860. TurboGears will happily serve up the same page either with or without a trailing slash, but relative links will be broken in one case or the other. In this case it is the relative URLs for the AJAX results loading. Flask handles this better by redirecting to the trailing slash URL if appropriate.

Comment 3 Nick Coghlan 2014-12-03 08:09:46 UTC
Dan, assuming the results reporting update happens for Beaker 20, I'm guessing this will be converted to Flask at that point?

Comment 4 PaulB 2014-12-03 13:45:53 UTC
(In reply to Dan Callaghan from comment #2)
> Paul, the problem is with the URL you are visiting. It has a trailing slash.
> 
> https://beaker.engineering.redhat.com/jobs/801440/
> 
> If you remove the trailing slash it will work:
> 
> https://beaker.engineering.redhat.com/jobs/801440
> 
> This is the same as bug 1019860. TurboGears will happily serve up the same
> page either with or without a trailing slash, but relative links will be
> broken in one case or the other. In this case it is the relative URLs for
> the AJAX results loading. Flask handles this better by redirecting to the
> trailing slash URL if appropriate.

Apologies - Dan :/

Thank you for the explanation.

Best,
-pbunyan

Comment 5 Dan Callaghan 2015-11-13 04:25:26 UTC
This is "fixed" by the new job page implementation in bug 1263917, in the sense that accidentally visiting /jobs/1234/ (with trailing slash) will give you a 404 page.

Comment 8 Dan Callaghan 2016-04-07 22:37:55 UTC
(In reply to wangdong from comment #7)

Ahhh that's an unintended consequence of the user pref we put in for opting out of the new job page. We are going to need to add some code to explicitly handle this I think, since this new behaviour is even worse than the original problem described in comment 2.

Comment 9 Dan Callaghan 2016-04-18 01:59:16 UTC
http://gerrit.beaker-project.org/4814

Comment 12 Dan Callaghan 2016-07-07 23:12:09 UTC
Beaker 23.0 has been released.


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