From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#20637: incompatible, undocumented change to vc-working-revision Date: Fri, 1 Apr 2016 03:36:57 +0300 Message-ID: References: <6ok2vyzwf9.fsf@fencepost.gnu.org> <08f70cda-44be-0657-e50a-2b2c80d2c21c@yandex.ru> <87mvphnoei.fsf@gmx.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1459471104 11570 80.91.229.3 (1 Apr 2016 00:38:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 1 Apr 2016 00:38:24 +0000 (UTC) Cc: 20637@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Apr 01 02:38:13 2016 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 1aln6L-00008Y-0H for geb-bug-gnu-emacs@m.gmane.org; Fri, 01 Apr 2016 02:38:13 +0200 Original-Received: from localhost ([::1]:35177 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aln6K-0001zG-5r for geb-bug-gnu-emacs@m.gmane.org; Thu, 31 Mar 2016 20:38:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59788) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aln6F-0001yY-R8 for bug-gnu-emacs@gnu.org; Thu, 31 Mar 2016 20:38:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aln6A-00045D-RH for bug-gnu-emacs@gnu.org; Thu, 31 Mar 2016 20:38:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:49477) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aln6A-000451-NL for bug-gnu-emacs@gnu.org; Thu, 31 Mar 2016 20:38:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1aln6A-000249-EF for bug-gnu-emacs@gnu.org; Thu, 31 Mar 2016 20:38:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 01 Apr 2016 00:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20637 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20637-submit@debbugs.gnu.org id=B20637.14594710277877 (code B ref 20637); Fri, 01 Apr 2016 00:38:02 +0000 Original-Received: (at 20637) by debbugs.gnu.org; 1 Apr 2016 00:37:07 +0000 Original-Received: from localhost ([127.0.0.1]:46604 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aln5H-00022x-9c for submit@debbugs.gnu.org; Thu, 31 Mar 2016 20:37:07 -0400 Original-Received: from mail-wm0-f46.google.com ([74.125.82.46]:38318) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aln5F-00022T-IZ for 20637@debbugs.gnu.org; Thu, 31 Mar 2016 20:37:05 -0400 Original-Received: by mail-wm0-f46.google.com with SMTP id 20so3212227wmh.1 for <20637@debbugs.gnu.org>; Thu, 31 Mar 2016 17:37:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=jUAbWTA/OJfBTM82k4bbZgXtnhc/kWTOZDZA8ZlrY7g=; b=AOdJKDoiAwSxxkilAn/vD8WtFbXjZHxIjoPpGf9+KEc/46d2TiO6UYqprv8pp8930r K2vnIicZTynWq8OhyYoGurgMrTjgy54vygKq/WEqkiaRfv7oO1sA9bLTbDDQC4OItAea ceztTF6SzOEk582pmJDY4I8wV/MFxaXgiHNMlcRlwjs0LfMGcJ1ewCv/GHHIHckXvJii 8dKCyPRgVvoGPAAE3KDvLxjBRDRyL0819AmHQ3SJI/0TAkqdskbvM+jqsxqXm4Pq0nHp yOJsXsrZd482eAQBcHC61rg78hPALRL+uP+3Yta9QXnqsg16eZ4m+yIR4tLPY+LFZ9ky 8vBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:to:references:cc:from:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=jUAbWTA/OJfBTM82k4bbZgXtnhc/kWTOZDZA8ZlrY7g=; b=iqLbF9cjjp4dpjks5pe5P7ICgigZ+BX7OYa/yRDFdtzecyqtxyje5vbVH02grosAnU xKjMwJmTQoXanHmtlYeTjo/pz+2Do2wJ1xHJs66ujumzxlSjfTewk4OjM4UIkUCT1LJC uHq42DTAHbfo9GlNrD3X3NM2zebWckgc8th0HxTAnSYI5x4sKDm7TRtRPSlq4xors/b+ proFPyeEh/B52/5DN8so11UZnMqC1mh2kN3ZZ+5uQgVqbGU53DzmPq6MFQbsh0gqx/3G p2x/ENPPGD3+IyIE3pkuajipp5z5WkTvFldab5a/UCbUGkZQjCtEd+iHiVwjs5f7r6UJ lVdg== X-Gm-Message-State: AD7BkJILg79PnAeRRnMXSFb9kgq7hVVJ7899x349lr4QmmkDePFPULZT3hY9o8riKBQi3w== X-Received: by 10.194.8.38 with SMTP id o6mr5978359wja.31.1459471019749; Thu, 31 Mar 2016 17:36:59 -0700 (PDT) Original-Received: from [192.168.1.2] ([185.105.175.24]) by smtp.googlemail.com with ESMTPSA id m13sm11913774wma.3.2016.03.31.17.36.58 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 31 Mar 2016 17:36:58 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0 In-Reply-To: <87mvphnoei.fsf@gmx.de> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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:115823 Archived-At: On 03/29/2016 09:13 PM, Michael Albinus wrote: > Why is verifying such tests "the wrong thing"? It's a while ago that I > wrote the tests, but IIRC I've added them exactly because I did expect > that such tests should pass, and they didn't. It's certainly not very meaningful to test this (it's better to compare to actual values; for all we know, the above method returns `fooled-ya' in both cases). As far as it being wrong: it is, if you consider that some existing implementations don't expect to be called with FILE that's not registered. So different return values in these two cases are to be expected. > I even fixed some trivial > corner cases when writing the tests. as far as I understood the code. Yes, you found some of those cases (but, like mentioned, not all), and that required double-checking that the file is indeed registered. You can argue that the new semantics are more straightforward, and I don't disagree (the docstring of vc-state seems to agree already; vc-working-revision's docstring disagrees). But the cost to that is extra process calls. I'm not sure if the changes in 7f9b037245ddb662ad98685e429a2498ae6b7c62 add any extra process calls, but they do add some interaction with the filesystem. Fixing the newly introduced problem with vc-git-state would require an extra process call, more or less reverting the fix for bug#11757. I don't know how much of a problem that is (I haven't used Windows in a while, and my current laptop is faster that what I had back then anyway), but it would certainly be nice not to introduce a regression in features, or performance. As far as vc-git-state, one way to do that is reimplementing some commands using 'git status --porcelain', introduced in Git 1.7.0. We should double-check if we're allowed to rely on this version being available (which Git does the the oldest relevant version of CentOS install now?), and it might be too late for Emacs 25.1 anyway. Calling vc-responsible-backend is also inherently slower than vc-backend, though not perceptibly so on this localhost (4e-5s vs 4e-6s). But it's likely more painful for remove hosts; how is it, in your experience?