Bug 255682

Summary: autolink: Short Git commit references are sometimes converted to SVNWeb links
Product: Services Reporter: Jan Beich <jbeich>
Component: Bug TrackerAssignee: Bugmeister <bugmeister>
Status: Closed Unable to Reproduce    
Severity: Affects Some People CC: gonzo, jcfyecrayz, pi, williamsdanielusa
Priority: --- Keywords: needs-qa
Version: unspecified   
Hardware: Any   
OS: Any   
See Also: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=261686
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=258786

Description Jan Beich freebsd_committer freebsd_triage 2021-05-07 14:15:04 UTC
Some Git commits may start with decimal digits and not contain any obviously hexadecimal digits like [a-f]. For example, in bug 255679 comment 2 I've pasted "ports <12-digit abbreviation>" but Bugzilla automatically appended "r" then linked to https://svnweb.freebsd.org/.

Let's test more:
- ports 111198 (exists in both SVN and Git)
- ports 123456789012 (doesn't exist, too large for SVN)
Comment 1 Oleksandr Tymoshenko freebsd_committer freebsd_triage 2021-05-08 02:34:16 UTC
I changed the priorities for links regexp. If it's a hexadecimal number 6 to 40 characters long - consider it a git revision, only numbers - SVN. There is still an overlap between SVN And git commits, like in your example, but there is no clear way to resolve it without querying repos I'm afraid.
Comment 2 Daniel Williams 2022-11-04 05:03:45 UTC
MARKED AS SPAM
Comment 3 John Hein 2022-11-23 22:15:10 UTC
It seems to me that ports commit autolinks are currently not working at all.

For instance, the commit hash in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=266470#c2 did not get converted to a link.
Comment 4 Graham Perrin freebsd_committer freebsd_triage 2022-11-24 02:23:33 UTC
(In reply to John Hein from comment #3)

> in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=266470#c2 

Testing: ports 27b5e1775e9d0732f5d4d5ba802179008992fcce

ports 27b5e1775e9d0732f5d4d5ba802179008992fcce

 (ports 27b5e1775e9d0732f5d4d5ba802179008992fcce) 

(ports 27b5e1775e9d0732f5d4d5ba802179008992fcce)

 (ports 27b5e1775e9d0732f5d4d5ba802179008992fcce ) 

 ( ports 27b5e1775e9d0732f5d4d5ba802179008992fcce )
Comment 5 Mark Linimon freebsd_committer freebsd_triage 2023-12-25 16:56:04 UTC
^Triage: re-assign to bugmeister.
Comment 6 Mark Linimon freebsd_committer freebsd_triage 2024-01-14 07:13:34 UTC
^Triage: I don't know of a way to replicate this problem ATM.