From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id ELRaNtTaxGWG8QAAqHPOHw:P1 (envelope-from ) for ; Thu, 08 Feb 2024 14:44:53 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id ELRaNtTaxGWG8QAAqHPOHw (envelope-from ) for ; Thu, 08 Feb 2024 14:44:53 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1707399892; a=rsa-sha256; cv=none; b=NoGG9lm7Lo03XyVMv6ynMkN2cbG9EgkTQkKLU9Tk9jiSaYI9Ilz0M16txP7i73FMMAhq+h OlUcaoqg5Blsuvii+sN+eHJpR7FUrXhdJF1IdGiBUttJB0kI86ZBRTfnEW9E092ZnKr9wf bjBqCqVPSD1ynR8sjKQXTFP0Auu+S/aLxYZDoJHM4SSmB62g5pmObAztRRMP/hECsvvhJF pz0wUoPbow5YYuInq02Tteuvsa/rqzEJ9fHQRbH+lVkbzXUKHqvUvfx3WgnLF3w06phn06 neg76SqcUytR/WvGRlBUDx74HXumtxvjVUNjbDgxuy7gcWVS8XwjhwUnY89ohA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1707399892; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=4TZAZgLQ544GH1M5t3txZCyD1LOOwFOa3yDxIjnnmM4=; b=cg+yplwpCWJ2pIhxVyedG6JCmvx1gLwBak8AdV3b7QQAXCFTV1Q2A9Fyme4MkjqX0+vXIP Nb/8IRUZBTZ0UEyYP7yUSAwChTkJqD24g8sMlXLXh3dsXF4l/9SdruUAOZyUS+/atcdvX7 ICR8RQBep3M/j8kgiyoWH0m0H2r2PiMtSr8O56SC+evo/5J4Ruxtn5l/AauFCPWHb2/Rbb l+CXehCD65/f9RgO1xEICx0m90ukMJbolcckIHeXi8j3Yhxd7E/Nus2y3yCgxzwu3hBYrx M1s1F52jFJkGjNMfLAlA2LRuvd0bypcHoTotnzDpliv/SMcP2dFMywya2OOhEA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 3A07B6A5F8 for ; Thu, 8 Feb 2024 14:44:52 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rY4hG-0005E0-Jt; Thu, 08 Feb 2024 08:44:10 -0500 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 ) id 1rXvaw-00063U-4x for emacs-orgmode@gnu.org; Wed, 07 Feb 2024 23:01:03 -0500 Received: from mail115-24.sinamail.sina.com.cn ([218.30.115.24]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXvat-0004mK-MS for emacs-orgmode@gnu.org; Wed, 07 Feb 2024 23:01:01 -0500 X-SMAIL-HELO: PWRD-20230207OU Received: from unknown (HELO PWRD-20230207OU)([111.207.225.84]) by sina.com (10.75.12.45) with ESMTP id 65C4507B0000420A; Thu, 8 Feb 2024 11:54:42 +0800 (CST) X-Sender: drcxd@sina.com X-Auth-ID: drcxd@sina.com X-SMAIL-MID: 80705631457637 X-SMAIL-UIID: A3433102FB6E4FE9B60BB38710000587-20240208-115442-1 From: Chang Xiaoduan To: emacs-orgmode@gnu.org Subject: [BUG] org-num-skip-unnumbered is not respected if a org-mode file enables org-num-mode on startup [9.6.18 ( @ /home/drcxd/.emacs.d/elpa/org-9.6.18/)] Date: Thu, 08 Feb 2024 11:54:39 +0800 Message-ID: <87jznf7gqo.fsf@PWRD-20230207OU.> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=218.30.115.24; envelope-from=drcxd@sina.com; helo=mail115-24.sinamail.sina.com.cn X-Spam_score_int: -5 X-Spam_score: -0.6 X-Spam_bar: / X-Spam_report: (-0.6 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FROM=0.001, HK_RANDOM_ENVFROM=0.999, HK_RANDOM_FROM=0.999, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Thu, 08 Feb 2024 08:44:05 -0500 X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx10.migadu.com X-Spam-Score: -6.77 X-Migadu-Queue-Id: 3A07B6A5F8 X-Migadu-Spam-Score: -6.77 X-TUID: n12NLs8iHHhD Remember to cover the basics, that is, what you expected to happen and what in fact did happen. You don't know how to make a good report? See https://orgmode.org/manual/Feedback.html#Feedback Your bug report will be posted to the Org mailing list. ------------------------------------------------------------------------ Hello, I have been experimenting with org-num-mode recently. I find that if an org-mode file enables org-num-mode on startup by adding: ```emacs-lisp #+STARTUP: num ``` and if there is a file local prop line: ```emacs-lisp # -*- org-num-skip-unnumbered: t; -*- ``` then org-num-mode does not respect the file local variable, i.e., some headings with the `UNNUMBERED` property set to `t` still get their numbering. This also happens for `org-num-max-level` if it is set on the file local prop line. If I toggle org-num-mode after visiting the file, then org-num-mode respect those file local variables. What's more, I have tried to remove the `STARTUP` keyword, so I can enable org-num-mode after visiting the file. However, without enabling org-num-mode on visiting the file, Emacs reports those file local variables as unsafe, though their values are safe, according to the documentation. I guess it is determined as unsafe because org-num-mode is not loaded. This can be reproduced by launching Emacs using `emacs -Q` and visiting the following org-mode file: ``` # -*- org-num-skip-unnumbered: t; -*- #+STARTUP: num * Unnumbered Heading :PROPERTIES: :UNNUMBERED: t :END: * Numbered Heading ``` I expect that if I enable org-num-mode using the `STARTUP` keyword, it will respect file local properties specified on the file local prop line. Alternatively, Emacs should not report those file local variables as unsafe if the org-num-mode is not enabled on startup. Thank you Xiaoduan Emacs : GNU Emacs 29.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.16.0) of 2023-08-30, modified by Debian Package: Org mode version 9.6.18 ( @ /home/drcxd/.emacs.d/elpa/org-9.6.18/)