Created attachment 8564309 [details] Screenshot 2015-02-13 11.52.21.png it should linkify all bug mentions in the comments
This is pretty surprising behavior, esp. since the last bug number is often not clickable at all, because it's not shown within the fairly narrow space we have for the commit message.
Bug 1081041 should have done something similar to: https://hg.mozilla.org/webtools/tbpl/file/547a7de112ac/js/UserInterface.js#l777 (well, not as unreadably as TBPL, but still) Jonathan, interest in taking this? :-)
Priority: P3 → P2
Sure, will have a go.
Assignee: nobody → tojonmz
Status: NEW → ASSIGNED
(In reply to Ed Morley [:edmorley] from comment #2) > Bug 1081041 should have done something similar to: > https://hg.mozilla.org/webtools/tbpl/file/547a7de112ac/js/UserInterface. > js#l777 > (well, not as unreadably as TBPL, but still) Or at least wrap the logic in <https://github.com/mozilla/treeherder-ui/pull/351/files#diff-7d56811a875af3d6e14e635462174245R43> in a |while (bug_matches || pr_matches)| loop...
Thanks Ehsan, sorry I didn't get to this yet, I had other Treeherder bugs in front of this in my queue. I'm out for a bit tomorrow, but back all day Friday. If it's urgent feel free to reassign if needed.
I have a local wip that linkifies correctly using the offending string, I just need to sort out the most efficient way to construct a new bug_match list using the current .exec(str) regex.
It looks like there's issues in the way we generate the titles also. If you hover on a linked bug in a 'multi-bug' summary line, all linkified bugs will inherit the parent span title, and so will be wrong on all but 1 of the links.
I think I have all the possible matches covered, multiple bug numbers with different prefixes, repeated bug numbers, PRs, combinations of bug numbers and PR's, etc. I still have to sort the title injection to override the overall span title, mentioned in comment 8.
I spoke too soon. More failure cases to sort out, and may have to look at another way of building the array.
Created attachment 8580216 [details] [review] treeherder-ui-PR#430 Please see above PR for status and review. Wlach, if/when it's an r+, if you can give it some brief local testing, that would be awesome :)
Attachment #8580216 - Flags: review?(wlachance)
Comment on attachment 8580216 [details] [review] treeherder-ui-PR#430 Some debugging code left in unintentionally, plus some minor adjustments needed.
Attachment #8580216 - Flags: review?(wlachance) → review-
Yup, I had just left them in for PR testing :) I've pulled them and made the other corrections.
Attachment #8580216 - Flags: review- → review?
Attachment #8580216 - Flags: review? → review?(wlachance)
Attachment #8580216 - Flags: review?(wlachance) → review+
Commits pushed to master at https://github.com/mozilla/treeherder-ui https://github.com/mozilla/treeherder-ui/commit/a66933c8defeccbf7fa2ad9528568cc6ab7847ba Bug 1133021 - Linkify all bugs and prs in revision commit messages https://github.com/mozilla/treeherder-ui/commit/7b418c30ea3b591602a0083a3a71f2dd4553efa0 Merge pull request #430 from tojonmz/commit-msg-links Bug 1133021 - Linkify all bugs and prs in revision commit messages
Marking fixed per above merge. I'll verify on the next push to stage/prod.
Status: ASSIGNED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
Verified fixed on stage. It will be live on the next push to production. Per comment 8 above, to expedite the fix and avoid unknowns with bmo and github api's we inject a proxy title on all blue linkified issues (PRs, Bugs) with "github.com" and "bugzilla.mozilla.org", rather than what we had before, which was nothing and only incidentally worked if the commit message happened to match the Bug summary or PR title. I will open a follow up for possible title injection. If folks prefer as-is we can mark that new bug wont fix, or we can keep it open in case there's a way to access the titles with no performance cost.
Status: RESOLVED → VERIFIED
Commits pushed to master at https://github.com/mozilla/treeherder https://github.com/mozilla/treeherder/commit/fd6f811019a926521f67f9ce0ac6eca4c99c512b Bug 1133021 - Linkify all bugs and prs in revision commit messages https://github.com/mozilla/treeherder/commit/5e23d58e854f8e623b00b414f4109145445c1549 Merge pull request #430 from tojonmz/commit-msg-links Bug 1133021 - Linkify all bugs and prs in revision commit messages
You need to log in before you can comment on or make changes to this bug.