Closed Bug 762120 Opened 10 years ago Closed 10 years ago

Reftest analyser doesn't work when using baseURL to run TBPL from the local filesystem

Categories

(Tree Management Graveyard :: TBPL, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: emorley, Assigned: emorley)

References

Details

Attachments

(1 file)

1) Open js/Config.js and change the baseURL to "https://tbpl.mozilla.org/"
2) Open index.html from the TBPL repo root, via local filesystem
3) Find a reftest failure and open the reftest analyser

Expected:
Spinner then reftest analyser appears.

Actual:
"Fetching reftest log failed."

----

Example:

> data:text/html,<!DOCTYPE html><title>Loading reftest analyzer for ...<snip>
> function encode(s) { return escape(s).replace(/=/g, "%3d") }
> > NetUtils.loadText("https:\/\/tbpl.mozilla.org\/https:\/\/tbpl.mozilla.org\/php\/getLogExcerpt.php?id=12420128&type=reftest",
>                    function(log) { > window.location.replace("https://hg.mozilla.org/mozilla-central/raw-file/tip/layout/tools/reftest/reftest-analyzer.xhtml#log=" + encode(encode(log))) },
>                    function() { $("p").removeClass("loading").text("Fetching reftest log failed.") },
>                    function() { $("p").removeClass("loading").text("Fetching reftest log timed out.") });
> </script>

Caused by:
http://hg.mozilla.org/users/mstange_themasta.com/tinderboxpushlog/file/b176931d00b8/js/UserInterface.js#l1498

> 1498           'NetUtils.loadText(' + self._makeJSString(baseURL + result.reftestLogURL) + ',\n' +
> 1499           '                   function(log) { window.location.replace("https://hg.mozilla.org/mozilla-central/raw-file/tip/layout/tools/reftest/reftest-analyzer.xhtml#log=" + encode(encode(log))) },\n' +
Attached patch Patch v1Splinter Review
reftestLogURL is defined as:
> "reftestLogURL": Config.baseURL + "php/getLogExcerpt.php?id=" + run._id + '&type=reftest',

So no need to prefix it with baseURL in UserInterface.js as well.
Attachment #630622 - Flags: review?(mstange)
Attachment #630622 - Flags: review?(mstange) → review+
http://hg.mozilla.org/users/mstange_themasta.com/tinderboxpushlog/rev/1388eddadac7
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Depends on: 767522
Depends on: 768474
Product: Webtools → Tree Management
Product: Tree Management → Tree Management Graveyard
You need to log in before you can comment on or make changes to this bug.