From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 26 01:18:28 2017 Received: (at submit) by debbugs.gnu.org; 26 Nov 2017 06:18:28 +0000 Received: from localhost ([127.0.0.1]:58482 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eIqGq-0001NX-19 for submit@debbugs.gnu.org; Sun, 26 Nov 2017 01:18:28 -0500 Received: from eggs.gnu.org ([208.118.235.92]:47891) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eIqGn-0001NK-Vr for submit@debbugs.gnu.org; Sun, 26 Nov 2017 01:18:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eIqGh-0002Op-Lz for submit@debbugs.gnu.org; Sun, 26 Nov 2017 01:18:20 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:35526) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eIqGh-0002Og-Ih for submit@debbugs.gnu.org; Sun, 26 Nov 2017 01:18:19 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38855) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eIqGg-0005ZV-HO for bug-gnu-emacs@gnu.org; Sun, 26 Nov 2017 01:18:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eIqGd-0002Ky-Dh for bug-gnu-emacs@gnu.org; Sun, 26 Nov 2017 01:18:18 -0500 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:38710) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eIqGd-0002Kl-AE; Sun, 26 Nov 2017 01:18:15 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:41929) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1eIqGc-00032b-Ux; Sun, 26 Nov 2017 01:18:15 -0500 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailauth.nyi.internal (Postfix) with ESMTP id 355A020BF0; Sun, 26 Nov 2017 01:18:14 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Sun, 26 Nov 2017 01:18:14 -0500 X-ME-Sender: Received: from localhost (76-234-69-149.lightspeed.frokca.sbcglobal.net [76.234.69.149]) by mail.messagingengine.com (Postfix) with ESMTPA id 9835B240B2; Sun, 26 Nov 2017 01:18:13 -0500 (EST) From: "John Wiegley" To: bug-gnu-emacs@gnu.org Subject: 26.0.90; No check for nil in some filenotify functions Date: Sat, 25 Nov 2017 22:18:07 -0800 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (darwin) Mail-Followup-To: bug-gnu-emacs@gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) The documentation for find-file-name-handler says: find-file-name-handler is a built-in function in =E2=80=98C source code= =E2=80=99. =20=20=20=20 (find-file-name-handler FILENAME OPERATION) =20=20=20=20 Return FILENAME=E2=80=99s handler function for OPERATION, if it has one. Otherwise, return nil. However, several of the functions in filenotify use the return value of this function without checking if it's nil or not: (defun file-notify-rm-watch (descriptor) "Remove an existing watch specified by its DESCRIPTOR. DESCRIPTOR should be an object returned by `file-notify-add-watch'." (when-let* ((watch (gethash descriptor file-notify-descriptors))) (let ((handler (find-file-name-handler (file-notify--watch-directory watch) 'file-notify-rm-watch))) (condition-case nil (if handler ;; A file name handler could exist even if there is no ;; local file notification support. (funcall handler 'file-notify-rm-watch descriptor) I've been getting several errors with a backtrace like nil(48). This is lik= ely because some package has done something wrong, but even still, filenotify should be more defensive. --=20 John Wiegley GPG fingerprint =3D 4710 CF98 AF9B 327B B80F http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2 From debbugs-submit-bounces@debbugs.gnu.org Sun Nov 26 10:40:02 2017 Received: (at submit) by debbugs.gnu.org; 26 Nov 2017 15:40:02 +0000 Received: from localhost ([127.0.0.1]:59474 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eIz2G-0007E1-SQ for submit@debbugs.gnu.org; Sun, 26 Nov 2017 10:40:02 -0500 Received: from eggs.gnu.org ([208.118.235.92]:34143) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eIz2F-0007Do-2P for submit@debbugs.gnu.org; Sun, 26 Nov 2017 10:39:59 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eIz28-0000qi-Jz for submit@debbugs.gnu.org; Sun, 26 Nov 2017 10:39:53 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:57422) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1eIz28-0000qb-GZ for submit@debbugs.gnu.org; Sun, 26 Nov 2017 10:39:52 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53340) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eIz27-0005co-8y for bug-gnu-emacs@gnu.org; Sun, 26 Nov 2017 10:39:52 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eIz26-0000q0-Ex for bug-gnu-emacs@gnu.org; Sun, 26 Nov 2017 10:39:51 -0500 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:42788) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eIz21-0000p2-J0; Sun, 26 Nov 2017 10:39:45 -0500 Received: from [176.228.60.248] (port=4926 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1eIz20-0002Hi-Sg; Sun, 26 Nov 2017 10:39:45 -0500 Date: Sun, 26 Nov 2017 17:39:31 +0200 Message-Id: <83lgit6ocs.fsf@gnu.org> From: Eli Zaretskii To: "John Wiegley" In-reply-to: (johnw@gnu.org) Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions References: MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit Cc: bug-gnu-emacs@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) > From: "John Wiegley" > Date: Sat, 25 Nov 2017 22:18:07 -0800 > > The documentation for find-file-name-handler says: > > find-file-name-handler is a built-in function in ‘C source code’. > > (find-file-name-handler FILENAME OPERATION) > > Return FILENAME’s handler function for OPERATION, if it has one. > Otherwise, return nil. > > However, several of the functions in filenotify use the return value of this > function without checking if it's nil or not: Maybe I'm blind, but I cannot find any place in filenotify where the handler is used without checking, including in the case you show: > (defun file-notify-rm-watch (descriptor) > "Remove an existing watch specified by its DESCRIPTOR. > DESCRIPTOR should be an object returned by `file-notify-add-watch'." > (when-let* ((watch (gethash descriptor file-notify-descriptors))) > (let ((handler (find-file-name-handler > (file-notify--watch-directory watch) > 'file-notify-rm-watch))) > (condition-case nil > (if handler <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< > ;; A file name handler could exist even if there is no > ;; local file notification support. > (funcall handler 'file-notify-rm-watch descriptor) What am I missing? > I've been getting several errors with a backtrace like nil(48). This is likely > because some package has done something wrong, but even still, filenotify > should be more defensive. Can you show a full backtrace like that? From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 09 19:29:03 2018 Received: (at 29450) by debbugs.gnu.org; 10 Jan 2018 00:29:03 +0000 Received: from localhost ([127.0.0.1]:50088 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZ4GN-0007Ym-Ar for submit@debbugs.gnu.org; Tue, 09 Jan 2018 19:29:03 -0500 Received: from eggs.gnu.org ([208.118.235.92]:54009) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZ4GM-0007YC-5H for 29450@debbugs.gnu.org; Tue, 09 Jan 2018 19:29:02 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eZ4GG-0001B0-6I for 29450@debbugs.gnu.org; Tue, 09 Jan 2018 19:28:57 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD, UNRESOLVED_TEMPLATE autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39338) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eZ4GD-00018k-C1; Tue, 09 Jan 2018 19:28:53 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1eZ4GC-0002SD-NE; Tue, 09 Jan 2018 19:28:52 -0500 From: Glenn Morris To: "John Wiegley" , 29450@debbugs.gnu.org Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions References: <83lgit6ocs.fsf@gnu.org> X-Spook: Execution Michoacna Attack Ammonium nitrate clones X-Ran: WzHXBbPfKCjdM|qpY>.i9I?H:K!Ar^7{<2/Axht2Z2"@(YbTkK)p%SHMSlt"4VE'B;wR (Eli Zaretskii's message of "Sun, 26 Nov 2017 17:39:31 +0200") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -4.3 (----) X-Debbugs-Envelope-To: 29450 Cc: Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.3 (----) Eli Zaretskii wrote: >> From: "John Wiegley" >> Date: Sat, 25 Nov 2017 22:18:07 -0800 >>=20 >> The documentation for find-file-name-handler says: >>=20 >> find-file-name-handler is a built-in function in =C3=A2=E2=82=AC=CB= =9CC source code=C3=A2=E2=82=AC=E2=84=A2. >>=20=20=20=20=20 >> (find-file-name-handler FILENAME OPERATION) >>=20=20=20=20=20 >> Return FILENAME=C3=A2=E2=82=AC=E2=84=A2s handler function for OPERAT= ION, if it has one. >> Otherwise, return nil. >>=20 >> However, several of the functions in filenotify use the return value of = this >> function without checking if it's nil or not: > > Maybe I'm blind, but I cannot find any place in filenotify where the > handler is used without checking, including in the case you show: > >> (defun file-notify-rm-watch (descriptor) >> "Remove an existing watch specified by its DESCRIPTOR. >> DESCRIPTOR should be an object returned by `file-notify-add-watch'." >> (when-let* ((watch (gethash descriptor file-notify-descriptors))) >> (let ((handler (find-file-name-handler >> (file-notify--watch-directory watch) >> 'file-notify-rm-watch))) >> (condition-case nil >> (if handler <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< >> ;; A file name handler could exist even if there is no >> ;; local file notification support. >> (funcall handler 'file-notify-rm-watch descriptor) > > What am I missing? > >> I've been getting several errors with a backtrace like nil(48). This is = likely >> because some package has done something wrong, but even still, filenotify >> should be more defensive. > > Can you show a full backtrace like that? Any update? From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 10 18:56:33 2018 Received: (at 29450) by debbugs.gnu.org; 10 Jan 2018 23:56:33 +0000 Received: from localhost ([127.0.0.1]:51513 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZQET-0008Of-CA for submit@debbugs.gnu.org; Wed, 10 Jan 2018 18:56:33 -0500 Received: from eggs.gnu.org ([208.118.235.92]:58770) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZQEQ-0008OS-PZ for 29450@debbugs.gnu.org; Wed, 10 Jan 2018 18:56:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eZQEG-0007mU-Fg for 29450@debbugs.gnu.org; Wed, 10 Jan 2018 18:56:25 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_20,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:35119) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eZQEF-0007ka-DF for 29450@debbugs.gnu.org; Wed, 10 Jan 2018 18:56:19 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:57611) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1eZQEE-0004Fe-SG; Wed, 10 Jan 2018 18:56:18 -0500 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailauth.nyi.internal (Postfix) with ESMTP id 2478D20CF9; Wed, 10 Jan 2018 18:56:18 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Wed, 10 Jan 2018 18:56:18 -0500 X-ME-Sender: Received: from localhost (76-234-69-149.lightspeed.frokca.sbcglobal.net [76.234.69.149]) by mail.messagingengine.com (Postfix) with ESMTPA id B144C24608; Wed, 10 Jan 2018 18:56:17 -0500 (EST) From: John Wiegley To: Glenn Morris Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions In-Reply-To: (Glenn Morris's message of "Tue, 09 Jan 2018 19:28:52 -0500") Date: Wed, 10 Jan 2018 15:56:13 -0800 Message-ID: References: <83lgit6ocs.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 29450 Cc: 29450@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) >>>>> "GM" == Glenn Morris writes: >>> I've been getting several errors with a backtrace like nil(48). This is >>> likely because some package has done something wrong, but even still, >>> filenotify should be more defensive. >> >> Can you show a full backtrace like that? GM> Any update? I worked around this with (setq auto-revert-use-notify nil). If it doesn't happen for anyone else, you can close it. I'll look into it again if I ever decide to re-enable this. -- John Wiegley GPG fingerprint = 4710 CF98 AF9B 327B B80F http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2 From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 11 04:13:21 2018 Received: (at 29450) by debbugs.gnu.org; 11 Jan 2018 09:13:21 +0000 Received: from localhost ([127.0.0.1]:51671 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZYvJ-0004sF-2g for submit@debbugs.gnu.org; Thu, 11 Jan 2018 04:13:21 -0500 Received: from mout.gmx.net ([212.227.17.21]:51679) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eZYvH-0004s2-95 for 29450@debbugs.gnu.org; Thu, 11 Jan 2018 04:13:19 -0500 Received: from detlef.gmx.de ([212.86.42.203]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LgZ7h-1fBuTV3EAf-00nzHr; Thu, 11 Jan 2018 10:13:12 +0100 From: Michael Albinus To: John Wiegley Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions References: <83lgit6ocs.fsf@gnu.org> Date: Thu, 11 Jan 2018 10:13:11 +0100 In-Reply-To: (John Wiegley's message of "Wed, 10 Jan 2018 15:56:13 -0800") Message-ID: <87fu7chi6w.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K0:JlYcaECte0DYUAHSDmvF9UP1sa/fGMIGr3dVUx49nfos8n0swba zJ8YM9hszbJchgCFRGH2uYujRNxdRwhXoU9KaQ/5MyrBpAkdsyc24ftSUk/Xyl1kzWAijUH 8THcX2NbjUUvM1PJq/PnM8qHuqrBn2j1oCfYk+siSV0Y3EUo89052Fhfb6s1np9+Mji7jiN f64lX1hkv0M0Ut5hgT+Dg== X-UI-Out-Filterresults: notjunk:1;V01:K0:4ODdOVcVo9A=:lQrPQfL06ZivwN3jHnwqfu yy1SmORiDSzJPoZsKN2mJRWGtpRK/hJeCH/P7MNsRtxOF1sbMvhTTaDeJI2CRMGZom9K8D2Tx 25h+NCXuXi9VaBYkyYs1tIPii2xdUQD7DYcHtkTLVtFHFcoq/CmpyWRw5Cbg1RfwsU6JG3+zp qxBmuZqpGUWZ/NCAuVcZo6MphcxCGyuhY/GLw+pFoJrgja6T+p5L9mcN18CO+sFw9jTI8OO2y VOO3DPksTsRZxQIfsNxp0o92tA1dIVhde/J7hXjmKzXQRjaztfk6HECRIyvGSlTnpIoPSTjVT eGnyp8hlEtwKuvziywWfFMpZir/NOHeqwi7I95KPy8y/xb8xrPfTjLVzch0eUmj0Tac69o1lp 5Wksezt7+iv5Hf0FLzu9BahA38aqM8JxVzrnZDXgm0T8vOSF50RbM0l/8KY/XZP7UDWVaHaFk F9Gbq+F57HdwC1pAEyRVI5d232IJgoTVMDcWH5I/SIX1YZTfqZ5W6GAD8UgUaiipUKwPbHtAr 8unGaQ1aDSYtrOe7fxbQF1ApWyhaTR431FNs3nkN3H++4wDF0oOZyCercDBwTuTs2OTkdOACF PLvJS0a29OihrmMErnyazYCD0d6WPUnAtiqi5ZVZ+QebBaL2XiXqZuW60kz4qfrRwYchgTusx si+DwLkhIlZyoQ4CkMdsMnp+mDRbWxI0FeJWKUZRG8T7ZVYjrTW+BFAkQQAlv35qbQcYEr7aM xRFnS6MQGqlR7eHQbmuBJBoBhuX+f6lz6R73XYTUkW3GkYXLeEIxiCSi2NIoglFCNMESpusqx bD7ktRtCARQ7M8jN8RDxNjobBCV7troPxihxMiD7VWE9/z2Ghk= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 29450 Cc: Glenn Morris , 29450@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) John Wiegley writes: Hi, Sorry to jump in such late; I've overlooked this thread before. >>>> I've been getting several errors with a backtrace like nil(48). This is >>>> likely because some package has done something wrong, but even still, >>>> filenotify should be more defensive. >>> >>> Can you show a full backtrace like that? > > I worked around this with (setq auto-revert-use-notify nil). If it doesn't > happen for anyone else, you can close it. I'll look into it again if I ever > decide to re-enable this. I still would like to see a full backtrace. You have quoted --8<---------------cut here---------------start------------->8--- (when-let* ((watch (gethash descriptor file-notify-descriptors))) (let ((handler (find-file-name-handler (file-notify--watch-directory watch) 'file-notify-rm-watch))) --8<---------------cut here---------------end--------------->8--- I have the feeling that it isn't the return value of `find-file-name-handler' being nil, but rather the `file-notify--watch-directory' call. Best regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 17 15:39:57 2018 Received: (at control) by debbugs.gnu.org; 17 Jan 2018 20:39:57 +0000 Received: from localhost ([127.0.0.1]:60622 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ebuV3-0004WY-A4 for submit@debbugs.gnu.org; Wed, 17 Jan 2018 15:39:57 -0500 Received: from eggs.gnu.org ([208.118.235.92]:53017) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ebuV1-0004WI-ID for control@debbugs.gnu.org; Wed, 17 Jan 2018 15:39:55 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ebuUv-00039B-M0 for control@debbugs.gnu.org; Wed, 17 Jan 2018 15:39:50 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:42525) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ebuUv-000393-Id for control@debbugs.gnu.org; Wed, 17 Jan 2018 15:39:49 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1ebuUv-0000yi-BI for control@debbugs.gnu.org; Wed, 17 Jan 2018 15:39:49 -0500 Subject: control message for bug 29450 To: X-Mailer: mail (GNU Mailutils 2.99.98) Message-Id: From: Glenn Morris Date: Wed, 17 Jan 2018 15:39:49 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) tag 29450 + wontfix From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 05 01:49:00 2018 Received: (at 29450) by debbugs.gnu.org; 5 Feb 2018 06:49:00 +0000 Received: from localhost ([127.0.0.1]:57633 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eiaaJ-0002z4-Vy for submit@debbugs.gnu.org; Mon, 05 Feb 2018 01:49:00 -0500 Received: from eggs.gnu.org ([208.118.235.92]:44630) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eiaaI-0002ys-Aq for 29450@debbugs.gnu.org; Mon, 05 Feb 2018 01:48:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eiaa8-0004jR-Cq for 29450@debbugs.gnu.org; Mon, 05 Feb 2018 01:48:53 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:41795) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eiaa8-0004j5-87; Mon, 05 Feb 2018 01:48:48 -0500 Received: from auth2-smtp.messagingengine.com ([66.111.4.228]:43111) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.82) (envelope-from ) id 1eiaa7-0000xZ-3H; Mon, 05 Feb 2018 01:48:47 -0500 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailauth.nyi.internal (Postfix) with ESMTP id 5689420A92; Mon, 5 Feb 2018 01:48:46 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Mon, 05 Feb 2018 01:48:46 -0500 X-ME-Sender: Received: from localhost (76-234-69-149.lightspeed.frokca.sbcglobal.net [76.234.69.149]) by mail.messagingengine.com (Postfix) with ESMTPA id C25D724250; Mon, 5 Feb 2018 01:48:45 -0500 (EST) From: John Wiegley To: Michael Albinus Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions In-Reply-To: <87fu7chi6w.fsf@gmx.de> (Michael Albinus's message of "Thu, 11 Jan 2018 10:13:11 +0100") Date: Sun, 04 Feb 2018 22:48:39 -0800 Message-ID: References: <83lgit6ocs.fsf@gnu.org> <87fu7chi6w.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.91 (darwin) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 29450 Cc: Glenn Morris , 29450@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) >>>>> "MA" == Michael Albinus writes: MA> I have the feeling that it isn't the return value of MA> `find-file-name-handler' being nil, but rather the MA> `file-notify--watch-directory' call. I've had file-notify back on for a few days now, and this has not happened again, so I'm fine with closing this issue. However -- and this is a separate bug -- I had to disable it again because it was stalling out Emacs regularly. I'd ran an operation that changed the state of the disk, and then Emacs would be locked up for minutes at a time until I hit C-g repeatedly. Finally, I ran Instruments to see what was going on, and it was stuck in a busy loop reading directories, spending 92% of its time calling delq over and over again. But that's a separate issue, and disabling file-notify cured the performance problem. -- John Wiegley GPG fingerprint = 4710 CF98 AF9B 327B B80F http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2 From debbugs-submit-bounces@debbugs.gnu.org Mon Feb 05 02:45:37 2018 Received: (at 29450-done) by debbugs.gnu.org; 5 Feb 2018 07:45:37 +0000 Received: from localhost ([127.0.0.1]:57652 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eibT6-0004KB-UI for submit@debbugs.gnu.org; Mon, 05 Feb 2018 02:45:37 -0500 Received: from mout.gmx.net ([212.227.17.21]:61663) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eibT4-0004Jx-Hh for 29450-done@debbugs.gnu.org; Mon, 05 Feb 2018 02:45:35 -0500 Received: from detlef.gmx.de ([212.86.38.251]) by mail.gmx.com (mrgmx101 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LbA4j-1f7Eqf0XsH-00kc68; Mon, 05 Feb 2018 08:45:28 +0100 From: Michael Albinus To: John Wiegley Subject: Re: bug#29450: 26.0.90; No check for nil in some filenotify functions References: <83lgit6ocs.fsf@gnu.org> <87fu7chi6w.fsf@gmx.de> Date: Mon, 05 Feb 2018 08:45:27 +0100 In-Reply-To: (John Wiegley's message of "Sun, 04 Feb 2018 22:48:39 -0800") Message-ID: <87po5jg9rc.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K0:46BXENQ4QPhenZJJgs6UBDjjZb4gi0aaKr19d7kn3ONSPY473dU meFeH/njQ9qqTHtLYNkBKXMRnaJcv9Xq6fBPnQn/qjM7AaZzauvSoVhQpRRVfA3cvidZqIT I5pKtn4S8hXdkzjWD3FEQTnB9WWvEoJV599J1Tl8EumHSO1gYtqORI3N4xFx1w805HInPiw Iu3V4i/G5kHIw2ugaKTJQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:U9ERL7kcGmw=:n1EmU6hSoMjmQkJkBy1tLc 3Io1TsnC8DgKcsCx2Z48bSx/f71vCFWQnkH3qJHlJ7FxP55A08pJ1MUUdLhliLSM/3TT9jEuD EdM3D72kGf2ksxxvEY/2TIat9F3pHA9nxF/9qY0i/6RwdZ79QGBF2f45HdgJMHgHKUy2O7DmN DazJBNIoN+HTeXxIEN0KjgmbxlKdF7aq1ADWjz2/Fei2fBqpXrh7y2T+tx5zoDrc/yDnbe6Pv WoSetSyMFUHDeiUAzDkUV2XyLwQmscV2vze7ads6p6uG3PXQ2hEA16VB27l4wJ/B2C5CQzVyt 7ufAqWPx2xsm+fVpPpMvsnJzGwyAe5T1ft48XIKgBPtW4we9NQu0RkCd/Qn5aQsOhaU77D9Fn Epy2Dh6WP+pipPhcb2HgDdeoDyKlOpminNBA1tfr6pmAR0e2AobuHczGivQoz1+moQSmJHrOK YS70v6UP+zOjf3mbds7Sya8ua16NuEB7JL/bbGu27PjXnm23+3rsTnM5cd2BkxGTEMvQbPlCb VuV4vgHDaQ9qjmdY/Z94TB2tZymWN7M3TGVekWus0YXxpBiWeSOrpo9aepiQxiBvjVdigIjXy 5vZwry+ZX1Q1JQ08y4WFLNCtpr+/wGBtSxw2jPteOsMj/9wQuSxKpXgmXCDEIAwhr6LC7r6/y QGDcbmh82utC0GS77VLe8M5FspaEgJguf6fqg+Vh9R4mJYkAuhC4OHk6+Yf7GPIgPwZOtO9GD HcB4ugYlLXOld+INCW8f3MgMftqR87HngbPaAXtaJwTn8mCzCO+cEsJ94k+UFEEYuuYVH6VeP exSEoMoaqUNZGY7xLpfUqXSNxj5fS2EGW4bNyoRDN1XId+yZ4w= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 29450-done Cc: Glenn Morris , 29450-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) John Wiegley writes: Hi John, > I've had file-notify back on for a few days now, and this has not happened > again, so I'm fine with closing this issue. I do it herewith. > However -- and this is a separate bug -- I had to disable it again because it > was stalling out Emacs regularly. I'd ran an operation that changed the state > of the disk, and then Emacs would be locked up for minutes at a time until I > hit C-g repeatedly. Finally, I ran Instruments to see what was going on, and > it was stuck in a busy loop reading directories, spending 92% of its time > calling delq over and over again. In function `file-notify-handle-event', there's a commented `message' call. Could you enable this, and send the output when this problem happens, again? > But that's a separate issue, and disabling file-notify cured the performance > problem. Do you write another bug report for this? Best regards, Michael. From unknown Fri Jun 20 20:02:37 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 05 Mar 2018 12:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator