[Tracker-discuss] [issue610] Hyperlink git hashes of 10 or 11 characters

2016-12-22 Thread Ezio Melotti

Ezio Melotti added the comment:

I'm +0.5 on the prefix idea -- by default it should work without prefix (both 
for backward compatibility and because most people will copy/paste CSIDs 
without bothering adding the prefix).  It could be still useful in case people 
want to explicitly disambiguate or to be used by bots though.
A few tests should be added in test_local_replace.py, otherwise the patch LGTM.

___
PSF Meta Tracker 

___
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/


[Tracker-discuss] [issue610] Hyperlink git hashes of 10 or 11 characters

2016-12-22 Thread Maciej Szulik

Maciej Szulik added the comment:

Still LGTM.

___
PSF Meta Tracker 

___
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/


[Tracker-discuss] [issue610] Hyperlink git hashes of 10 or 11 characters

2016-12-22 Thread Brett C.
Brett C. added the comment:

I went ahead and implemented the idea of hg or git prefixes on the commit 
numbers.

___
PSF Meta Tracker 
<http://psf.upfronthosting.co.za/roundup/meta/issue610>
___
diff -r 1b16b4c8ab77 extensions/local_replace.py
--- a/extensions/local_replace.py   Fri Dec 02 01:21:29 2016 +0200
+++ b/extensions/local_replace.py   Thu Dec 22 10:54:37 2016 -0800
@@ -74,10 +74,11 @@
 
 seps = r'\b(?[a-fA-F0-9]{40})\b' % seps),
+# deadbeeffeed  (hg hashes with exactly twelve or forty chars,
+# git has 10 or more as it grows as time goes on)
+(re.compile(r'%s(?P(git|hg)?[a-fA-F0-9]{40})\b' % seps),
  r'http://hg.python.org/lookup/\g">\g'),
-(re.compile(r'%s(?P[a-fA-F0-9]{12})\b' % seps),
+(re.compile(r'%s(?P(git|hg)?[a-fA-F0-9]{10,12})\b' % seps),
  r'http://hg.python.org/lookup/\g">\g'),
 
 # r12345, r 12345, rev12345, rev. 12345, revision12345, revision 12345
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/

[Tracker-discuss] [issue589] Add GitHub PR to b.p.o issues using GitHub webhooks (depends on issue586)

2016-12-22 Thread Brett C.

Brett C. added the comment:

LGTM

___
PSF Meta Tracker 

___
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/


[Tracker-discuss] [issue610] Hyperlink git hashes of 10 or 11 characters

2016-12-22 Thread Brett C.

Brett C. added the comment:

Do people think it would be worth adding prefix support? E.g. 
/lookup/git1234567890 so as to help future-proof number collisions and 
ambiguity? We could also add "hg" prefix support (svn already has "r").

___
PSF Meta Tracker 

___
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/


[Tracker-discuss] [issue610] Hyperlink git hashes of 10 or 11 characters

2016-12-22 Thread Maciej Szulik

Maciej Szulik added the comment:

SGTM

___
PSF Meta Tracker 

___
___
Tracker-discuss mailing list
Tracker-discuss@python.org
https://mail.python.org/mailman/listinfo/tracker-discuss
Code of Conduct: https://www.python.org/psf/codeofconduct/