From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: joaotavora@gmail.com (=?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?=) Newsgroups: gmane.emacs.bugs Subject: bug#24623: 25.1; Flymake turns off if check command fails without reporting errors in the file being edited Date: Fri, 03 Nov 2017 11:51:23 +0000 Message-ID: <877ev7vav8.fsf@gmail.com> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1509709944 23051 195.159.176.226 (3 Nov 2017 11:52:24 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 3 Nov 2017 11:52:24 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (gnu/linux) Cc: 24623@debbugs.gnu.org To: Dave Abrahams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Nov 03 12:52:13 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eAaWA-0005CZ-9J for geb-bug-gnu-emacs@m.gmane.org; Fri, 03 Nov 2017 12:52:10 +0100 Original-Received: from localhost ([::1]:36097 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eAaWH-0004dQ-6t for geb-bug-gnu-emacs@m.gmane.org; Fri, 03 Nov 2017 07:52:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33378) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eAaW7-0004bk-9n for bug-gnu-emacs@gnu.org; Fri, 03 Nov 2017 07:52:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eAaW2-0008DD-Ch for bug-gnu-emacs@gnu.org; Fri, 03 Nov 2017 07:52:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:40120) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eAaW2-0008D7-9O for bug-gnu-emacs@gnu.org; Fri, 03 Nov 2017 07:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eAaW2-00057U-2t for bug-gnu-emacs@gnu.org; Fri, 03 Nov 2017 07:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: joaotavora@gmail.com (=?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?=) Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 03 Nov 2017 11:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24623 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24623-submit@debbugs.gnu.org id=B24623.150970989619644 (code B ref 24623); Fri, 03 Nov 2017 11:52:02 +0000 Original-Received: (at 24623) by debbugs.gnu.org; 3 Nov 2017 11:51:36 +0000 Original-Received: from localhost ([127.0.0.1]:48801 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eAaVb-00056l-LD for submit@debbugs.gnu.org; Fri, 03 Nov 2017 07:51:36 -0400 Original-Received: from mail-wm0-f45.google.com ([74.125.82.45]:49740) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eAaVa-00056J-HY for 24623@debbugs.gnu.org; Fri, 03 Nov 2017 07:51:34 -0400 Original-Received: by mail-wm0-f45.google.com with SMTP id b189so937699wmd.4 for <24623@debbugs.gnu.org>; Fri, 03 Nov 2017 04:51:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=XoDEWxVu7dl9d7U2bgrMfzp+SiVezQ4ZS9HnmU5QSaA=; b=RzKjng1EbYUtdSCXUeDXDLEcrhjgqwNfKsxtGYqmO8PsKH/6dT7UdCCAsn6ARU7rWl xwrLrEZP35L29QHMT7V0USX2GaFTPEz1H6cAxK0YZDEqO24AuMymAvs8V71nJY5tw+S6 MrwRjeCqADJALt5BkCHU0lAdZJPVWwWhb659aMclgYU6oZ4iXh5acM7+V3UkKiCSGKjY wEY8psRT0OgGMcBdZMxW9er4KXBsUNGrRSY/OOyzU7BTvdY9s3nFDObnJ2Ktr2T/LsB7 99vO/4k62pk585IrHCYrd/GNm49X7dfqv1HzAD01yedAE5OkmL3uKXDrEi4Tc5LnW8Fl urGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=XoDEWxVu7dl9d7U2bgrMfzp+SiVezQ4ZS9HnmU5QSaA=; b=Lm/Nyu7+iQdmg0Ym2avG2F06QLKlJK5wje1jLdU/PUb09S/4kkh/0nMAcTThp82aes ppiwYS277DDa46iUEbI5f6iAOjgSWP9StN5WJKJjBPHYZPDxlzke128LNt2QX/ieP7vL aoaD66gliog2txz633vNIXnVUp2tfEwz8dYS32A9bWH9PwRnqtVgSntnKE707oWTe+fX Jdx4oisrlrOUV07pJQLzyhV7AiUPT7NwXvPJX9IHskb6ykyb0w74Oe77LelU5V5fm+gw nkQGoIigpV8l9frqU92sh3f0vQmOAk8NPVoEfmpzj1uGXAV3khYkXFbYEMUlpJA2NojR 4bMg== X-Gm-Message-State: AMCzsaX9xzAEB08yG+yB6CkDX9spVA0WmxOHmujlYWyJW1sJk5IczGOg cFLcEMzTBewYlYcp9e4yIN4= X-Google-Smtp-Source: ABhQp+TPN7yn2fgYUZGswxEduhJS3+3lutdTuQyG7TXhpD7r/j9O9YI5JwZkVf1R3V+t1uzDndTiVA== X-Received: by 10.28.126.146 with SMTP id z140mr4553033wmc.126.1509709888481; Fri, 03 Nov 2017 04:51:28 -0700 (PDT) Original-Received: from lolita.yourcompany.com (188.139.62.94.rev.vodafone.pt. [94.62.139.188]) by smtp.gmail.com with ESMTPSA id 64sm4293594wrk.46.2017.11.03.04.51.26 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 03 Nov 2017 04:51:27 -0700 (PDT) In-Reply-To: (Dave Abrahams's message of "Tue, 04 Oct 2016 10:47:32 -0700") 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" Xref: news.gmane.org gmane.emacs.bugs:139407 Archived-At: Dave Abrahams writes: > In these lines from flymake-post-syntax-check: > > (if (and (equal 0 err-count) (equal 0 warn-count)) > (if (equal 0 exit-status) > (flymake-report-status "" "") ; PASSED > (if (not flymake-check-was-interrupted) > (flymake-report-fatal-status "CFGERR" > (format "Configuration error= has occurred while running %s" command)) > (flymake-report-status nil ""))) ; "STOPPED" > (flymake-report-status (format "%d/%d" err-count warn-count) ""))= ))) > > err-count and warn-count are the count of errors detected *in the file > being edited*. My syntax check command must consider a whole batch of > files at once, and sometimes those other files have errors in them. > That should not disable syntax checking in the current file, but flymake > has this behavior unconditionally, and there's no way to turn it off. [Eli, I=E2=80=99m CC=E2=80=99ing you since I think this bug can be marked "= wontfix" or equivalent] Hello Dave and sorry for the extremely late reply to this bug. This is easy to reproduce with GCC as a checker tool when checking a .h file with no errors but included by a .c file with some errors. I just wanted to note, if you haven=E2=80=99t noticed already, that Flymake= has been redesigned in the upcoming Emacs 26 and the functionality you refer to is now considered obsolete. Nevertheless, it is still supported and lives in a so called "legacy backend". Your particular problem also popped up for me testing. My solution would be to invoke your syntax checker tool in a way that the invocation univocally returns 0, like having this in a Makefile: syntax-check: mytool $(CHK_SOURCES) || true But there are new much better ways to configure Flymake with your syntax checker. They are described in the Flymake Info manual, which also broadly describes the redesign effort). You can read this manual with M-x info in the upcoming Emacs version (or one of the already available pretests thereof). Given the workaround, I don=E2=80=99t there=E2=80=99s much reason to fix th= is. Jo=C3=A3o