Backtrace on cygwin: IOError: invalid mode: wb

Gregory Collins greg at maptuit.com
Wed Oct 3 12:46:05 CDT 2007


Hi all,

I got the following exception backtrace running hg atop cygwin:

~/replicated $ hg update
Traceback (most recent call last):
  File "/usr/local/bin/hg", line 14, in <module>
    mercurial.dispatch.run()
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 20, in run
    sys.exit(dispatch(sys.argv[1:]))
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 29, in dispatch
    return _runcatch(u, args)
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 45, in _runcatch
    return _dispatch(ui, args)
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 348, in _dispatch
    ret = _runcommand(ui, options, cmd, d)
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 401, in _runcommand
    return checkargs()
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 357, in checkargs
    return cmdfunc()
  File "/usr/local/lib/python2.5/site-packages/mercurial/dispatch.py", line 340, in <lambda>
    d = lambda: func(ui, repo, *args, **cmdoptions)
  File "/usr/local/lib/python2.5/site-packages/mercurial/commands.py", line 2723, in update
    return hg.update(repo, rev)
  File "/usr/local/lib/python2.5/site-packages/mercurial/hg.py", line 257, in update
    stats = _merge.update(repo, node, False, False, None)
  File "/usr/local/lib/python2.5/site-packages/mercurial/merge.py", line 625, in update
    stats = applyupdates(repo, action, wc, p2)
  File "/usr/local/lib/python2.5/site-packages/mercurial/merge.py", line 485, in applyupdates
    repo.wwrite(f, t, flags)
  File "/usr/local/lib/python2.5/site-packages/mercurial/localrepo.py", line 496, in wwrite
    self.wopener(filename, 'w').write(data)
  File "/usr/local/lib/python2.5/site-packages/mercurial/util.py", line 1365, in __call__
    return posixfile(f, mode)
IOError: invalid mode: wb


~/replicated $ hg --version
Mercurial Distributed SCM (version adce4d30a6ea)

This is the current hg tip revision. I think this is the same as
http://www.selenic.com/mercurial/bts/issue481. It was reported there as
a MacOS issue. Does anyone have a workaround?

G.


More information about the Mercurial mailing list