From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id MCJFHYBXUV/LZAAA0tVLHw (envelope-from ) for ; Thu, 03 Sep 2020 20:52:16 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id KBUTGYBXUV92RgAAbx9fmQ (envelope-from ) for ; Thu, 03 Sep 2020 20:52:16 +0000 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 25AEC94036A for ; Thu, 3 Sep 2020 20:52:14 +0000 (UTC) Received: from localhost ([::1]:36238 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kDwDM-0007rv-Jp for larch@yhetil.org; Thu, 03 Sep 2020 16:52:12 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54038) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kDwCv-0007rn-CX for emacs-orgmode@gnu.org; Thu, 03 Sep 2020 16:51:45 -0400 Received: from mx0b-00395d01.pphosted.com ([148.163.137.170]:9742) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kDwCs-00062L-39 for emacs-orgmode@gnu.org; Thu, 03 Sep 2020 16:51:45 -0400 Received: from pps.filterd (m0173176.ppops.net [127.0.0.1]) by mx0b-00395d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 083KnJ0K007926; Thu, 3 Sep 2020 13:51:39 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ucsd.edu; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-id : content-transfer-encoding : mime-version; s=campus; bh=NaHcvbU20QDdGNCbXqmBviWzNW1O1QAJ/nZ07M8jKlA=; b=yYA35uDfoS740j1KIq0uIj6gNsUJBEFNpqwQDn+tzMp4ejXRUTrdovrIiOR9z3mOy30L NWA8CmE7M3Ix2hSmq8ToWxqcCSeZ9IXkaau1bv8HyUNlfvfd9QzkijvbLYT829yskprp hvRHI3k5b4iz9Se+NCB+p69+gvo7YHS0IymldMwyX4xyNxdC+OrWt0qKnGeQHj/jPzyW 2i2xrPicW7ioWfX0m/gIjqv2JPN11wucTJrF91u3OAQ87urKG5Jp6VHMYqgsag49/cPR M0+SHDyJ0i0DIZV9PAzlZdVf5mJE8lw80yT08VpF/OJCGj+jY3pe2KhxgoPRDjN8qGrJ lw== Received: from secdlpezp04.ucsd.edu ([40.112.251.180]) by mx0b-00395d01.pphosted.com with ESMTP id 337k0mh9xh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 03 Sep 2020 13:51:39 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CWK/jRh4ijWYZo8lOnjrX5Jfuw81hz0iZA7ItAMT/h/T7TQq7UqpvAI7NACNmPIkIJf4Y816KrCbf9fP6XUwaYrkvwsiMKgQoxv+NaApm2SurFnCxridoL3raso4CmRDbFyNNuF3Ti+MNDrXmqrJ0tCpwLOrpP2gKvC+OK+rwg1/7S+W/okde0zEcr9FixByhiUz/vz4zXeu4NgX7QAmKsYD9CbznzbT6u+9v6L726aIFGOFOqQX6WPOS/hEM2LEGZBPvGDPhjNUXPLa7CUNY7kOJXGBBZJrWM5sa/YSO2zQPzGYV/8veAfbOze4KpFSLlfCdWn0DNsZE9VzdVWv7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NaHcvbU20QDdGNCbXqmBviWzNW1O1QAJ/nZ07M8jKlA=; b=LuW49n5JUlHhlqB985D2c/+SMbLuV+njaDUmGTORdpBqKz9TXwxz20TKmnEBPqa3GI7OJCiVfmEJkxnkWw7ip56ZkcKTzLNXx+fUdEFbOzuEjLkAqN6w1GtO2XdNnqC11UwPEifEMY4AoCBltgh2hfwVGPZvOT60lzRsz+fs2EFMXgrMUhlDGdOAK5dCRsr+Ro1o5oBX/Ru67gAW3phkk5ycYr7AB09e6sBJ1SgB8o3DP5RijZ9z99gqiVo30RZgOgen3pWOsY/6TXQuGLEMgmoLZbBm9I5oxHg8QQS8D6Ln+twjM+wNN0F9wMBLxLYyuBLlYnD52CVFo1p2VeajfA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=health.ucsd.edu; dmarc=pass action=none header.from=health.ucsd.edu; dkim=pass header.d=health.ucsd.edu; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ucsdhs.onmicrosoft.com; s=selector2-ucsdhs-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NaHcvbU20QDdGNCbXqmBviWzNW1O1QAJ/nZ07M8jKlA=; b=LZL86O+AiG9E9l6r42E2O8GD8VrapKIDe9V7NK95zmtnNH9H/ysl76Sdy6cJdzdRWqw9ONC5fvpBWTjsyIpq9Z0dia0U+R8hyP0GCBJoWW8s5Sg4rOwib6/6Ujqb0yh9A6aaf1DRMl0tOeGAXOmfj2JJyB1xVChfB9zQ+A7zvF0= To: Enze Chi Subject: Re: Bug: Source blocks before first ":tangle yes" are not tangled to file [9.4 (nil @ /Users/ezchi/.emacs.d/.local/straight/build/org-mode/)] Thread-Topic: Bug: Source blocks before first ":tangle yes" are not tangled to file [9.4 (nil @ /Users/ezchi/.emacs.d/.local/straight/build/org-mode/)] Thread-Index: AQHWghUpKC01MORp6U6EG/tw8tHRZalXXjaAgAAFpYA= Date: Thu, 3 Sep 2020 20:51:37 +0000 Message-ID: <2BF03DFE-2EE5-42DC-B36D-AC746B5669AA@health.ucsd.edu> References: <72B34378-D53B-4A76-95D1-B6903EE38C26@health.ucsd.edu> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [2600:1702:1021:b0:846f:7027:d140:148d] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 36e82ba0-bc01-47f0-4dfc-08d8504b2679 x-ms-traffictypediagnostic: BY5PR19MB3746: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:3383; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: YmD7hLJtJzjiJUvgCwLTiX++5fjC59wC50nts+imFuJk2lnfys8RVvo2aVdl3VdYQrsjxUzUSDpZ4xIEucPeOD1DDpMVtry8EjsG7y5Za2UunAzvvshxHLG0zV62Gred5xCuBiYlVp2CFOrGxoC/2XspY2I8hHUaRY92SDgbuPsCnw7XlaGMZMzMPat+QQ/yff3GdrBZymIgRZ9cAzKKnJQIfieJwKDDTMVoImqr3v0yJnHxXwXVb3evknHpvsYrmjQ5i3svcfsQsKHUkuDXoXNhWXD7OyJlyuajvUhG9yGjn/dVHMfb3SfePzOBmxEKG4NVDb/LHLQBhDQ3zDED4csp3J6hI+86uSo9aBaEMoSStiAtL3O9gwxw/Wcy3J4kwXvsXCngbjLaFCSHBg3sTQ== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BYAPR19MB2888.namprd19.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(396003)(136003)(376002)(346002)(366004)(39860400002)(6916009)(316002)(786003)(66946007)(71200400001)(8676002)(478600001)(186003)(8936002)(53546011)(2616005)(6506007)(64756008)(5660300002)(86362001)(66556008)(76116006)(2906002)(66446008)(66476007)(6486002)(33656002)(83380400001)(6512007)(966005)(75432002)(4326008); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: kXwLOjQQHRutaewXWw6/3YGC9J0/cATlBhbMXgqxNgQJony521UEfxEh+VhUcER8ZFeeJH3vMBG25GtG/S8beCpppH3/dXgFQDDnKMCzsXKLLhU8KChhpVXRSMuDy7QNUlRHHQy0/umvjXMthOasvNfobphrmtM3D++gy1vvHQFrm+ww9JlAUylNxp5Z+7P5Wgp+QaJhamCg+YqRXwsN95teC9ODa1PKoa33GUogRf062/2P95pgTJP86Apf2PsTx9LtTZ15mb1P2kqbYtJ4is7wnKQQDq8GJ4KsvwdVy/m+YDbVmsj46DFer6FSruURfpFai5vVOS1Sz94GAc2HWJzgUsGLKd02U20x4XPgyc/py4R8B9w6cLg8Lro4jFqWuCjZWWis3IS5Zs6d7vrfiScEhhet4o+yiUaxg246ZuHAsTuG5yxewv8oOWGgcfk1QBD1WFP21W9OVZe5VGz35vV1YrXhSP6Sl4XE8W1BJVEPy+mTA7xYTX2AKM3aOWtkhFyN5kdnU0N235UJHhK3ZTYExbqwLZ8gZAEARGFRGuoPWArBfDS3nNFkabn50pXL6ap1k2pUcsz3TC9+MRQUwL+hJ9rjvWXliqplepmLTlquoUjideHTex+9TsWGNOVrB0gPNqmtqUYCDh74L9nu+ZoF7M0hXV9Hcp7KA/bQVUpqZ562DzWbfWul99KlMc1RxR8SBOciubsUhIDqRyEEdg== x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-ID: Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: health.ucsd.edu X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BYAPR19MB2888.namprd19.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 36e82ba0-bc01-47f0-4dfc-08d8504b2679 X-MS-Exchange-CrossTenant-originalarrivaltime: 03 Sep 2020 20:51:37.0448 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: e470d736-e7f7-41a8-8eab-dad544b2b579 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Mb/U0ntBIAbXNnt2dDRNS75E7vmECaWQOXORNJBfJW1MIv70ujsDrx1KlPCISj+01wnJnikEx4ewhtQ0vnlAuA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR19MB3746 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.235, 18.0.687 definitions=2020-09-03_14:2020-09-03, 2020-09-03 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 adultscore=0 impostorscore=0 mlxlogscore=996 spamscore=0 phishscore=0 malwarescore=0 priorityscore=1501 lowpriorityscore=0 clxscore=1015 suspectscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2009030185 Received-SPF: pass client-ip=148.163.137.170; envelope-from=ccberry@health.ucsd.edu; helo=mx0b-00395d01.pphosted.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/03 16:51:39 X-ACL-Warn: Detected OS = Linux 3.1-3.10 X-Spam_score_int: -26 X-Spam_score: -2.7 X-Spam_bar: -- X-Spam_report: (-2.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "emacs-orgmode@gnu.org" Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" Reply-to: "Berry, Charles" From: "Berry, Charles" via "General discussions about Org-mode." X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=ucsd.edu header.s=campus header.b=yYA35uDf; dkim=fail (rsa verify failed) header.d=ucsdhs.onmicrosoft.com header.s=selector2-ucsdhs-onmicrosoft-com header.b=LZL86O+A; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: 1.99 X-TUID: Zd7zy/GzvwlI I get one file, "foo.el", with both src blocks. Chuck > On Sep 3, 2020, at 1:31 PM, Enze Chi wrote: >=20 > Hi Charles: >=20 > Thanks for the clear explanation. Add default ":tangle yes" does what I e= xpected.=20 >=20 > But when I try to tangle it to a file like this (with default ":tangle no= "): > (org-babel-tangle nil "foo.el") >=20 > I end up get 2 files: > foo.el: > (setq foo "hello") >=20 > test_tangle.el: > (setq bar "world") >=20 > Should I expect only: > foo.el: > (setq bar "world") >=20 >=20 >=20 > On Fri, Sep 4, 2020 at 3:10 AM Berry, Charles w= rote: > Not a bug. See inline. >=20 > > On Sep 3, 2020, at 12:37 AM, Enze Chi wrote: > >=20 > >=20 > > 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? Se= e > >=20 > > https://orgmode.org/manual/Feedback.html#Feedback > >=20 > > Your bug report will be posted to the Org mailing list. > > -----------------------------------------------------------------------= - > >=20 > > I have a org file like this (test_tangle.org): > >=20 > > #+begin_src emacs-lisp > > (setq foo "hello") ; > > #+end_src > >=20 >=20 > There was no :tangle header arg specified for this block. Hence it is nev= er tangled. I believe this is well documented in the manual. >=20 > Running `org-babel-view-src-block-info' (C-c C-v C-i) with point in the s= rc block will confirm this this by listing the header args including `:tang= le no' >=20 > If you want all src blocks to be tangled, you should study >=20 > (info "(org) Using Header Arguments") >=20 > to set a system-wide or buffer wide default. >=20 > HTH, >=20 > Chuck >=20 >=20 > > #+begin_src emacs-lisp :tangle yes > > (setq bar "world")=20 > > #+end_src > >=20 > >=20 > > After I run "(org-babel-tangle nil nil)" > >=20 > > I expect both of them are tangled to "test_tangle.el": > >=20 > > (setq foo "hello") > > (setq bar "world") > >=20 > >=20 > > But I only got: > >=20 > > (setq bar "world") > >=20 > >=20 > >=20 > > Emacs : GNU Emacs 27.1.50 (build 1, x86_64-apple-darwin19.6.0, NS appk= it-1894.60 Version 10.15.6 (Build 19G73)) > > of 2020-08-14 > > Package: Org mode version 9.4 (nil @ /Users/ezchi/.emacs.d/.local/strai= ght/build/org-mode/) > >=20 > > current state: > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > (setq > > org-src-mode-hook '(org-src-babel-configure-edit-buffer > > org-src-mode-configure-edit-buffer) > > org-link-shell-confirm-function 'yes-or-no-p > > org-metadown-hook '(org-babel-pop-to-session-maybe) > > org-clock-out-hook '(org-clock-remove-empty-clock-drawer) > > org-mode-hook '(#[0 "\300\301\302\303\304$\207" > > [add-hook change-major-mode-hook org-show-all append local] > > 5] > > #[0 "\300\301\302\303\304$\207" > > [add-hook change-major-mode-hook org-babel-show-result-all > > append local] > > 5] > > org-babel-result-hide-spec org-babel-hide-all-hashes) > > org-archive-hook '(org-attach-archive-delete-maybe) > > org-confirm-elisp-link-function 'yes-or-no-p > > org-agenda-before-write-hook '(org-agenda-add-entry-text) > > org-metaup-hook '(org-babel-load-in-session-maybe) > > org-bibtex-headline-format-function #[257 "\300\236A\207" [:title] 3 "= \n\n(fn ENTRY)"] > > org-babel-pre-tangle-hook '(save-buffer) > > org-tab-first-hook '(org-babel-hide-result-toggle-maybe > > org-babel-header-arg-expand) > > org-agenda-loop-over-headlines-in-active-region nil > > org-occur-hook '(org-first-headline-recenter) > > org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawe= rs > > org-cycle-show-empty-lines > > org-optimize-window-after-visibility-change) > > org-speed-command-hook '(org-speed-command-activate > > org-babel-speed-command-activate) > > org-export-before-parsing-hook '(org-attach-expand-links) > > org-confirm-shell-link-function 'yes-or-no-p > > org-link-parameters '(("attachment" :follow org-attach-follow :complet= e > > org-attach-complete-link) > > ("id" :follow org-id-open) > > ("eww" :follow org-eww-open :store org-eww-store-link) > > ("rmail" :follow org-rmail-open :store > > org-rmail-store-link) > > ("mhe" :follow org-mhe-open :store org-mhe-store-link) > > ("irc" :follow org-irc-visit :store org-irc-store-link > > :export org-irc-export) > > ("info" :follow org-info-open :export org-info-export > > :store org-info-store-link) > > ("gnus" :follow org-gnus-open :store > > org-gnus-store-link) > > ("docview" :follow org-docview-open :export > > org-docview-export :store org-docview-store-link) > > ("bibtex" :follow org-bibtex-open :store > > org-bibtex-store-link) > > ("bbdb" :follow org-bbdb-open :export org-bbdb-export > > :complete org-bbdb-complete-link :store > > org-bbdb-store-link) > > ("w3m" :store org-w3m-store-link) ("file+sys") > > ("file+emacs") ("shell" :follow org-link--open-shell) > > ("news" :follow > > #[514 "\301\300\302Q\"\207" > > ["news" browse-url ":"] 6 "\n\n(fn URL ARG)"] > > ) > > ("mailto" :follow > > #[514 "\301\300\302Q\"\207" > > ["mailto" browse-url ":"] 6 "\n\n(fn URL ARG)"] > > ) > > ("https" :follow > > #[514 "\301\300\302Q\"\207" > > ["https" browse-url ":"] 6 "\n\n(fn URL ARG)"] > > ) > > ("http" :follow > > #[514 "\301\300\302Q\"\207" > > ["http" browse-url ":"] 6 "\n\n(fn URL ARG)"] > > ) > > ("ftp" :follow > > #[514 "\301\300\302Q\"\207" ["ftp" browse-url ":"] > > 6 "\n\n(fn URL ARG)"] > > ) > > ("help" :follow org-link--open-help) > > ("file" :complete org-link-complete-file) > > ("elisp" :follow org-link--open-elisp) > > ("doi" :follow org-link--open-doi)) > > org-link-elisp-confirm-function 'yes-or-no-p > > ) > >=20 >=20 >=20