From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Moreton Newsgroups: gmane.emacs.bugs Subject: bug#13405: 24.3; log-view-diff-changeset reports wrong results Date: Sat, 12 Jan 2013 14:22:27 +0000 Message-ID: <50F171A3.9050200@gmail.com> References: <50EEE630.3000306@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1358000586 6393 80.91.229.3 (12 Jan 2013 14:23:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 12 Jan 2013 14:23:06 +0000 (UTC) Cc: 13405@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Jan 12 15:23:22 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Tu1zU-0006Te-K8 for geb-bug-gnu-emacs@m.gmane.org; Sat, 12 Jan 2013 15:23:20 +0100 Original-Received: from localhost ([::1]:58629 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tu1zE-0005XV-IE for geb-bug-gnu-emacs@m.gmane.org; Sat, 12 Jan 2013 09:23:04 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:43392) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tu1z5-0005X4-TZ for bug-gnu-emacs@gnu.org; Sat, 12 Jan 2013 09:23:02 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tu1yz-0008NU-Sg for bug-gnu-emacs@gnu.org; Sat, 12 Jan 2013 09:22:55 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50996) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tu1yz-0008NQ-Ox for bug-gnu-emacs@gnu.org; Sat, 12 Jan 2013 09:22:49 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1Tu1zC-0007jV-4i for bug-gnu-emacs@gnu.org; Sat, 12 Jan 2013 09:23:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andy Moreton Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 12 Jan 2013 14:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13405 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 13405-submit@debbugs.gnu.org id=B13405.135800057929717 (code B ref 13405); Sat, 12 Jan 2013 14:23:02 +0000 Original-Received: (at 13405) by debbugs.gnu.org; 12 Jan 2013 14:22:59 +0000 Original-Received: from localhost ([127.0.0.1]:56460 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tu1z8-0007jF-LF for submit@debbugs.gnu.org; Sat, 12 Jan 2013 09:22:59 -0500 Original-Received: from mail-ea0-f169.google.com ([209.85.215.169]:57050) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tu1z5-0007j2-PO for 13405@debbugs.gnu.org; Sat, 12 Jan 2013 09:22:56 -0500 Original-Received: by mail-ea0-f169.google.com with SMTP id a12so1108140eaa.28 for <13405@debbugs.gnu.org>; Sat, 12 Jan 2013 06:22:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:message-id:date:from:user-agent:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=a9Jtaew7UeGoxejiXdyy15qgh4y2LbGnWZmtUCxJ0/0=; b=ec9JNlNhAM/5Nktrv/bqMM/QS1Xs8C35/cFz13s+oXsEWPVkoEZuQj91UYxMmGa3vd JPY6beeSSZCXPSNlvVASVOwLRFbrKHy00DR2ttkrk2kLCNbYSh1m9VYNuWXQLkcZSnYP myGsRQn+/btnVUZrSUsgEiw4X/oYut/JcsN0HhgsY+C4Fkl+qmSl8eve4xcfU9YBIGO7 TcoL5Vtz8+rCMUMCyG8dAC/GTMDZGfg7GV04OkclQSstNpFSLOc6JyaH3t1XEsA+FTK7 pZbMhxmpL8eI4qmwEl4IrYnyXSVqBMwx+ADqUv9NcF0urCOwic8oJW5pordqlO5mxXUE 48mw== X-Received: by 10.14.184.134 with SMTP id s6mr210235413eem.43.1358000557435; Sat, 12 Jan 2013 06:22:37 -0800 (PST) Original-Received: from [192.168.0.3] (82-69-64-228.dsl.in-addr.zen.co.uk. [82.69.64.228]) by mx.google.com with ESMTPS id f6sm13037358eeo.7.2013.01.12.06.22.36 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 12 Jan 2013 06:22:36 -0800 (PST) User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:17.0) Gecko/20130107 Thunderbird/17.0.2 In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:69659 Archived-At: On 11/01/2013 23:13, Stefan Monnier wrote: >> 3) In the *vc-change-log* buffer, type D (log-view-diff-changeset) to view >> the changeset for that single revision. >> Emacs runs "hg diff --git -r 46768 -r 46769", but this does not show >> the expected contents of the changeset, as the previous revision was >> on a different named branch. Instead this shows the (large) diff between >> the two branches. The line counts illustrate this: > >> # hg diff -r 46768 -r 46769 | wc -l ## Diff between branches >> 102276 >> # hg diff -c 46769 | wc -l ## Changeset diff >> 295 >> # hg log -p -r 46769 | wc -l ## Changeset diff + hg metadata >> 302 > >> The second and third commands give the expected output. >> Can log-view-diff-changeset be changed to deal with this case more >> gracefully ? > > VC assumes you can get the changeset by running > "hg diff -r -r 46769". Is there a that would > give the right answer? Ideally this should be computable > from "46769". This can be done using revsets: # hg diff -r46769^1 -r 46769 | wc -l 295 However that relies on having a new enough version of mercurial that supports the revsets syntax. The "hg diff -c" or "hg log -p" commands work with older mercurial versions that do not support revset syntax. AndyM