[issue3121] hgdiff fail in Mercurial 2.0
Wayne
bugs at mercurial.selenic.com
Tue Nov 22 04:40:23 UTC 2011
New submission from Wayne <goto100 at gmail.com>:
OS: Windows 7 64bit
Python: 2.6
Mercurial: 2.0
My hgrc:
[extdiff]
cmd.vimdiff = gvim
opts.vimdiff = --noplugin -d -R
when I run "hg vimdiff path/to/somefile.js" the cmd window show:
abort: : c:\users\myusername\appdata\local\temp\extdiff.somerandomchars
and the vimdiff can't fetch the source file in this folder, the diff fail.
bug in Mercurial 1.9, It's OK.
I debug the source code, I found the differents between 1.9 and 2.0 in
extdiff.py line 225:
util.system(cmdline, cwd=tmproot, out=ui.fout)
in 2.0, ui.fout == sys.__stdout__, so in mercurial/util.py line 426,
mercurial opened a new subprocess to run the command, the main process exit,
delete the diff file, after that, open the vimdiff. at that time, the file
is already deleted, the bug shows.
in 1.9, ui.fout != sys.__stdout__, there is no bug.
as now, I rollback my mercurial to 1.9, I hope a patch will release soon.
----------
messages: 18136
nosy: goto100
priority: bug
status: unread
title: hgdiff fail in Mercurial 2.0
____________________________________________________
Mercurial issue tracker <bugs at mercurial.selenic.com>
<http://mercurial.selenic.com/bts/issue3121>
____________________________________________________
More information about the Mercurial-devel
mailing list