[CDash] Broken links to github.com/<organization>/<project>/pull/CHANGE_ID at cdash.org/index.php

Niels Dekker niels_dekker_address_until_2024 at xs4all.nl
Mon Apr 2 11:12:53 UTC 2018


Update: it appears to me that these GitHub pull request links at CDash 
index.php are broken, because CDash strips "https://" from the GitHub 
URLs.

Is this a known issue? Do you have a workaround?

More details:

CDash produces the following HTML code, for a pull request at 
http://trunk.cdash.org/index.php?project=SuperElastix&date=2018-03-30

     <a target="_blank" 
ng-href="github.com/SuperElastix/SuperElastix/pull/183" 
href="github.com/SuperElastix/SuperElastix/pull/183">
       <img class="smallicon" ng-src="img/Octocat.png" 
src="img/Octocat.png">
     </a>

Web browsers assume that the GitHub URL at href="..." is a relative 
path, because it does not start with "http[s]://". So there is where the 
link gets broken.

I observed the "https://" being stripped as follows:

  - I went to http://trunk.cdash.org/index.php?project=SuperElastix
  - Logged in
  - Opened "Edit Project" page (createProject.php), from the Settings 
menu.
  - Went to Repository tab page.
  - Entered "https://github.com/SuperElastix/SuperElastix" at "Repository 
Viewer URL:"
  - Clicked the "Update Project" button, and then, "https://" was gone!

I guess this stripping is done by stripHTTP($url), at:
   
https://github.com/Kitware/CDash/blob/d46d9e06dc83d577aacecfa4b95a3613bcbca1a6/public/api/v1/project.php#L214

The GitHub URL that is stripped is internally referred to as 
'cdash.project.CvsUrl'

Hope you can help me to get it fixed! (A workaround would be nice as 
well.)

   Kind regards, Niels


-------- Original Message --------
Date: 2018-03-30 20:25

I just experienced this really cool feature that when CTEST_CHANGE_ID is 
set for a specific build, a little GitHub icon appears at the index.php, 
in the table entry of the Build Name, for that particular build. For the 
SuperElastix project that I am involved with, at:

   http://trunk.cdash.org/index.php?project=SuperElastix&date=2018-03-30

I guess the GitHub icon should link to the GitHub pull request, 
https://github.com/<organization>/<project>/pull/<CHANGE_ID>, and that 
would be wonderful.

Unfortunately the GitHub links are broken, at the cdash.org/index.php 
page of our project, as they points to:

   http://trunk.cdash.org/github.com/SuperElastix/SuperElastix/pull/183

Which says: "The requested URL 
/github.com/SuperElastix/SuperElastix/pull/183 was not found on this 
server"

I saw the same problem here:

   https://open.cdash.org/index.php?project=Fletch&date=2018-03-30

Which has GitHub icons linking to:

   https://open.cdash.org/github.com/kitware/fletch/pull/354

Do we do something wrong in our CDash project settings, or is it a bug?

Kind regards, Niels
-- 
Niels Dekker
Scientific programmer
LKEB, Leiden University Medical Center



More information about the CDash mailing list