Skip to content

Commit

Permalink
codereview: fix 'hg sync' and 'hg download' in Python 2.7
Browse files Browse the repository at this point in the history
Fixes #1218.

R=rsc
CC=golang-dev
https://golang.org/cl/2664041
  • Loading branch information
fhs authored and rsc committed Nov 1, 2010
1 parent 270bad3 commit 0e816f5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/codereview/codereview.py
Original file line number Diff line number Diff line change
Expand Up @@ -1508,7 +1508,7 @@ def IsRietveldSubmitted(ui, clname, hex):
if feed is None:
return False
for sum in feed.findall("{http:https://www.w3.org/2005/Atom}entry/{http:https://www.w3.org/2005/Atom}summary"):
text = sum.findtext("", None).strip()
text = sum.text.strip()
m = re.match('\*\*\* Submitted as [^*]*?([0-9a-f]+) \*\*\*', text)
if m is not None and len(m.group(1)) >= 8 and hex.startswith(m.group(1)):
return True
Expand Down Expand Up @@ -1542,7 +1542,7 @@ def DownloadCL(ui, repo, clname):
# Find author - first entry will be author who created CL.
nick = None
for author in feed.findall("{http:https://www.w3.org/2005/Atom}entry/{http:https://www.w3.org/2005/Atom}author/{http:https://www.w3.org/2005/Atom}name"):
nick = author.findtext("", None).strip()
nick = author.text.strip()
break
if not nick:
return None, None, "CL has no author"
Expand Down

0 comments on commit 0e816f5

Please sign in to comment.