Closed Bug 503797 Opened 15 years ago Closed 15 years ago

Crash report pages are not well-formed; need escaped ampersand in "Get Help" URL and has an extra </div>

Categories

(Socorro :: General, task)

task
Not set
major

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: davemgarrett, Unassigned)

References

Details

http://crash-stats.mozilla.com/report/index/6fca5dcc-14c0-46a4-b7a0-b630d2090712
http://validator.w3.org/check?uri=http%3A%2F%2Fcrash-stats.mozilla.com%2Freport%2Findex%2F6fca5dcc-14c0-46a4-b7a0-b630d2090712&charset=%28detect+automatically%29&doctype=Inline&group=0

Thanks for the addition of the "Get Help" link on the crash pages. However, its URL has an unescaped ampersand in need of an "&amp;". The hrefs for the cvsblame links are all properly escaped, so it's just this one link that should need changing for this.

The reason I care is that the addition of this is causing an error on parsing in my extension, Crash Report Helper:
https://addons.mozilla.org/en-US/firefox/addon/11217

Of course I could probably find a way to work around this, but it should be escaped so if someone would be so kind as to escape this one little character things should work again.
We'll try to get this fixed with the next release. Sorry about that.
Fixed in r1245. Will ship in next release (in next week).
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
(In reply to comment #2)
> Fixed in r1245. Will ship in next release (in next week).

Thanks! Wrong revision number though. ;)

Just occurred to me that this would also come up with any signatures with references in them. Whole thing needs escaping if it isn't already.
Nevermind. Just learned that Bugzilla mis-linkifies it and it's on another SVN. Everything's escaped; thanks again.
Austin: The validation is also complaining about an tag closing.

Line 2731, Column 14: end tag for element "div" which is not open
        </div> <!-- /PAGE -->
Line 2731, Column 14: XML Parsing Error: Opening and ending tag mismatch: body line 44 and div
        </div> <!-- /PAGE -->
Line 2744, Column 11: XML Parsing Error: Opening and ending tag mismatch: html line 2 and body
    </body>

I'm not sure exactly which one it's complaining about but it should probably get fixed too to get this thing error free.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Ah, there are two "</div><!-- /details -->" for some reason. I think one needs removal.
Austin: Yeah, the other error breaks things still. (Do I need to file another bug for this other one? The link in comment 0 listed both errors.)
Summary: Crash report pages fail validation; need escaped ampersand in "Get Help" URL → Crash report pages fail validation; need escaped ampersand in "Get Help" URL and has an extra </div>
Summary: Crash report pages fail validation; need escaped ampersand in "Get Help" URL and has an extra </div> → Crash report pages are not well-formed; need escaped ampersand in "Get Help" URL and has an extra </div>
Actually, now I think it's complaining about two stray </div> and possibly a </ul>, which wasn't in the validation output with the old version. It may have gotten worse.

(I really want to smack the parser used for XMLHttpRequest.responseXML. Its over-strictness is what's killing Crash Report Helper. Apparently even the most minor of errors causes it to explode.)
You could parse .responseText yourself, but parsing that would be difficult without a patch for bug 102699.
(In reply to comment #8)
Sorry about that. I'll get this fixed ASAP. No need for another bug.
(In reply to comment #10)
Not to suggest that you rewrite your code, but FYI all crashes include a link to the JSON formatted gzip compressed file.

http://crash-stats.mozilla.com/dumps/{uuid}.jsonz

So for
http://crash-stats.mozilla.com/report/index/6fca5dcc-14c0-46a4-b7a0-b630d2090712
you can retrieve
http://crash-stats.mozilla.com/dumps/6fca5dcc-14c0-46a4-b7a0-b630d2090712.jsonz

We've all so shipped RSS feeds with this release. Those two formats should be more robust. I think this was a merge issue, and I didn't catch it on stage.
@Jesse: Yes, I was considering exactly that.

@Austin: Thanks.

As to the JSON, I know about bug 412477. It makes getting at the signature potentially much simpler, but it doesn't really provide a better alternative to the full page for getting the crashing thread modules. The former is what I need for about:crashes signature listing and the later is what I need to analyze things and identify the crashing plugin or extension (if possible). The current JSON implementation just has the dump in a single text blob so I'd have to parse it myself to get at that information. Of course I could do that but I'd rather take the information from the server which has already been reliably parsed. (is there a doc somewhere on this dump format?) For the moment, things should work fine so long as the crash page is error-free, but I'd I might like to get some additional JSON or XML access at some point in the future.
The facepalm cycle has completed.
Status: REOPENED → RESOLVED
Closed: 15 years ago15 years ago
Resolution: --- → FIXED
Crash Reporter Helper works now :)  Tested in Firefox 3.5.
Dave: there aren't any docs on the raw dump format, but it's not terribly complicated. Feel free to ping me offline about it if you're interested.
"This document was successfully checked as XHTML 1.0 Strict!" :)

They don't call it strict for nothing. Thank you very much for the fixes. Everything works perfectly again.

Ted: Thanks for the offer. I'll take a look at it in a bit. Will probably be simpler overall than getting more JSON for all the info, seeing as I only need one portion.
Status: RESOLVED → VERIFIED
Component: Socorro → General
Product: Webtools → Socorro
You need to log in before you can comment on or make changes to this bug.