Opened on 08/08/2016 at 05:33:16 PM

Closed on 08/16/2016 at 01:29:13 PM

#4313 closed defect (fixed)

TypeError: expected string or buffer using hg review

Reported by: juliandoucette Assignee: trev
Priority: P4 Milestone:
Module: Sitescripts Keywords:
Cc: trev, sebastian Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):

Description (last modified by trev)


OSX 10.11.6

How to reproduce

  1. Create new repository hg init
  2. Make 1 commit hg commit -m "Sample message"
  3. Review one change hg review -c 0 -w -t "Sample message"

Observed behaviour

** Unknown exception encountered with possibly-broken third-party extension review
** which supports versions unknown of Mercurial.
** Please disable review and try your action again.
** If that fixes the bug please report it to the extension author.
** Python 2.7.10 (default, Oct 23 2015, 19:19:21) [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)]
** Mercurial Distributed SCM (version 3.8.2)
** Extensions loaded: color, pager, record, purge, rebase, strip, histedit, shelve, review
Traceback (most recent call last):
  File "/usr/local/bin/hg", line 43, in <module>
  File "/Library/Python/2.7/site-packages/mercurial/", line 59, in run
    sys.exit((dispatch(request(sys.argv[1:])) or 0) & 255)
  File "/Library/Python/2.7/site-packages/mercurial/", line 125, in dispatch
    ret = _runcatch(req)
  File "/Library/Python/2.7/site-packages/mercurial/", line 204, in _runcatch
    return _dispatch(req)
  File "/Library/Python/2.7/site-packages/mercurial/", line 887, in _dispatch
    cmdpats, cmdoptions)
  File "/Library/Python/2.7/site-packages/mercurial/", line 632, in runcommand
    ret = _runcommand(ui, options, cmd, d)
  File "/Library/Python/2.7/site-packages/mercurial/", line 204, in closure
    return func(*(args + a), **kw)
  File "/Library/Python/2.7/site-packages/hgext/", line 160, in pagecmd
    return orig(ui, options, cmd, cmdfunc)
  File "/Library/Python/2.7/site-packages/mercurial/", line 204, in closure
    return func(*(args + a), **kw)
  File "/Library/Python/2.7/site-packages/hgext/", line 502, in colorcmd
    return orig(ui_, opts, cmd, cmdfunc)
  File "/Library/Python/2.7/site-packages/mercurial/", line 1017, in _runcommand
    return checkargs()
  File "/Library/Python/2.7/site-packages/mercurial/", line 978, in checkargs
    return cmdfunc()
  File "/Library/Python/2.7/site-packages/mercurial/", line 884, in <lambda>
    d = lambda: util.checksignature(func)(ui, *args, **cmdoptions)
  File "/Library/Python/2.7/site-packages/mercurial/", line 1005, in check
    return func(*args, **kwargs)
  File "/Users/jdoucette/Desktop/codingtools/", line 69, in review
    match ='^(?:https://|ssh://hg@)(.*)', path)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/", line 146, in search
    return _compile(pattern, flags).search(string)
TypeError: expected string or buffer

Expected behaviour

Review is created/uploaded on


The repository has no URL configured, so the code trying to determine repository name fails.

Attachments (0)

Change History (4)

comment:1 Changed on 08/08/2016 at 07:05:00 PM by trev

  • Description modified (diff)
  • Owner set to trev
  • Priority changed from Unknown to P4
  • Ready set

comment:2 Changed on 08/08/2016 at 07:06:38 PM by trev

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:3 Changed on 08/16/2016 at 01:28:05 PM by abpbot

comment:4 Changed on 08/16/2016 at 01:29:13 PM by trev

  • Resolution set to fixed
  • Status changed from reviewing to closed

Add Comment

Modify Ticket

Change Properties
as closed .
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from trev.
Note: See TracTickets for help on using tickets.