GNU bug report logs - #65035
29.1; Port flycheck-emacs-lisp-initialize-packages to flymake

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Antonio Romano <n58r@HIDDEN>; dated Thu, 3 Aug 2023 10:05:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 28 Dec 2024 11:08:48 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 28 06:08:48 2024
Received: from localhost ([127.0.0.1]:48948 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tRUgZ-0006Ou-VF
	for submit <at> debbugs.gnu.org; Sat, 28 Dec 2024 06:08:48 -0500
Received: from eggs.gnu.org ([209.51.188.92]:40510)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1tRUgX-0006Oi-RM
 for 65035 <at> debbugs.gnu.org; Sat, 28 Dec 2024 06:08:46 -0500
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1tRUgS-00068Z-9G; Sat, 28 Dec 2024 06:08:40 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=PwxuTq8zNJytW64Uge69yNtYew/J9ZsC5UCgA/RiYRk=; b=fBOaQmGMOOPv
 gKM4XN52bi3Afe47LXPWvL1eOmU80E+HaE8HDcU6aLXsWTbrAY71zakUD+nG83OL+d5dP4/udfqp/
 9Ng6M1tHJoE/Kg//1j832PP6m+TKxF5+n0ldWnLY0XU7VZx74S+D8OPJSSc228cTPPvDccMqYFlcM
 IQK6AqXkpIFrUaY7FyIM4OQMqrzYVI8b62jk28UNG64llMRuqRttw2G0MqiPoBnHuvHeEOHh7fzcz
 xOZfJHjx0yfS52jle15447QnW6tMs7CJkevZDH6FEbOl7SDEDgOTHavnURFaiMckBT6s6YvJuzvJA
 lEKvQL/gOuKu1A9q+qnoDw==;
Date: Sat, 28 Dec 2024 13:08:25 +0200
Message-Id: <86o70wt68m.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: sbaugh@HIDDEN
In-Reply-To: <864j36wqux.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 14
 Dec 2024 11:33:58 +0200)
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
 <iero72kt8uc.fsf@HIDDEN> <87msi23vyb.fsf@HIDDEN>
 <868qt19hno.fsf@HIDDEN> <864j36wqux.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 65035
Cc: me@HIDDEN, joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ping! Ping! Ping!

