Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Issue 29336790: Issue 3674 - Add a hg hook that references commits in issues (Closed)

Created:
Feb. 22, 2016, 10:17 a.m. by Felix Dahlke
Modified:
Feb. 24, 2016, 8:30 p.m.
Reviewers:
Wladimir Palant
CC:
Sebastian Noack
Visibility:
Public.

Description

Issue 3674 - Add a hg hook that references commits in issues

Patch Set 1 : #

Total comments: 15

Patch Set 2 : Address comments #

Total comments: 12

Patch Set 3 : Address comments #

Patch Set 4 : Don't use RegexObject.match #

Unified diffs Side-by-side diffs Delta from patch set Stats (+87 lines, -0 lines) Patch
M .sitescripts.example View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
A sitescripts/hg/bin/update_issues.py View 1 2 3 1 chunk +76 lines, -0 lines 0 comments Download
A sitescripts/hg/template/issue_commit_comment.tmpl View 1 2 1 chunk +9 lines, -0 lines 0 comments Download

Messages

Total messages: 11
Felix Dahlke
Feb. 22, 2016, 10:59 a.m. (2016-02-22 10:59:50 UTC) #1
Wladimir Palant
Philip will be extremely happy about installing yet another Trac plugin ;). I'll look into ...
Feb. 22, 2016, 11:32 a.m. (2016-02-22 11:32:33 UTC) #2
Wladimir Palant
https://codereview.adblockplus.org/29336790/diff/29336797/.sitescripts.example File .sitescripts.example (right): https://codereview.adblockplus.org/29336790/diff/29336797/.sitescripts.example#newcode166 .sitescripts.example:166: trac_xmlrpc_url=https://abpbot:abpbot@issues.adblockplus.org/login/xmlrpc On 2016/02/22 11:32:33, Wladimir Palant wrote: > Shouldn't ...
Feb. 22, 2016, 11:41 a.m. (2016-02-22 11:41:37 UTC) #3
Wladimir Palant
https://codereview.adblockplus.org/29336790/diff/29336797/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29336797/sitescripts/hg/bin/update_issues.py#newcode56 sitescripts/hg/bin/update_issues.py:56: {"_ts": attributes["_ts"], "action": "leave"}) The ridiculous part about this ...
Feb. 22, 2016, 12:02 p.m. (2016-02-22 12:02:51 UTC) #4
Wladimir Palant
https://codereview.adblockplus.org/29336790/diff/29336797/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29336797/sitescripts/hg/bin/update_issues.py#newcode56 sitescripts/hg/bin/update_issues.py:56: {"_ts": attributes["_ts"], "action": "leave"}) Sorry about so many mails, ...
Feb. 22, 2016, 12:06 p.m. (2016-02-22 12:06:02 UTC) #5
Felix Dahlke
New patch set is up. https://codereview.adblockplus.org/29336790/diff/29336797/.sitescripts.example File .sitescripts.example (right): https://codereview.adblockplus.org/29336790/diff/29336797/.sitescripts.example#newcode166 .sitescripts.example:166: trac_xmlrpc_url=https://abpbot:abpbot@issues.adblockplus.org/login/xmlrpc On 2016/02/22 11:41:37, ...
Feb. 22, 2016, 8:09 p.m. (2016-02-22 20:09:50 UTC) #6
Wladimir Palant
https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py#newcode33 sitescripts/hg/bin/update_issues.py:33: template = get_template("hg/template/issue_commit_comment.tmpl") I think you need autoescape=False here. ...
Feb. 23, 2016, 10:41 a.m. (2016-02-23 10:41:31 UTC) #7
Felix Dahlke
New patch set is up. https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py#newcode33 sitescripts/hg/bin/update_issues.py:33: template = get_template("hg/template/issue_commit_comment.tmpl") On ...
Feb. 23, 2016, 4:23 p.m. (2016-02-23 16:23:00 UTC) #8
Wladimir Palant
https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py#newcode50 sitescripts/hg/bin/update_issues.py:50: noissue_regex = re.compile(r"noissue\b", re.I) On 2016/02/23 16:22:59, Felix Dahlke ...
Feb. 23, 2016, 9:33 p.m. (2016-02-23 21:33:23 UTC) #9
Felix Dahlke
And another patch set. https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py File sitescripts/hg/bin/update_issues.py (right): https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/update_issues.py#newcode50 sitescripts/hg/bin/update_issues.py:50: noissue_regex = re.compile(r"noissue\b", re.I) On ...
Feb. 23, 2016, 9:40 p.m. (2016-02-23 21:40:59 UTC) #10
Wladimir Palant
Feb. 24, 2016, 10:13 a.m. (2016-02-24 10:13:49 UTC) #11
LGTM

https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/...
File sitescripts/hg/bin/update_issues.py (right):

https://codereview.adblockplus.org/29336790/diff/29337499/sitescripts/hg/bin/...
sitescripts/hg/bin/update_issues.py:50: noissue_regex = re.compile(r"noissue\b",
re.I)
On 2016/02/23 21:40:58, Felix Dahlke wrote:
> Fair enough. Tried to be smart, but this comment thread proves that it's a bad
> idea. Done.

Yes, particularly with the regexp and re.match() not in the same place this is
very confusing.

Powered by Google App Engine
This is Rietveld