> Cc: 65035 <at> debbugs.gnu.org, joaotavora@HIDDEN, me@HIDDEN
> Date: Sat, 14 Dec 2024 11:33:58 +0200
> From: Eli Zaretskii <eliz@HIDDEN>
> 
> Ping! Ping!
> 
> > Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
> > Date: Sat, 30 Nov 2024 11:48:11 +0200
> > From: Eli Zaretskii <eliz@HIDDEN>
> > 
> > Ping!  Can we make some progress with this bug report?
> > 
> > > Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
> > > From: Pengji Zhang <me@HIDDEN>
> > > Date: Thu, 14 Nov 2024 19:18:20 +0800
> > > 
> > > Spencer Baugh <sbaugh@HIDDEN> writes:
> > > 
> > > > I think this should also switch from passing "-Q" to passing just
> > > > "-q". If we're include ~/.emacs.d/elpa on load-path, we should include
> > > > the site-lisp directories too, which -Q suppresses.
> > > 
> > > I agree. How about the following change?
> > > 
> > > --8<---------------cut here---------------start------------->8---
> > >          :name "elisp-flymake-byte-compile"
> > >          :buffer output-buffer
> > >          :command `(,(expand-file-name invocation-name invocation-directory)
> > > -                   "-Q"
> > > +                   ,@(if elisp-flymake--byte-compile-activate-packages
> > > +                         ;; Add site-lisp directories to `load-path' so
> > > +                         ;; that system-wide packages (installed into
> > > +                         ;; site-lisp/elpa) are activated.
> > > +                         '("-q" "--no-site-file")
> > > +                       '("-Q"))
> > >                     "--batch"
> > >                     ;; "--eval" "(setq load-prefer-newer t)" ; for testing
> > >                     ,@(mapcan (lambda (path) (list "-L" path))
> > > --8<---------------cut here---------------end--------------->8---
> > > 
> > > > Probably we should specifically pass "--batch --no-site-file" instead
> > > > of "-Q --batch", since --batch also implies -q.
> > > 
> > > I am not sure if it is a good idea to always include the site-lisp
> > > directories. I myself want this only when checking my init.el. When
> > > developing packages, I prefer a pristine environment.
> > > 
> > > 
> > > 
> > > 
> > 
> > 
> > 
> > 
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 14 Dec 2024 09:34:17 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Dec 14 04:34:17 2024
Received: from localhost ([127.0.0.1]:45446 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tMOXQ-0006YX-EE
	for submit <at> debbugs.gnu.org; Sat, 14 Dec 2024 04:34:17 -0500
Received: from eggs.gnu.org ([209.51.188.92]:51020)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1tMOXI-0006Y9-L4
 for 65035 <at> debbugs.gnu.org; Sat, 14 Dec 2024 04:34:12 -0500
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1tMOXC-00005L-88; Sat, 14 Dec 2024 04:34:02 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=YtpTUTFJFhcrot9RVfZxC1/uTiw0DjdLBVL5tm02HbI=; b=k+APeVLU12Ck
 jBriKpQy5mfZU15bptx19Ud6k3OOXTt1qcH0YXu0iSohdo5sLSG1fMk85W88eK04zQK/LVMbRr7Fz
 hltvXW8Jgk3rUZ8blILUGOPunrKH1mix0xZ5Yvklo1gGC/gWjyAQuw0VcKFw/S7zlBI/9fMgWCP59
 7zgynzOusoRmukm+zXd5StOJM6vnnlQ1fS/o6FWcoIrV9UHUCdXxNl76WSl0Pjm5fGtAWoB1tgq0o
 H5JXvGSj1BkUkLVLOV0shFYpyOb+O4v7etb0//7t8d0bmNeusiaS3k7k9HMWDZAuK3+i5VL6zBA5o
 QhV+U4k3WHq54XSQdkCHkw==;
Date: Sat, 14 Dec 2024 11:33:58 +0200
Message-Id: <864j36wqux.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: sbaugh@HIDDEN
In-Reply-To: <868qt19hno.fsf@HIDDEN> (message from Eli Zaretskii on Sat, 30
 Nov 2024 11:48:11 +0200)
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
 <iero72kt8uc.fsf@HIDDEN> <87msi23vyb.fsf@HIDDEN>
 <868qt19hno.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 65035
Cc: 65035 <at> debbugs.gnu.org, joaotavora@HIDDEN, me@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ping! Ping!

> Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
> Date: Sat, 30 Nov 2024 11:48:11 +0200
> From: Eli Zaretskii <eliz@HIDDEN>
> 
> Ping!  Can we make some progress with this bug report?
> 
> > Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
> > From: Pengji Zhang <me@HIDDEN>
> > Date: Thu, 14 Nov 2024 19:18:20 +0800
> > 
> > Spencer Baugh <sbaugh@HIDDEN> writes:
> > 
> > > I think this should also switch from passing "-Q" to passing just
> > > "-q". If we're include ~/.emacs.d/elpa on load-path, we should include
> > > the site-lisp directories too, which -Q suppresses.
> > 
> > I agree. How about the following change?
> > 
> > --8<---------------cut here---------------start------------->8---
> >          :name "elisp-flymake-byte-compile"
> >          :buffer output-buffer
> >          :command `(,(expand-file-name invocation-name invocation-directory)
> > -                   "-Q"
> > +                   ,@(if elisp-flymake--byte-compile-activate-packages
> > +                         ;; Add site-lisp directories to `load-path' so
> > +                         ;; that system-wide packages (installed into
> > +                         ;; site-lisp/elpa) are activated.
> > +                         '("-q" "--no-site-file")
> > +                       '("-Q"))
> >                     "--batch"
> >                     ;; "--eval" "(setq load-prefer-newer t)" ; for testing
> >                     ,@(mapcan (lambda (path) (list "-L" path))
> > --8<---------------cut here---------------end--------------->8---
> > 
> > > Probably we should specifically pass "--batch --no-site-file" instead
> > > of "-Q --batch", since --batch also implies -q.
> > 
> > I am not sure if it is a good idea to always include the site-lisp
> > directories. I myself want this only when checking my init.el. When
> > developing packages, I prefer a pristine environment.
> > 
> > 
> > 
> > 
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 30 Nov 2024 09:48:23 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 30 04:48:22 2024
Received: from localhost ([127.0.0.1]:45449 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tHK5O-0006OJ-H4
	for submit <at> debbugs.gnu.org; Sat, 30 Nov 2024 04:48:22 -0500
Received: from eggs.gnu.org ([209.51.188.92]:54398)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1tHK5M-0006O5-KH
 for 65035 <at> debbugs.gnu.org; Sat, 30 Nov 2024 04:48:21 -0500
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1tHK5G-0004lP-SS; Sat, 30 Nov 2024 04:48:14 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=TW02Y4L9n2b3/zzoJdVakifspGVJwM/D95oyrPfLges=; b=a+52hE8CWXM8
 OYg2bbvbrJidu5syNqxxhh5h4ZmEbdpRAT+QPwxp4TBW0lGaqZ3trvFLX1x9nD7srtl3nm3JxL4vt
 AGkThmdIth1qrOaUP7cGEVI0pE+wPatup9PjpT/w4M2nXyT8t7mItwKCEX5yq5XkNccRwe9l/ec0B
 pIdXSly8o6DbVklUC//fpvUe6PP+B1b3kIn7nZN9x73IgPMPP/jriS+k4e8HWtNDbqmzkWzSit4Y+
 1pgUFQ+dsPubMVueTWYdjjx2ZbaBay8dAsEqbsR0X9GWZEOuwSNVqw68kOMpZbUU3EZPMV+EY2RAp
 HnP134AHEHEXTPP+zw3Upw==;
Date: Sat, 30 Nov 2024 11:48:11 +0200
Message-Id: <868qt19hno.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: sbaugh@HIDDEN, Pengji Zhang <me@HIDDEN>
In-Reply-To: <87msi23vyb.fsf@HIDDEN> (message from Pengji Zhang on Thu,
 14 Nov 2024 19:18:20 +0800)
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
 <iero72kt8uc.fsf@HIDDEN> <87msi23vyb.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 65035
Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ping!  Can we make some progress with this bug report?

> Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
> From: Pengji Zhang <me@HIDDEN>
> Date: Thu, 14 Nov 2024 19:18:20 +0800
> 
> Spencer Baugh <sbaugh@HIDDEN> writes:
> 
> > I think this should also switch from passing "-Q" to passing just
> > "-q". If we're include ~/.emacs.d/elpa on load-path, we should include
> > the site-lisp directories too, which -Q suppresses.
> 
> I agree. How about the following change?
> 
> --8<---------------cut here---------------start------------->8---
>          :name "elisp-flymake-byte-compile"
>          :buffer output-buffer
>          :command `(,(expand-file-name invocation-name invocation-directory)
> -                   "-Q"
> +                   ,@(if elisp-flymake--byte-compile-activate-packages
> +                         ;; Add site-lisp directories to `load-path' so
> +                         ;; that system-wide packages (installed into
> +                         ;; site-lisp/elpa) are activated.
> +                         '("-q" "--no-site-file")
> +                       '("-Q"))
>                     "--batch"
>                     ;; "--eval" "(setq load-prefer-newer t)" ; for testing
>                     ,@(mapcan (lambda (path) (list "-L" path))
> --8<---------------cut here---------------end--------------->8---
> 
> > Probably we should specifically pass "--batch --no-site-file" instead
> > of "-Q --batch", since --batch also implies -q.
> 
> I am not sure if it is a good idea to always include the site-lisp
> directories. I myself want this only when checking my init.el. When
> developing packages, I prefer a pristine environment.
> 
> 
> 
> 




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 14 Nov 2024 13:26:45 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Nov 14 08:26:44 2024
Received: from localhost ([127.0.0.1]:45569 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tBZrw-0006ld-DO
	for submit <at> debbugs.gnu.org; Thu, 14 Nov 2024 08:26:44 -0500
Received: from mail-ua1-f44.google.com ([209.85.222.44]:58458)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <shipmints@HIDDEN>) id 1tBZrt-0006lN-GW
 for 65035 <at> debbugs.gnu.org; Thu, 14 Nov 2024 08:26:42 -0500
Received: by mail-ua1-f44.google.com with SMTP id
 a1e0cc1a2514c-856d51de64aso183289241.0
 for <65035 <at> debbugs.gnu.org>; Thu, 14 Nov 2024 05:26:41 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1731590736; x=1732195536; darn=debbugs.gnu.org;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:from:to:cc:subject:date:message-id:reply-to;
 bh=j70UBdOdQJel7McHvikYXoZkJA2+JdYAf9If0Jy/fTM=;
 b=C8MW9xgkjJv9lJ4HcpLpFQ2dFW++PkMFR73nQEHQltDV7vURA1hx0VQxl5OasnbDzM
 KUEx/HCGMadWL3KVavwiZNz4QjOPB2be78L0jShnK3OzyRDWeETPcWLUOczwOSl9ssDK
 I7UwtXhH2KK0BWKqUIv5WdFkIrX7aCNPPa5QUsHYxqsyAtejsH9xocJATa4vMD9zUmVH
 acrLdy+xridqnLxdkCeeESURGgf3OEpZsUhoSM1aEQjI/z/MogA/YrgSRooUZR8v9tZc
 wJhXPV2ekxjaaZObEK3Ga/JwFlhsTX2jWjnH7k2h2GAGko64obSLzXJ13rlsukZgmw8X
 SCPw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1731590736; x=1732195536;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id
 :reply-to;
 bh=j70UBdOdQJel7McHvikYXoZkJA2+JdYAf9If0Jy/fTM=;
 b=EGNJFrN1/9J1YyPx8Lxj2rPjNBOpc3edJEctsswAMfYBXzaxQcEtNbZJF1dXVq2ccn
 /gdnA4zxYLK3uH0/wT30ZcwbTTIQmPUgI0q94n53MLyFLlo4WbUo3hYswjQUSo+qulxl
 ooxxijjZSDx+L/uXUma9y4BgvQXKEJVDrW6F/PeRW2Q3GAxhTmOmGhPYHRb1rYvcinLB
 SGiPEJ2q5oBTdUypnrortxGVCgk/tyxbAjpidTvnOgepajVmaTOt5Nv6cIWG7agVbqBb
 dsYBJys5boMp5Hzo7L7bTNvOHDnS5bGlaYl6wxvmECSW1OrZr6AGCt2oNZjDQ1/WXk3I
 mSMA==
X-Forwarded-Encrypted: i=1;
 AJvYcCXN/MXVy/6+/vHRGKLEeLQ1r/q4HOKArOtTZHfkt0W8qm+YdhYYjwc0qAsZ2MdEr5+c4mk0Zw==@debbugs.gnu.org
X-Gm-Message-State: AOJu0Yxbg9XvkWbA4mYZ+fG2YkDoPaBbDG6fl/l30h3lpjEO/kdUqoa9
 EV0YmaOogVGvkYNv34MWIuxzv2/xmksVmI0BkLZdwmCedyNxT0EbWCMWiVuLGWmKjzWR2+nC/Rl
 GMcU2edNft3AKorocYXFwppIFUQk=
X-Google-Smtp-Source: AGHT+IHIdfhxM/rXghbVDGYo0nWOoNzu2WI5m7sP1LXtf23AfBrUN6Yhc0vmT4nLq4PorripH9j+mWL8icagkKETL08=
X-Received: by 2002:a05:6102:dd3:b0:4ad:4ce6:709 with SMTP id
 ada2fe7eead31-4ad4ce607a4mr5902578137.6.1731590735797; Thu, 14 Nov 2024
 05:25:35 -0800 (PST)
MIME-Version: 1.0
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
 <iero72kt8uc.fsf@HIDDEN> <87msi23vyb.fsf@HIDDEN>
In-Reply-To: <87msi23vyb.fsf@HIDDEN>
From: Ship Mints <shipmints@HIDDEN>
Date: Thu, 14 Nov 2024 08:25:24 -0500
Message-ID: <CAN+1HbrM5WzD_8H7XhtuM4z=J-8trHc0PnPRymVqPerX=Xkvbg@HIDDEN>
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
To: Pengji Zhang <me@HIDDEN>
Content-Type: multipart/alternative; boundary="000000000000b427f30626df6270"
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 65035
Cc: Spencer Baugh <sbaugh@HIDDEN>, Eli Zaretskii <eliz@HIDDEN>,
 joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

--000000000000b427f30626df6270
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Not sure this is 100% relevant to the discussion, but -Q also implies
--no-site-file which inhibits site-start.el. This will interfere with Emacs
builds such as https://github.com/jimeh/emacs-builds for macOS. They
rely on site-start to establish bundled native compiler runtime
dependencies. Running a flymake batch without those dependencies may have
unintended flymake performance implications.

On Thu, Nov 14, 2024 at 6:19=E2=80=AFAM Pengji Zhang <me@HIDDEN> wrote=
:

> Spencer Baugh <sbaugh@HIDDEN> writes:
>
> > I think this should also switch from passing "-Q" to passing just
> > "-q". If we're include ~/.emacs.d/elpa on load-path, we should include
> > the site-lisp directories too, which -Q suppresses.
>
> I agree. How about the following change?
>
> --8<---------------cut here---------------start------------->8---
>          :name "elisp-flymake-byte-compile"
>          :buffer output-buffer
>          :command `(,(expand-file-name invocation-name
> invocation-directory)
> -                   "-Q"
> +                   ,@(if elisp-flymake--byte-compile-activate-packages
> +                         ;; Add site-lisp directories to `load-path' so
> +                         ;; that system-wide packages (installed into
> +                         ;; site-lisp/elpa) are activated.
> +                         '("-q" "--no-site-file")
> +                       '("-Q"))
>                     "--batch"
>                     ;; "--eval" "(setq load-prefer-newer t)" ; for testin=
g
>                     ,@(mapcan (lambda (path) (list "-L" path))
> --8<---------------cut here---------------end--------------->8---
>
> > Probably we should specifically pass "--batch --no-site-file" instead
> > of "-Q --batch", since --batch also implies -q.
>
> I am not sure if it is a good idea to always include the site-lisp
> directories. I myself want this only when checking my init.el. When
> developing packages, I prefer a pristine environment.
>
>
>
>

--000000000000b427f30626df6270
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_default" style=3D"font-family:monospac=
e">Not sure this is 100% relevant to the discussion, but -Q also implies --=
no-site-file which inhibits site-start.el. This will interfere with Emacs b=
uilds such as <a href=3D"https://github.com/jimeh/emacs-builds">https://git=
hub.com/jimeh/emacs-builds</a>=C2=A0for macOS. They rely=C2=A0on site-start=
 to establish bundled native compiler runtime dependencies. Running a flyma=
ke batch without those dependencies may=C2=A0have unintended flymake perfor=
mance implications.</div></div><br><div class=3D"gmail_quote"><div dir=3D"l=
tr" class=3D"gmail_attr">On Thu, Nov 14, 2024 at 6:19=E2=80=AFAM Pengji Zha=
ng &lt;<a href=3D"mailto:me@HIDDEN">me@HIDDEN</a>&gt; wrote:<br><=
/div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;bo=
rder-left:1px solid rgb(204,204,204);padding-left:1ex">Spencer Baugh &lt;<a=
 href=3D"mailto:sbaugh@HIDDEN" target=3D"_blank">sbaugh@janestreet.=
com</a>&gt; writes:<br>
<br>
&gt; I think this should also switch from passing &quot;-Q&quot; to passing=
 just<br>
&gt; &quot;-q&quot;. If we&#39;re include ~/.emacs.d/elpa on load-path, we =
should include<br>
&gt; the site-lisp directories too, which -Q suppresses.<br>
<br>
I agree. How about the following change?<br>
<br>
--8&lt;---------------cut here---------------start-------------&gt;8---<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0:name &quot;elisp-flymake-byte-compile&qu=
ot;<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0:buffer output-buffer<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0:command `(,(expand-file-name invocation-=
name invocation-directory)<br>
-=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0&quot=
;-Q&quot;<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0,@(if=
 elisp-flymake--byte-compile-activate-packages<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0;; Add site-lisp directories to `load-path&#39; so<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0;; that system-wide packages (installed into<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0;; site-lisp/elpa) are activated.<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0&#39;(&quot;-q&quot; &quot;--no-site-file&quot;)<br>
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0&#39;(&quot;-Q&quot;))<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 &quot=
;--batch&quot;<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 ;; &q=
uot;--eval&quot; &quot;(setq load-prefer-newer t)&quot; ; for testing<br>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 ,@(ma=
pcan (lambda (path) (list &quot;-L&quot; path))<br>
--8&lt;---------------cut here---------------end---------------&gt;8---<br>
<br>
&gt; Probably we should specifically pass &quot;--batch --no-site-file&quot=
; instead<br>
&gt; of &quot;-Q --batch&quot;, since --batch also implies -q.<br>
<br>
I am not sure if it is a good idea to always include the site-lisp<br>
directories. I myself want this only when checking my init.el. When<br>
developing packages, I prefer a pristine environment.<br>
<br>
<br>
<br>
</blockquote></div>

--000000000000b427f30626df6270--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 14 Nov 2024 11:18:44 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Nov 14 06:18:44 2024
Received: from localhost ([127.0.0.1]:45285 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tBXs3-0000hw-Rw
	for submit <at> debbugs.gnu.org; Thu, 14 Nov 2024 06:18:44 -0500
Received: from fhigh-a8-smtp.messagingengine.com ([103.168.172.159]:37289)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <me@HIDDEN>) id 1tBXs2-0000hk-TF
 for 65035 <at> debbugs.gnu.org; Thu, 14 Nov 2024 06:18:43 -0500
Received: from phl-compute-06.internal (phl-compute-06.phl.internal
 [10.202.2.46])
 by mailfhigh.phl.internal (Postfix) with ESMTP id 8CA061140175;
 Thu, 14 Nov 2024 06:18:37 -0500 (EST)
Received: from phl-mailfrontend-01 ([10.202.2.162])
 by phl-compute-06.internal (MEProxy); Thu, 14 Nov 2024 06:18:37 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pengjiz.com; h=
 cc:cc:content-type:content-type:date:date:from:from:in-reply-to
 :in-reply-to:message-id:mime-version:references:reply-to:subject
 :subject:to:to; s=fm1; t=1731583117; x=1731669517; bh=u3sNNhyERj
 Xy+dD2v1wrohRt/sKPaO5Yn0ro82JsjLU=; b=dGivCy+qQe6edUolqmLXb/+mRU
 wsHlYVMmAjd+n5Ool38bVxXNHEn9UU5hBQza3KAp54nBaeZVgU7jbO1fC2avSIhY
 uzwDm6ZQ1kcA45ODpxqhaedmsjvSzpoVujzkkx4M8SGmICnqObZCJCziRvM5lX9+
 D+cPOyzp8M//uhfA9V9z7GQEeIOLxPnMSdN/9pjsvPZexPDN0ZDCyJxN6jcRDJGL
 8kxcwq9gGos0TnxeBUZzMWqREUV1X7ZungDYfUnoij7WLKh6FIjjS5NK9j1MRjIL
 Z7E9mUBcAQQUYvuNsZ0oBjOrNUgYl09HnBxB1Ptd0+2OSMSzYx1hQyKdPJmw==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:cc:content-type:content-type:date:date
 :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to
 :message-id:mime-version:references:reply-to:subject:subject:to
 :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=
 1731583117; x=1731669517; bh=u3sNNhyERjXy+dD2v1wrohRt/sKPaO5Yn0r
 o82JsjLU=; b=FJdHUkzsnpi6X7Um5Huii+07cN1QiPd35ToSeKLr5WeEi+QNCmz
 sNnPkRdhpgyCPUIelwoE77dWPkbxVZ2d6mLedJ50kL/Ndn7uGP0dcvdA5xFNO0GA
 ePmxrb0Q4cYcx4FRJ7hP3Fj9o0SCjzUA8pJv6szPzoBNcoqWJ78TD8qbMTWVcymd
 jqfTC0HQDU6m5sRgYX+F/CKavPFOKzAC3FHp1/+YHW3NOM2e82VBEPmoEa/O4Nsi
 KZ5N0aStrwecgZopD/urCXXWnAU+YeFcgUBC9yV8VtuGy0aDa0GJvvjaJDW2wFCE
 ba1UXc1ccwMw6rbjkKh/kCODsgHFv1/UMig==
X-ME-Sender: <xms:jdw1ZzwuT6MH6cvapZ-hfouAVJNcCbe0c9TuR0ZhyWKUGDAFflgTog>
 <xme:jdw1Z7SzhpsmFu-WzPOwom39xbq9KSYzJcmOih_aGWnRMqMTd6f7wWvPeKjiHzNTK
 Gf6T1qxhGeCs9HguX0>
X-ME-Received: <xmr:jdw1Z9WTHvcGYmGMRilckVbA_hVPpqQyXlbi8kK5h4UWj-WJJlY_HA1ljOtD9w>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrvddvgddviecutefuodetggdotefrodftvf
 curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr
 tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth
 hsucdlqddutddtmdenucfjughrpefhvfevufgjfhffkfggtgesthdtredttddttdenucfh
 rhhomheprfgvnhhgjhhiucgkhhgrnhhguceomhgvsehpvghnghhjihiirdgtohhmqeenuc
 ggtffrrghtthgvrhhnpeegfeeiiedvudekiedtgedufedtvedtueetieffhfdvhefftefg
 ieejieelleehgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh
 hrohhmpehmvgesphgvnhhgjhhiiidrtghomhdpnhgspghrtghpthhtohepgedpmhhouggv
 pehsmhhtphhouhhtpdhrtghpthhtohepshgsrghughhhsehjrghnvghsthhrvggvthdrtg
 homhdprhgtphhtthhopegvlhhiiiesghhnuhdrohhrghdprhgtphhtthhopehjohgrohht
 rghvohhrrgesghhmrghilhdrtghomhdprhgtphhtthhopeeihedtfeehseguvggssghugh
 hsrdhgnhhurdhorhhg
X-ME-Proxy: <xmx:jdw1Z9i7FfRbKLiZKEEBCgQ6MynFXEaN4txHAAyqAJA95yljGHJ04w>
 <xmx:jdw1Z1DPaCu7XqXHb4S-wvR8-YJcK3iTGVEY0Evv7z6FM71Do3hXLA>
 <xmx:jdw1Z2LBiKRcZx8UG0p6kxpkN8XyUnJdXKJQGdD4S_8SnngfPmKpew>
 <xmx:jdw1Z0D07aAG0RUEGzaoUizj0_nKMjQaJJwrc0eH0nj44YD5YayG-Q>
 <xmx:jdw1Z47ln7HPGfyhIN-TSe8X1FYKVgJ6y2607WQfiNV9gfHR5tN3nqQw>
Feedback-ID: i16614472:Fastmail
Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu,
 14 Nov 2024 06:18:36 -0500 (EST)
From: Pengji Zhang <me@HIDDEN>
To: Spencer Baugh <sbaugh@HIDDEN>, Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#65035: 29.1; Port flycheck-emacs-lisp-initialize-packages
 to flymake
In-Reply-To: <iero72kt8uc.fsf@HIDDEN>
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
 <iero72kt8uc.fsf@HIDDEN>
Date: Thu, 14 Nov 2024 19:18:20 +0800
Message-ID: <87msi23vyb.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 65035
Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

Spencer Baugh <sbaugh@HIDDEN> writes:

> I think this should also switch from passing "-Q" to passing just
> "-q". If we're include ~/.emacs.d/elpa on load-path, we should include
> the site-lisp directories too, which -Q suppresses.

I agree. How about the following change?

--8<---------------cut here---------------start------------->8---
         :name "elisp-flymake-byte-compile"
         :buffer output-buffer
         :command `(,(expand-file-name invocation-name invocation-directory)
-                   "-Q"
+                   ,@(if elisp-flymake--byte-compile-activate-packages
+                         ;; Add site-lisp directories to `load-path' so
+                         ;; that system-wide packages (installed into
+                         ;; site-lisp/elpa) are activated.
+                         '("-q" "--no-site-file")
+                       '("-Q"))
                    "--batch"
                    ;; "--eval" "(setq load-prefer-newer t)" ; for testing
                    ,@(mapcan (lambda (path) (list "-L" path))
--8<---------------cut here---------------end--------------->8---

> Probably we should specifically pass "--batch --no-site-file" instead
> of "-Q --batch", since --batch also implies -q.

I am not sure if it is a good idea to always include the site-lisp
directories. I myself want this only when checking my init.el. When
developing packages, I prefer a pristine environment.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 12 Nov 2024 21:56:20 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Nov 12 16:56:20 2024
Received: from localhost ([127.0.0.1]:39757 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tAyrz-000717-Sa
	for submit <at> debbugs.gnu.org; Tue, 12 Nov 2024 16:56:20 -0500
Received: from mxout5.mail.janestreet.com ([64.215.233.18]:37975)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <sbaugh@HIDDEN>) id 1tAyrw-00070r-Uu
 for 65035 <at> debbugs.gnu.org; Tue, 12 Nov 2024 16:56:18 -0500
From: Spencer Baugh <sbaugh@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#65035: 29.1; Port flycheck-emacs-lisp-initialize-packages
 to flymake
In-Reply-To: <86y11sn4rw.fsf@HIDDEN> (Eli Zaretskii's message of "Sat, 09 Nov
 2024 11:19:15 +0200")
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
Date: Tue, 12 Nov 2024 16:56:11 -0500
Message-ID: <iero72kt8uc.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=janestreet.com;
 s=waixah; t=1731448571;
 bh=LXo7vMjwFE399bFWQgpM1cF4ZDtvgnFVzvbpGHfUA9I=;
 h=From:To:Cc:Subject:In-Reply-To:References:Date;
 b=wRc5kRfV55m3wczzhh3cX8w9wYh6PS5CMdHprqXi4V9r3m3WTnPKoZ4D1OGkMRY7Q
 hdaXmuV7FzSpEyjGqHdj1QLhsmhs1FhvbR+ggI6uE5PCOVXG4WnMp9W8XFXaJhoRNo
 ygwm+TTeKXveHdsSjug4MJdbvRJ74hATOshnhOxK3gXMImIwBmf+VOJ9CMxpSpTg3X
 LjmN0FqyvC69MBJVRbedMSzLx4sFxVtUMIjdpdQskOHxScHMFW8HLa1tY6IWnGyjsc
 IlG2S2dCEhoQmS2H31PWZbCNZH7mQ4Sc/nwtb+HW9RbcRzN2l1HZMghpgDBecCY0XR
 e06kNinzs7Iew==
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 65035
Cc: 65035 <at> debbugs.gnu.org, joaotavora@HIDDEN, Pengji Zhang <me@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:
>> From: Pengji Zhang <me@HIDDEN>
>> Cc: sbaugh@HIDDEN, Jo=C3=A3o T=C3=A1vora
>>  <joaotavora@HIDDEN>, Eli Zaretskii
>>  <eliz@HIDDEN>
>> Date: Fri, 25 Oct 2024 19:50:48 +0800
>>=20
>> Jo=C3=A3o T=C3=A1vora <joaotavora@HIDDEN> writes:
>>=20
>> > Feel free to use my patch of course.  Stefan noted some time ago
>> > that -f package-initialize is the wrong flag to ask Emacs -Q to use
>> > elpa though, so there's something better.
>>=20
>> Thanks! I prepared a new patch based on yours.
>
> Thanks.  Spencer, any comments?

I think this should also switch from passing "-Q" to passing just "-q".
If we're include ~/.emacs.d/elpa on load-path, we should include the
site-lisp directories too, which -Q suppresses.

Probably we should specifically pass "--batch --no-site-file" instead of
"-Q --batch", since --batch also implies -q.

(This is particularly relevant for my site, where most packages are
distributed via site-lisp/elpa rather than installed into
package-user-dir)




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 10 Nov 2024 01:34:00 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 09 20:34:00 2024
Received: from localhost ([127.0.0.1]:55005 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t9wq0-0002qN-4O
	for submit <at> debbugs.gnu.org; Sat, 09 Nov 2024 20:34:00 -0500
Received: from fout-b8-smtp.messagingengine.com ([202.12.124.151]:40107)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <me@HIDDEN>) id 1t9wpx-0002q7-Ow
 for 65035 <at> debbugs.gnu.org; Sat, 09 Nov 2024 20:33:58 -0500
Received: from phl-compute-05.internal (phl-compute-05.phl.internal
 [10.202.2.45])
 by mailfout.stl.internal (Postfix) with ESMTP id 713EE1140100;
 Sat,  9 Nov 2024 20:33:52 -0500 (EST)
Received: from phl-mailfrontend-01 ([10.202.2.162])
 by phl-compute-05.internal (MEProxy); Sat, 09 Nov 2024 20:33:52 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pengjiz.com; h=
 cc:cc:content-type:content-type:date:date:from:from:in-reply-to
 :in-reply-to:message-id:mime-version:references:reply-to:subject
 :subject:to:to; s=fm1; t=1731202432; x=1731288832; bh=0RzN0ReTYN
 l/hvsUELkvGHWL9RXPnq1Qu+9ORBZYjEY=; b=gBcRZV3yFVdgwSUX4Fr48fgYvE
 keQtkAUin9ohMgozzpAiWDXdYmJAId6cHwXTkL5MxcLtwjoWVCKTnFzh3jEjCkMv
 OJN38eCNzc7U3nKfsgoDl9Gk5fxTexX/1RwKnt/Ghac4cbQZqfuzd9Ss28SZ6LKy
 XmlXASodTOmvN3ZEKZKAnam2DpgrJeOlzKjersfZBuD3z0SGGs5wlvFP03YHYPIL
 V1zhf1+K2yV6s7VbcAABpSBO2m+h41Ul6gQP/4UYqHe7uN9IEXzqBDWvDDsJMDRS
 B9CS974IWcEu8cvS2mr/8zHf9tHOiGsWWWft16SmstbXt65JxAC+FqdBz6QA==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:cc:content-type:content-type:date:date
 :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to
 :message-id:mime-version:references:reply-to:subject:subject:to
 :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=
 1731202432; x=1731288832; bh=0RzN0ReTYNl/hvsUELkvGHWL9RXPnq1Qu+9
 ORBZYjEY=; b=AH4GNw7e8b4hWO8S33EDS/G3aQJjP6YI3QX2DAyDiRc2BShgL8k
 ik9+Sjg95ByaN0+KC+vSS0kIRTB02k5PB00LLU6nHbcW9EL/5sIK6NX8RHcFDnpB
 i0RmBNM/2YyUtozPKhECIXOs2fkkVxRFRBKrJOCxwacNvu+xjJOY+VQ0e4ZoGTPT
 ngEB68t/xsucj475WfqGyVpyBm1+CMgQqJf9uvoyQe64Zt1yCH4few6oocDtaH9p
 NNEZIhPS77uO16+EnIj1SdHUfRBw859K1sHqSpIj7BjGf6QNIF58qffzJ0kB6Wvp
 WQbao6dSdC2JuBRDCi7jaGyM/j47wl/7gIg==
X-ME-Sender: <xms:fw0wZ5NCWUXXC4DMG6qlCw3f6FsmBNhFls3zYXi7Us6qIEE6YizGQA>
 <xme:fw0wZ7-GS9qhfJDa5RcLL8Dg2xmTQQES6LmYHD2Hanlbh6aXrIGmUdZ1MvK8rr1iI
 GPqsVTEKspRTv5vGoU>
X-ME-Received: <xmr:fw0wZ4RRrJ6R3F7kSN7jU3o751gh2N5Oqw3P4QTrY8xN8o4-X9MNAKUWK6pFaw>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrtdelgdefiecutefuodetggdotefrodftvf
 curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr
 tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth
 hsucdlqddutddtmdenucfjughrpefhvfevufgjfhffkfggtgesmhdtreertddttdenucfh
 rhhomheprfgvnhhgjhhiucgkhhgrnhhguceomhgvsehpvghnghhjihiirdgtohhmqeenuc
 ggtffrrghtthgvrhhnpeeifffgieeulefgjeejiedvleehffffueeiiefhhfffveejuefh
 gedvhfekgfelkeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh
 hrohhmpehmvgesphgvnhhgjhhiiidrtghomhdpnhgspghrtghpthhtohepgedpmhhouggv
 pehsmhhtphhouhhtpdhrtghpthhtohepvghlihiisehgnhhurdhorhhgpdhrtghpthhtoh
 epshgsrghughhhsehjrghnvghsthhrvggvthdrtghomhdprhgtphhtthhopeeihedtfeeh
 seguvggssghughhsrdhgnhhurdhorhhgpdhrtghpthhtohepjhhorghothgrvhhorhgrse
 hgmhgrihhlrdgtohhm
X-ME-Proxy: <xmx:fw0wZ1u5LkO4o0C7T9KLkTJryRfyHHfbtuIJjy8KPs75snF9S2lZKg>
 <xmx:fw0wZxdylJv_b7LM9ak7RwH_7V10M21DsQubxdf6e6Zsc_XOa-FBHA>
 <xmx:fw0wZx3azzzTw5O5sQX1YoGylkdGPWxXeRrLQlZOWZG6NJmyOQMOPw>
 <xmx:fw0wZ999z02IwSP4Khc6Mfsr_TPUpqXOrXHx3aGS9DNKOo15d8lQeA>
 <xmx:gA0wZ45JGe4i1v6sAeElQ4MYmhwEin6AXJPuOdKDHErwoxrpkP-cjf9f>
Feedback-ID: i16614472:Fastmail
Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sat,
 9 Nov 2024 20:33:50 -0500 (EST)
From: Pengji Zhang <me@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>, sbaugh@HIDDEN
Subject: Re: bug#65035: 29.1; Port flycheck-emacs-lisp-initialize-packages
 to flymake
In-Reply-To: <86y11sn4rw.fsf@HIDDEN>
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN> <86y11sn4rw.fsf@HIDDEN>
Date: Sun, 10 Nov 2024 09:33:30 +0800
Message-ID: <87y11rj2j9.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 65035
Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

--=-=-=
Content-Type: text/plain

Eli Zaretskii <eliz@HIDDEN> writes:

> I think the doc string should explicitly mention
> elisp-flymake-byte-compile-user-file-p, since it is used as the
> default value of the option.
>
> [...]
>
> Please add a :version tag here.

Thanks for the review! Fixed in the attached updated patch.

Pengji


--=-=-=
Content-Type: text/x-patch; charset=utf-8
Content-Disposition: inline;
 filename=0001-Add-option-elisp-flymake-byte-compile-activate-packa.patch
Content-Transfer-Encoding: quoted-printable

From 6d34dcc9de1f99c795d0a6bcaa416e29c8500eed Mon Sep 17 00:00:00 2001
From: Pengji Zhang <me@HIDDEN>
Date: Sun, 10 Nov 2024 09:30:01 +0800
Subject: [PATCH] Add option 'elisp-flymake-byte-compile-activate-packages'
MIME-Version: 1.0
Content-Type: text/plain; charset=3DUTF-8
Content-Transfer-Encoding: 8bit

This option controls whether the Flymake Emacs Lisp
byte-compiler should activate user installed packages before
checking the source buffer.  (Bug#65035)

* lisp/progmodes/elisp-mode.el
(elisp-flymake-byte-compile-user-file-p): New predicate function
to check if a buffer is visiting a user file.
(elisp-flymake-byte-compile-activate-packages): New option.
(elisp-flymake--byte-compile-activate-packages): New variable
for caching.
(elisp-flymake-byte-compile): Use the new option.

* etc/NEWS: Announce the new option.

Co-authored-by: Jo=C3=A3o T=C3=A1vora <joaotavora@HIDDEN>
---
 etc/NEWS                     |  7 ++++++
 lisp/progmodes/elisp-mode.el | 46 ++++++++++++++++++++++++++++++++++++
 2 files changed, 53 insertions(+)

diff --git a/etc/NEWS b/etc/NEWS
index a6c2c895985..090f4293c8e 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -413,6 +413,13 @@ This affects calls to 'warn', 'lwarn', 'display-warnin=
g', and
 In most cases, having it enabled leads to a large amount of false
 positives.
=20
+---
+*** New user option 'elisp-flymake-byte-compile-activate-packages'.
+This option controls whether or not the Flymake byte-compiler backend
+should activate user installed packages before compiling the source
+buffer.  By default, it is set to activate packages when checking user
+configuration files.  Set it to nil to restore the previous behavior.
+
 ** DocView
=20
 ---
diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el
index 2f931daedc7..3905300c9a8 100644
--- a/lisp/progmodes/elisp-mode.el
+++ b/lisp/progmodes/elisp-mode.el
@@ -2190,6 +2190,44 @@ elisp-flymake-byte-compile-load-path
=20
 (defvar bytecomp--inhibit-lexical-cookie-warning)
=20
+(defun elisp-flymake-byte-compile-user-file-p (buffer)
+  "Return non-nil if BUFFER is visiting a user file.
+That means either the file is `user-init-file' or it is in
+`user-emacs-directory'."
+  (when-let* ((file (buffer-local-value 'buffer-file-truename buffer)))
+    (or (and user-emacs-directory
+             (file-in-directory-p file user-emacs-directory))
+        (and user-init-file
+             (string=3D file (abbreviate-file-name
+                            (file-truename user-init-file)))))))
+
+(defcustom elisp-flymake-byte-compile-activate-packages
+  #'elisp-flymake-byte-compile-user-file-p
+  "Whether to activate packages for Flymake elisp byte-compilation.
+If the value is nil, do not activate installed packages.  If the value
+is a function, it is called with one argument, the source buffer to be
+checked, and installed packages are activated if the function returns
+non-nil.  Otherwise, packages are always activated.
+
+The default value is a predicate function
+`elisp-flymake-byte-compile-user-file-p' (which see), and that means
+packages are activated only for user configuration files.
+
+Note that for efficiency the return value of the predicate function is
+cached the first time it is called.  Type \\[revert-buffer-quick] to
+invalidate the cached value."
+  :type '(choice
+          (const :tag "Don't activate" nil)
+          (const :tag "Always activate" t)
+          (const :tag "Activate for user files"
+                 elisp-flymake-byte-compile-user-file-p)
+          (function :tag "Predicate function"))
+  :group 'lisp
+  :version "31.1")
+
+(defvar-local elisp-flymake--byte-compile-activate-packages :unset
+  "Cached value for `elisp-flymake-byte-compile-activate-packages'.")
+
 ;;;###autoload
 (defun elisp-flymake-byte-compile (report-fn &rest _args)
   "A Flymake backend for elisp byte compilation.
@@ -2205,6 +2243,12 @@ elisp-flymake-byte-compile
     (save-restriction
       (widen)
       (write-region (point-min) (point-max) temp-file nil 'nomessage))
+    (when (eq elisp-flymake--byte-compile-activate-packages :unset)
+      (setq elisp-flymake--byte-compile-activate-packages
+            (if (functionp elisp-flymake-byte-compile-activate-packages)
+                (funcall elisp-flymake-byte-compile-activate-packages
+                         source-buffer)
+              elisp-flymake-byte-compile-activate-packages)))
     (let* ((output-buffer (generate-new-buffer " *elisp-flymake-byte-compi=
le*"))
            ;; Hack: suppress warning about missing lexical cookie in
            ;; *scratch* buffers.
@@ -2223,6 +2267,8 @@ elisp-flymake-byte-compile
                    ;; "--eval" "(setq load-prefer-newer t)" ; for testing
                    ,@(mapcan (lambda (path) (list "-L" path))
                              elisp-flymake-byte-compile-load-path)
+                   ,@(when elisp-flymake--byte-compile-activate-packages
+                       '("-f" "package-activate-all"))
                    ,@warning-suppression-opt
                    "-f" "elisp-flymake--batch-compile-for-flymake"
                    ,temp-file)
--=20
2.47.0


--=-=-=--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 9 Nov 2024 09:19:29 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 09 04:19:29 2024
Received: from localhost ([127.0.0.1]:53411 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t9hcu-0001cb-M0
	for submit <at> debbugs.gnu.org; Sat, 09 Nov 2024 04:19:28 -0500
Received: from eggs.gnu.org ([209.51.188.92]:58958)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1t9hcr-0001cM-HM
 for 65035 <at> debbugs.gnu.org; Sat, 09 Nov 2024 04:19:26 -0500
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1t9hcm-0001vc-0B; Sat, 09 Nov 2024 04:19:20 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=r6ExyN7YMP3KrdDcdY2RbQpzxT3qUurt+wEmAYHqn9w=; b=TH5Fpl1IFglXYwVB5ihw
 Geb6qBRJJWWxJLS0uZGkop5yNaaRHlrDDr3PNhLa+jb8EzljrFlfPHKX86ZbdHMbzOZWhccg/FeqA
 cyf//qgODw5MD3C7/kgncfV40yAFnS75DnfpUexiKDz8tj39c3hf6L/N1yA5JmgrCgeJqrz8anGQI
 3TNnCqR9Vbs/75nGzr8aZ1GZtO8qCUHb8LiDCdm/EGk5twidcNwKbCo+CrviJdj054v/2q7UI1FRn
 FX7TVI6+bJ13JgY/eIMC6m2APtmRMjrYqwxxGvrI6YW0RUTEsBzF3KY5f8lXIxrTgmCb7bzXnmFey
 7Cnr5stgwaGQTA==;
Date: Sat, 09 Nov 2024 11:19:15 +0200
Message-Id: <86y11sn4rw.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Pengji Zhang <me@HIDDEN>, sbaugh@HIDDEN
In-Reply-To: <87ed44s8o7.fsf@HIDDEN> (message from Pengji Zhang on Fri,
 25 Oct 2024 19:50:48 +0800)
Subject: Re: bug#65035: 29.1; Port flycheck-emacs-lisp-initialize-packages
 to flymake
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
 <87ed44s8o7.fsf@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 65035
Cc: joaotavora@HIDDEN, 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Pengji Zhang <me@HIDDEN>
> Cc: sbaugh@HIDDEN, João Távora
>  <joaotavora@HIDDEN>, Eli Zaretskii
>  <eliz@HIDDEN>
> Date: Fri, 25 Oct 2024 19:50:48 +0800
> 
> João Távora <joaotavora@HIDDEN> writes:
> 
> > Feel free to use my patch of course.  Stefan noted some time ago
> > that -f package-initialize is the wrong flag to ask Emacs -Q to use
> > elpa though, so there's something better.
> 
> Thanks! I prepared a new patch based on yours.

Thanks.  Spencer, any comments?

> +(defcustom elisp-flymake-byte-compile-activate-packages
> +  #'elisp-flymake-byte-compile-user-file-p
> +  "Whether to activate packages for Flymake elisp byte-compilation.
> +If the value is nil, do not activate installed packages.  If the value
> +is a function, it is called with one argument, the source buffer to be
> +checked, and installed packages are activated if the function returns
> +non-nil.  Otherwise, packages are always activated.
> +
> +Note that for efficiency the return value of the predicate function is
> +cached the first time it is called.  Type \\[revert-buffer-quick] to
> +invalidate the cached value."

I think the doc string should explicitly mention
elisp-flymake-byte-compile-user-file-p, since it is used as the
default value of the option.

> +  :type '(choice
> +          (const :tag "Don't activate" nil)
> +          (const :tag "Always activate" t)
> +          (const :tag "Activate for user files"
> +                 elisp-flymake-byte-compile-user-file-p)
> +          (function :tag "Predicate function"))
> +  :group 'lisp)

Please add a :version tag here.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 25 Oct 2024 11:51:44 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Oct 25 07:51:44 2024
Received: from localhost ([127.0.0.1]:37581 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t4Ir2-0008AE-0E
	for submit <at> debbugs.gnu.org; Fri, 25 Oct 2024 07:51:44 -0400
Received: from fout-b3-smtp.messagingengine.com ([202.12.124.146]:52111)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <me@HIDDEN>) id 1t4Iqz-0008A0-Mx
 for 65035 <at> debbugs.gnu.org; Fri, 25 Oct 2024 07:51:42 -0400
Received: from phl-compute-11.internal (phl-compute-11.phl.internal
 [10.202.2.51])
 by mailfout.stl.internal (Postfix) with ESMTP id 32AF91140133;
 Fri, 25 Oct 2024 07:51:03 -0400 (EDT)
Received: from phl-mailfrontend-01 ([10.202.2.162])
 by phl-compute-11.internal (MEProxy); Fri, 25 Oct 2024 07:51:03 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pengjiz.com; h=
 cc:cc:content-type:content-type:date:date:from:from:in-reply-to
 :in-reply-to:message-id:mime-version:references:reply-to:subject
 :subject:to:to; s=fm1; t=1729857063; x=1729943463; bh=lFkoXcwAkR
 HZG7AZOV3x5bvhG51RkGNJ5w9lQT6q/x0=; b=QMJ/EdWn2UO5B9a9aLjwVyIXPG
 4xDDLMgSOvRsnyAX7CqbsQ3kTkXzRp0Mg5NZg9kBR4T4YI7ZRsE+kfLyhOSEMks9
 G5z2yBsLEZ0akLYQnAy1RUEY/IJQ0tNK6548qCOAGyKAQFQz9cvyMfYYRDmJxVak
 BmpUPCQggSoJF2GKHGOABWl9JNgwizJkltS+YMnEMOqHYBO/Rwrt0TJ43gvmT7K9
 P4hV2lA7I7c4R4x5g1KngJShI0Ry12/a3gNZbyX6yI4CK9KnbhR48wlkbJqk7NL1
 mphdZ3+Q1MNLCCLyyCq1sHcNTIcf+jqlLEK4Li5TB6bvMpHMsp77ZyRAlhwg==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:cc:content-type:content-type:date:date
 :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to
 :message-id:mime-version:references:reply-to:subject:subject:to
 :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=
 fm3; t=1729857063; x=1729943463; bh=lFkoXcwAkRHZG7AZOV3x5bvhG51R
 kGNJ5w9lQT6q/x0=; b=ci1evgEjPGcwJ0sgzXyHxldjk3pK7yoOK7cRYh2+oY/+
 CAebqCTTMVA4FO4UxXyesEoPWgEsCDEg3BBtXz0FY1UUdLFnAKt1DvqESDWA3L8S
 47JIkf2+Y8nEapIlmbnVOTUVk+poeOFzTubrGszAUHlsb4+edLO4kJzB3/tCf2Qq
 JjcGpWDbH0V/vnh2ozzOxsIABNcu54qBV5HP4E9AHGO8aTxero/+B7PGWcd2dM3H
 cmQVsBdhejIOWi4nClZ8s3LYymjR0Sx5GP8QMqt8AZfHe0KSQafYEMRIarKafM3Z
 4f/SuUVO1Oz6BW/XaLCibwOHusiq1n3edlxdMTaxEA==
X-ME-Sender: <xms:JoYbZ2jQPvOihHGoJEwvXWV3PQtiQNsYcGJjOcM30oEXIpM76t33bQ>
 <xme:JoYbZ3BI0piMFrOXgSB6qjvVO2ZZBN7eMVG3KYRz_TS3oSEATruc7HYBP_P_yjdiL
 p-1bMOJ8XURQeghSXg>
X-ME-Received: <xmr:JoYbZ-HPPd2aBy-oZ4TLBUCTpcDOh0IurWCwMI9l1VfYVzFNKQIpNqq9VGc2-g>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrvdejvddggeehucetufdoteggodetrfdotf
 fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdggtfgfnhhsuhgsshgtrhhisggvpdfu
 rfetoffkrfgpnffqhgenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnh
 htshculddquddttddmnecujfgurhephffvvefujghffffkgggtsehmtderredttdejnecu
 hfhrohhmpefrvghnghhjihcukghhrghnghcuoehmvgesphgvnhhgjhhiiidrtghomheqne
 cuggftrfgrthhtvghrnhepkeevieekgfeiudeuvefgieevfeejhfffkefhgeegfedtgeek
 tdegueejffdugeetnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilh
 hfrhhomhepmhgvsehpvghnghhjihiirdgtohhmpdhnsggprhgtphhtthhopeegpdhmohgu
 vgepshhmthhpohhuthdprhgtphhtthhopeeihedtfeehseguvggssghughhsrdhgnhhurd
 horhhgpdhrtghpthhtohepshgsrghughhhsehjrghnvghsthhrvggvthdrtghomhdprhgt
 phhtthhopehjohgrohhtrghvohhrrgesghhmrghilhdrtghomhdprhgtphhtthhopegvlh
 hiiiesghhnuhdrohhrgh
X-ME-Proxy: <xmx:JoYbZ_QUZcJ7BWejopBjrg_5mMAsB-OjYDGqvPyrhz6-41N-1RVuKA>
 <xmx:JoYbZzzoELv8BoaM1nkQIHUSbNvj2F_LGlmq1IhBZEPr2cj87F9ysw>
 <xmx:JoYbZ95lD3cxK3EACTnGLv_369t3wlGrG9NpZYaIqdOjrEmJodd79g>
 <xmx:JoYbZwxlWWbHg41nt4TXUHzm6_ydBIPY0Jtau_QaqDZLoUAuNnwuOg>
 <xmx:J4YbZ1sJ9hqy3pZn4khOPsa_g-DfldKInNL7BXA9upzwzn_vbupyGAg2>
Feedback-ID: i16614472:Fastmail
Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri,
 25 Oct 2024 07:51:01 -0400 (EDT)
From: Pengji Zhang <me@HIDDEN>
To: 65035 <at> debbugs.gnu.org
Subject: Re: bug#65035: 29.1; Port flycheck-emacs-lisp-initialize-packages
 to flymake
In-Reply-To: <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
 <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
Date: Fri, 25 Oct 2024 19:50:48 +0800
Message-ID: <87ed44s8o7.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 65035
Cc: sbaugh@HIDDEN, Eli Zaretskii <eliz@HIDDEN>,
 =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= <joaotavora@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

Jo=C3=A3o T=C3=A1vora <joaotavora@HIDDEN> writes:

> Feel free to use my patch of course.  Stefan noted some time ago
> that -f package-initialize is the wrong flag to ask Emacs -Q to use
> elpa though, so there's something better.

Thanks! I prepared a new patch based on yours.

Regards,
Pengji


--=-=-=
Content-Type: text/x-patch; charset=utf-8
Content-Disposition: inline;
 filename=0001-Add-option-elisp-flymake-byte-compile-activate-packa.patch
Content-Transfer-Encoding: quoted-printable

From be772ff2f3bae82977d6c54fa84960f721ba088e Mon Sep 17 00:00:00 2001
From: Pengji Zhang <me@HIDDEN>
Date: Fri, 25 Oct 2024 19:44:44 +0800
Subject: [PATCH] Add option 'elisp-flymake-byte-compile-activate-packages'
MIME-Version: 1.0
Content-Type: text/plain; charset=3DUTF-8
Content-Transfer-Encoding: 8bit

This option controls whether the Flymake Emacs Lisp
byte-compiler should activate user installed packages before
checking the source buffer.  (Bug#65035)

* lisp/progmodes/elisp-mode.el
(elisp-flymake-byte-compile-user-file-p): New predicate function
to check if a buffer is visiting a user file.
(elisp-flymake-byte-compile-activate-packages): New option.
(elisp-flymake--byte-compile-activate-packages): New variable
for caching.
(elisp-flymake-byte-compile): Use the new option.

* etc/NEWS: Announce the new option.

Co-authored-by: Jo=C3=A3o T=C3=A1vora <joaotavora@HIDDEN>
---
 etc/NEWS                     |  7 ++++++
 lisp/progmodes/elisp-mode.el | 41 ++++++++++++++++++++++++++++++++++++
 2 files changed, 48 insertions(+)

diff --git a/etc/NEWS b/etc/NEWS
index a6c2c895985..090f4293c8e 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -413,6 +413,13 @@ This affects calls to 'warn', 'lwarn', 'display-warnin=
g', and
 In most cases, having it enabled leads to a large amount of false
 positives.
=20
+---
+*** New user option 'elisp-flymake-byte-compile-activate-packages'.
+This option controls whether or not the Flymake byte-compiler backend
+should activate user installed packages before compiling the source
+buffer.  By default, it is set to activate packages when checking user
+configuration files.  Set it to nil to restore the previous behavior.
+
 ** DocView
=20
 ---
diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el
index 2f931daedc7..8a9dce5d3f6 100644
--- a/lisp/progmodes/elisp-mode.el
+++ b/lisp/progmodes/elisp-mode.el
@@ -2190,6 +2190,39 @@ elisp-flymake-byte-compile-load-path
=20
 (defvar bytecomp--inhibit-lexical-cookie-warning)
=20
+(defun elisp-flymake-byte-compile-user-file-p (buffer)
+  "Return non-nil if BUFFER is visiting a user file.
+That means either the file is `user-init-file' or it is in
+`user-emacs-directory'."
+  (when-let* ((file (buffer-local-value 'buffer-file-truename buffer)))
+    (or (and user-emacs-directory
+             (file-in-directory-p file user-emacs-directory))
+        (and user-init-file
+             (string=3D file (abbreviate-file-name
+                            (file-truename user-init-file)))))))
+
+(defcustom elisp-flymake-byte-compile-activate-packages
+  #'elisp-flymake-byte-compile-user-file-p
+  "Whether to activate packages for Flymake elisp byte-compilation.
+If the value is nil, do not activate installed packages.  If the value
+is a function, it is called with one argument, the source buffer to be
+checked, and installed packages are activated if the function returns
+non-nil.  Otherwise, packages are always activated.
+
+Note that for efficiency the return value of the predicate function is
+cached the first time it is called.  Type \\[revert-buffer-quick] to
+invalidate the cached value."
+  :type '(choice
+          (const :tag "Don't activate" nil)
+          (const :tag "Always activate" t)
+          (const :tag "Activate for user files"
+                 elisp-flymake-byte-compile-user-file-p)
+          (function :tag "Predicate function"))
+  :group 'lisp)
+
+(defvar-local elisp-flymake--byte-compile-activate-packages :unset
+  "Cached value for `elisp-flymake-byte-compile-activate-packages'.")
+
 ;;;###autoload
 (defun elisp-flymake-byte-compile (report-fn &rest _args)
   "A Flymake backend for elisp byte compilation.
@@ -2205,6 +2238,12 @@ elisp-flymake-byte-compile
     (save-restriction
       (widen)
       (write-region (point-min) (point-max) temp-file nil 'nomessage))
+    (when (eq elisp-flymake--byte-compile-activate-packages :unset)
+      (setq elisp-flymake--byte-compile-activate-packages
+            (if (functionp elisp-flymake-byte-compile-activate-packages)
+                (funcall elisp-flymake-byte-compile-activate-packages
+                         source-buffer)
+              elisp-flymake-byte-compile-activate-packages)))
     (let* ((output-buffer (generate-new-buffer " *elisp-flymake-byte-compi=
le*"))
            ;; Hack: suppress warning about missing lexical cookie in
            ;; *scratch* buffers.
@@ -2223,6 +2262,8 @@ elisp-flymake-byte-compile
                    ;; "--eval" "(setq load-prefer-newer t)" ; for testing
                    ,@(mapcan (lambda (path) (list "-L" path))
                              elisp-flymake-byte-compile-load-path)
+                   ,@(when elisp-flymake--byte-compile-activate-packages
+                       '("-f" "package-activate-all"))
                    ,@warning-suppression-opt
                    "-f" "elisp-flymake--batch-compile-for-flymake"
                    ,temp-file)
--=20
2.47.0


--=-=-=--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 23 Oct 2024 11:17:11 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 23 07:17:11 2024
Received: from localhost ([127.0.0.1]:58787 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t3ZMV-0006SR-FB
	for submit <at> debbugs.gnu.org; Wed, 23 Oct 2024 07:17:11 -0400
Received: from mail-oi1-f176.google.com ([209.85.167.176]:61560)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <joaotavora@HIDDEN>) id 1t3ZMS-0006S2-NA
 for 65035 <at> debbugs.gnu.org; Wed, 23 Oct 2024 07:17:09 -0400
Received: by mail-oi1-f176.google.com with SMTP id
 5614622812f47-3e60fca5350so1997218b6e.2
 for <65035 <at> debbugs.gnu.org>; Wed, 23 Oct 2024 04:16:39 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1729682134; x=1730286934; darn=debbugs.gnu.org;
 h=content-transfer-encoding:cc:to:subject:message-id:date:from
 :in-reply-to:references:mime-version:from:to:cc:subject:date
 :message-id:reply-to;
 bh=ngRu964OQYtV+ISxvSf/rx2x6e6N0/cruHSGA/C+elk=;
 b=Iv+ACpCFYvBlEibOkxXhcRTIWRIFoC32amiFez4GdjTnKg911rfHNN/hKBDhmehngJ
 TiHBEPmy3WyN1BBp/1L2A9MPRs2ry11zLYlTYhtNS0jNbaVAHoEmM5SQpCvz1PvgEEE3
 oycrCHODCJUA6TpscePkuSWkYI1LGBDe+Gcvud7h0KGh5S9pBEM103gisqfSQOI/WsTy
 yNBittXmbOuou1B4oxZG/AEJYNOChmnHWTjtMpWlpcHMk9uroEqFEoWr1vehB3sTaT82
 nOFFfhOAhp4uh0BE+enmNvfbsyfL6/ETsVIh3IlpnkYs+HwHLsCuqJDvsgf0xk40P+ZY
 nphA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1729682134; x=1730286934;
 h=content-transfer-encoding:cc:to:subject:message-id:date:from
 :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc
 :subject:date:message-id:reply-to;
 bh=ngRu964OQYtV+ISxvSf/rx2x6e6N0/cruHSGA/C+elk=;
 b=ftLDsdAjM/EfqNmjGm4lZuG24kvrFkVlwzmcN3iFSJtO6fi7x1PowA93OJxvudFpIS
 wT1RSrbVI+s7e2t0OkeueR27D6XLT4V9AQHDJWgFoZ/yCe7FQa7GUmkbfDob6Gfrmlmr
 WcLH9ZuxelaRUTXkl3FeDaCmFL1CMeyCfN43vVT9ZV59+1NjsCtlI3Hudf+nu9CiIAOd
 oga522Fn91qu1eWMY0Ml1rAr0qzkEsE8i5PHy7QeP+/I/LxEIe6GwCPQBJCd8eFI7iXS
 qNnTZmtDIzKtixPrh5+fmxQnbPQjMyNLK1YAVlO3bInYN87GjToazTvuxSMkJO+Hp/Hi
 fcXw==
X-Forwarded-Encrypted: i=1;
 AJvYcCVlPwsKK7IIEKs6lZU8vG0wNCqaAniAhcp/UgBOqJSHtV8HdgtPxVdHHIK0RrSNNkGXyLr45w==@debbugs.gnu.org
X-Gm-Message-State: AOJu0Yyzw531A1qEtS1gKmCH0+Fb9XNCHT1/iN+rjQCx3HiGIojxvWd4
 dmwjQVerM7gG5G/0xpYUjsoE8UgZ4y461h/Tf06q2bmU+lOASYWRrc3HW4DhHtnRWlyOcPypiwT
 4HdCXlhyf7C5faXCbn65HZsCU6cU=
X-Google-Smtp-Source: AGHT+IFDVUOCxvJhlPsu2XVKlH87OnzyXHcSMgbKUOcCFTQfnHn3pY+mSWlysgt7osQ41b9RAnGD7lbUdNoO8zFW3oo=
X-Received: by 2002:a05:6808:3c8a:b0:3e6:8ae:7b85 with SMTP id
 5614622812f47-3e6244da033mr2397209b6e.6.1729682133720; Wed, 23 Oct 2024
 04:15:33 -0700 (PDT)
MIME-Version: 1.0
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN> <86o73bds9e.fsf@HIDDEN>
In-Reply-To: <86o73bds9e.fsf@HIDDEN>
From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= <joaotavora@HIDDEN>
Date: Wed, 23 Oct 2024 12:15:22 +0100
Message-ID: <CALDnm52uRy2rDEksyC5Fi7BUBsrbQWetsxy3Ex1AKXL7-XCBOA@HIDDEN>
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
To: Eli Zaretskii <eliz@HIDDEN>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 65035
Cc: sbaugh@HIDDEN, 65035 <at> debbugs.gnu.org, Pengji Zhang <me@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

On Wed, Oct 23, 2024 at 11:33=E2=80=AFAM Eli Zaretskii <eliz@HIDDEN> wrote=
:
>
> > From: Pengji Zhang <me@HIDDEN>
> > Date: Wed, 23 Oct 2024 17:01:23 +0800
> >
> > I am switching to Flymake and I missed this feature as well. I think
> > this bug report is related:
> >
> >     https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D48452
> >
> > In that thread Jo=C3=A3o gave a patch that implements this feature (sor=
t of):
> >
> >     https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D48452#43
> >
> > Although it was not installed.
>
> Adding Spencer, who nowadays maintains Flymake, and Jo=C3=A3o.

Feel free to use my patch of course.  Stefan noted some time ago
that -f package-initialize is the wrong flag to ask Emacs -Q to use
elpa though, so there's something better.

Jo=C3=A3o




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 23 Oct 2024 10:33:40 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 23 06:33:40 2024
Received: from localhost ([127.0.0.1]:58704 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t3YgO-0004Wu-3w
	for submit <at> debbugs.gnu.org; Wed, 23 Oct 2024 06:33:40 -0400
Received: from eggs.gnu.org ([209.51.188.92]:57622)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1t3YgL-0004We-Kk
 for 65035 <at> debbugs.gnu.org; Wed, 23 Oct 2024 06:33:39 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1t3Yfm-0002hI-3d; Wed, 23 Oct 2024 06:33:02 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=G7UjVVt6LZiOVFzA5BqDrg4PeSjQrR5pEfUdZqP6PFo=; b=Sp8K5dXMg+QHRzxL6jTi
 VZBtXdDQ3McVHCwAx3sLWVmvW4uUROJX4GKOYlWxhnHu+lxJg1k5YWhjT+Z5qpKu7UQtCNVa47otK
 0qFm/3hM0G77tL5IajG/R8oxmxS8PSXDCBt7sbcMGsUBsEec3HpsOHC98uo1BrOUmyFjpLsbiGOBs
 nrbO4pHAw5HguhlaAHWS/JsfBnBkA6TIhsRaYhdFBOZj5bBvgHyagx1R9U1c0i4V2Zrix8/gQQZUA
 5nhzmG1EYjzDgoadj+clvVQcjOD+dH5CSFGvSjXjVQUi5BJOpT3xwvPKXU6Urssxp2dq0ZSv6rbr4
 4q/8Xbqtcxhu0A==;
Date: Wed, 23 Oct 2024 13:32:13 +0300
Message-Id: <86o73bds9e.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Pengji Zhang <me@HIDDEN>, sbaugh@HIDDEN
In-Reply-To: <87o73b6vmk.fsf@HIDDEN> (message from Pengji Zhang on Wed,
 23 Oct 2024 17:01:23 +0800)
Subject: Re: bug#65035: 29.1;
 Port flycheck-emacs-lisp-initialize-packages to flymake
References: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
 <87o73b6vmk.fsf@HIDDEN>
MIME-version: 1.0
Content-type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 65035
Cc: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= <joaotavora@HIDDEN>,
 65035 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Pengji Zhang <me@HIDDEN>
> Date: Wed, 23 Oct 2024 17:01:23 +0800
> 
> I am switching to Flymake and I missed this feature as well. I think
> this bug report is related:
> 
>     https://debbugs.gnu.org/cgi/bugreport.cgi?bug=48452
> 
> In that thread João gave a patch that implements this feature (sort of):
> 
>     https://debbugs.gnu.org/cgi/bugreport.cgi?bug=48452#43
> 
> Although it was not installed.

Adding Spencer, who nowadays maintains Flymake, and João.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at 65035 <at> debbugs.gnu.org:


Received: (at 65035) by debbugs.gnu.org; 23 Oct 2024 09:02:13 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Oct 23 05:02:13 2024
Received: from localhost ([127.0.0.1]:58580 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1t3XFt-0000gg-0W
	for submit <at> debbugs.gnu.org; Wed, 23 Oct 2024 05:02:13 -0400
Received: from fhigh-a3-smtp.messagingengine.com ([103.168.172.154]:56739)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <me@HIDDEN>) id 1t3XFq-0000gT-T8
 for 65035 <at> debbugs.gnu.org; Wed, 23 Oct 2024 05:02:12 -0400
Received: from phl-compute-10.internal (phl-compute-10.phl.internal
 [10.202.2.50])
 by mailfhigh.phl.internal (Postfix) with ESMTP id 4729C1140175
 for <65035 <at> debbugs.gnu.org>; Wed, 23 Oct 2024 05:01:36 -0400 (EDT)
Received: from phl-mailfrontend-01 ([10.202.2.162])
 by phl-compute-10.internal (MEProxy); Wed, 23 Oct 2024 05:01:36 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pengjiz.com; h=
 cc:content-transfer-encoding:content-type:content-type:date:date
 :from:from:in-reply-to:message-id:mime-version:reply-to:subject
 :subject:to:to; s=fm1; t=1729674096; x=1729760496; bh=VDGWSMA4mN
 INS+kUP2DmDAyu6VzBFQz1PW0xK4s9Gxs=; b=qXcaiXrQ7xiR7wguPfbRvReDOS
 sv/Yrgo4hUf+fGGzuAHJ2XforodvAxNKSn/APspjxokzt5w2FAsd14bJsMYPoEp9
 nglKJvo/RgMMOntAd5mwcwuk/yW36T/GMGQuuNr1EZch7w9z+6DSAvQLbYAZdUPW
 eEmp0l3c+XCBa9cSy1EdXVlTSoVV1EIUqUpcQE0CdxgYX0I107wij4oqwA6odZ8P
 ruiU3/e8fsAPB8QafVhC9Ea5J2dhoV+tJ1OSFzH19hweHoXeFQuGGb4cfKOU8NgE
 EIbw89j1A0gPR3iOXU9AmwuCsXrdsVczzRmEggygfh9YnqJPV3NLnq116+9g==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=
 messagingengine.com; h=cc:content-transfer-encoding:content-type
 :content-type:date:date:feedback-id:feedback-id:from:from
 :in-reply-to:message-id:mime-version:reply-to:subject:subject:to
 :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=
 fm3; t=1729674096; x=1729760496; bh=VDGWSMA4mNINS+kUP2DmDAyu6VzB
 FQz1PW0xK4s9Gxs=; b=izWgtgaIqSgVZuE3peYKESbBPTJ5Cp6udE/x6i0XcQ9u
 RwEnCZe7D4jzK9Vu4NHcH4I95Ce/Ibc2SyZpiKKCXVYgdbu8itDff9W0Vhfte+Cd
 LN44QXPa1hoSR+xbP1w9Z3G/6MH1LSZZMDIGZCAqAo5ndYChp/HFnG0q/F9UgEpx
 ba6aCpWx3/HtvlNzG5rIwcMqDgMviBMKIWTRzN/Lj5jYpaXsVF1zcXZA9/UBUB+R
 tbRXhnBsWhvUzsZE8Ppxk2LqSpwwhiunih0owG8W9nt0ifFGDXb4f6nnYE3aLm4v
 0vsivl7OBCrwDrj8H900fKNN1MgqEtMi0LxocWNKyA==
X-ME-Sender: <xms:b7sYZ6lDaX76R9a3NwyA3IUluW_VX2KQUQmZIHenmAnotdbE6bM7nw>
 <xme:b7sYZx3BXZsonDj6mwnfPRQILRCNl6Y5g0zCw8AyUnA4e6UCW95QJZiELhNfLdxtb
 LJyMZxD2hdBNU7LAsw>
X-ME-Received: <xmr:b7sYZ4qfh4bmij5JO_EjstFt5s8sWSHskRJL_mYwJiwETZdwTDU9C6MZlq4Hdw>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrvdeijedguddtucetufdoteggodetrfdotf
 fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdggtfgfnhhsuhgsshgtrhhisggvpdfu
 rfetoffkrfgpnffqhgenuceurghilhhouhhtmecufedttdenucenucfjughrpefhvffuff
 fkgggtgfesthhqredttddtjeenucfhrhhomheprfgvnhhgjhhiucgkhhgrnhhguceomhgv
 sehpvghnghhjihiirdgtohhmqeenucggtffrrghtthgvrhhnpeeiffeiffelgfetveegff
 fhleehveejhfettdekgfekvddvieeiveffieeffffgieenucffohhmrghinhepghhnuhdr
 ohhrghenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe
 hmvgesphgvnhhgjhhiiidrtghomhdpnhgspghrtghpthhtohepuddpmhhouggvpehsmhht
 phhouhhtpdhrtghpthhtohepieehtdefheesuggvsggsuhhgshdrghhnuhdrohhrgh
X-ME-Proxy: <xmx:cLsYZ-lVMCUYYxor5t42o--bU4O-gBkKx0lAu7Y8WYVegfSn_0JRiQ>
 <xmx:cLsYZ42u07_z0i1RjfV0ofgEqteKf74IXe6hcmTLyYv-AgHV9QNbqA>
 <xmx:cLsYZ1uc1oybO8Sdy1LGvcg7OsVhSPKfUdbejTB5tq0fwWHuH0faCw>
 <xmx:cLsYZ0XmW0iqj-GKyJKUemgF_swRPwC6r_laoXFpX0MpJ1rWgBZVgg>
 <xmx:cLsYZ1_Vmg2o8_NMy1JEviWAuSgy0bFalS9FfSYODdUuk6h43xnbP9Zq>
Feedback-ID: i16614472:Fastmail
Received: by mail.messagingengine.com (Postfix) with ESMTPA for
 <65035 <at> debbugs.gnu.org>; Wed, 23 Oct 2024 05:01:35 -0400 (EDT)
From: Pengji Zhang <me@HIDDEN>
To: 65035 <at> debbugs.gnu.org
Subject: Re: 29.1; Port flycheck-emacs-lisp-initialize-packages to flymake
Date: Wed, 23 Oct 2024 17:01:23 +0800
Message-ID: <87o73b6vmk.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 65035
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.7 (-)

Hi!

I am switching to Flymake and I missed this feature as well. I think
this bug report is related:

    https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D48452

In that thread Jo=C3=A3o gave a patch that implements this feature (sort of=
):

    https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D48452#43

Although it was not installed.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 3 Aug 2023 10:04:52 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Aug 03 06:04:51 2023
Received: from localhost ([127.0.0.1]:50917 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1qRVCN-00058I-Ki
	for submit <at> debbugs.gnu.org; Thu, 03 Aug 2023 06:04:51 -0400
Received: from lists.gnu.org ([2001:470:142::17]:52298)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <n58r@HIDDEN>) id 1qRVCL-000582-5J
 for submit <at> debbugs.gnu.org; Thu, 03 Aug 2023 06:04:50 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <n58r@HIDDEN>) id 1qRVCD-0005es-Pu
 for bug-gnu-emacs@HIDDEN; Thu, 03 Aug 2023 06:04:42 -0400
Received: from mail-4322.protonmail.ch ([185.70.43.22])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <n58r@HIDDEN>) id 1qRVCB-0000HF-NN
 for bug-gnu-emacs@HIDDEN; Thu, 03 Aug 2023 06:04:41 -0400
Date: Thu, 03 Aug 2023 10:04:24 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pm.me;
 s=protonmail3; t=1691057075; x=1691316275;
 bh=+G97js6K4OYML2rCBSmVUXPlruXFukxarKmSiJkiTBc=;
 h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date:
 Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector;
 b=JBFwnMVjGB2Fa+RxE17w1r++RIzWGflbZvEG4Mz/aS/UcRbxqFbekHEwbtpLR6LPl
 sfVT26zu9yCGhdorE/JoKbVtanempsPg3oXVjM3QeJ6QxZNeSVJrqBH8+x/L66aVXy
 UXvIAoaWuRX4+cmpCRdfKdLpgUnkTKoJyLtIqkqpeMmBm/CXSQN2kT+AhxBgzQhb9u
 Wo9MuIbYAdnXfzMF3KPmjI6HmJEnv+/My0hwOyxeW8HfhtiQa2OJNgCJI01d6Y7v1T
 XofKq38Pnry46F0EaqXOoqVXYXj1I87DKTo+t6ePv3lymYm/gx5L8WM/wKxLUs9r/P
 i7OTAH7o2ltQw==
To: bug-gnu-emacs@HIDDEN
From: Antonio Romano <n58r@HIDDEN>
Subject: 29.1; Port flycheck-emacs-lisp-initialize-packages to flymake
Message-ID: <d773c5bd-0fbf-2fcf-fecc-9b3bfeda51da@HIDDEN>
Feedback-ID: 77338314:user:proton
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass client-ip=185.70.43.22; envelope-from=n58r@HIDDEN;
 helo=mail-4322.protonmail.ch
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001,
 SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 1.0 (+)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.0 (/)



Flycheck includes the "flycheck-emacs-lisp-initialize-packages"
customizable variable, which allows packages to be initialized in the
Emacs subprocess used to lint the elisp file. With this variable, it is
possible for the linter to be aware of autoloads from installed
packages.

I think that having such option on the built-in alternative "flymake"
would be a good quality-of-life addition, as this would make it more
suitable for linting personal configuration and only one M-x away from
any user who would want to try it.

Thanks in advance








Acknowledgement sent to Antonio Romano <n58r@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#65035; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Sun, 12 Jan 2025 05:45:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.