From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 4LtJJN0GdWEgTwEAgWs5BA (envelope-from ) for ; Sun, 24 Oct 2021 09:10:21 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id GI/jH90GdWFMSQAAB5/wlQ (envelope-from ) for ; Sun, 24 Oct 2021 07:10:21 +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 1BBA723FBB for ; Sun, 24 Oct 2021 09:10:21 +0200 (CEST) Received: from localhost ([::1]:59328 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1meXe7-0000EI-01 for larch@yhetil.org; Sun, 24 Oct 2021 03:10:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59728) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1meXdF-0000DV-Fm for emacs-orgmode@gnu.org; Sun, 24 Oct 2021 03:09:25 -0400 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]:36741) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1meXdE-0001cp-1h for emacs-orgmode@gnu.org; Sun, 24 Oct 2021 03:09:25 -0400 Received: by mail-pf1-x42b.google.com with SMTP id m26so7659278pff.3 for ; Sun, 24 Oct 2021 00:09:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=references:user-agent:from:to:cc:subject:date:in-reply-to :message-id:mime-version; bh=NjzWb1LpqjCK7qGKCwnQwUK8amAZRYIrZhSj7gevIBM=; b=nL+5k7IZJFBRp6JbN8EV7Bin7umUP1xsrwDEXtJZvu68ajjwU+6l5tbv0IyRps3yQj o3HD7NqRBBUEG1q4+RInNrhhmOehkVLGzRR7YpSJZQgJxsVrxa3As4Q+ghhQ7ONTzCf2 djTDQvvLMyylQTxpVrH6tc9fcWnGP2kr+E7PvIdClXg61Njh58qoVBQG/yTpVvBpbWPH ne4VTp9Z5OmLNAExmPKybFHKZFYKQk8KgmMtGZBMKBdtin0DKV75hwk8Qe8oVLwzhlXp 1kkvBnSxb50X8FW4lcuCUwIyjhvDZ8rF2rWMcyblNkTgfdd7zvnWfZOzgVWAEj2w1FIC P8lA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:references:user-agent:from:to:cc:subject:date :in-reply-to:message-id:mime-version; bh=NjzWb1LpqjCK7qGKCwnQwUK8amAZRYIrZhSj7gevIBM=; b=xXqraXqJ+GsN9YEqmspQ/RlSGxLssBCluhLx06MOcbfRxZmduX4QabRdDISCxgHdA3 xRHIIKsd5EQk2v+4Kjn6pxYyx6P5SVEZb92JoAQbgPaiR1aNvOCbuKVPhJDcXgm1B8oA fXC/SUpmQtYkkzKyDykDV2+T6KIACdtQ2rlZNMd2g/M/8aP9vdxEIZMhh4WuHrjUypDE S3CpCqvanXt2wavK98mV7g1w3lCrRxgZi0lyCDL/OTGWwhHGqab8u65D9rhS8ICW/Auk 1ezx2OQWIHF/iO+SdsSG7j0UOmMyq5LMmAScI9oe85i20NzSXl/c5jDOZl8zmMzcCrob F9+Q== X-Gm-Message-State: AOAM530Hl3EOUPqupbU42h4X64JnAnfhkrq4DO3ECgFnfVUN6nhNleeH LuoB2Hy+ymega6REqd+kNWv8CiXUFm8= X-Google-Smtp-Source: ABdhPJxocEs8dSzW3F8D49J53pUNbD8NMAE68pEk/0AIu42pD7YRXSkwimKCYHAFVL7TlgIylwBX3w== X-Received: by 2002:a05:6a00:181c:b0:44c:bf17:e8ad with SMTP id y28-20020a056a00181c00b0044cbf17e8admr10263677pfa.67.1635059362381; Sun, 24 Oct 2021 00:09:22 -0700 (PDT) Received: from blind-drunk.fritz.box (124-171-49-168.dyn.iinet.net.au. [124.171.49.168]) by smtp.gmail.com with ESMTPSA id h12sm6161425pfv.117.2021.10.24.00.09.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 24 Oct 2021 00:09:21 -0700 (PDT) References: <733d6598-0efd-519d-ba13-08d127256b87@gmail.com> <3dd9032d-c18e-47ec-a26d-a3c2f1e3cbf7@gmail.com> <1366768.1634984772@apollo2.minshall.org> <87lf2jdn00.fsf@localhost> User-agent: mu4e 1.6.7; emacs 27.2 From: Tim Cross To: Ihor Radchenko Subject: Re: [PATCH] Re: Fwd: errors when using org-agenda Date: Sun, 24 Oct 2021 17:59:42 +1100 In-reply-to: <87lf2jdn00.fsf@localhost> Message-ID: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::42b; envelope-from=theophilusx@gmail.com; helo=mail-pf1-x42b.google.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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: Greg Minshall , emacs-orgmode@gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1635059421; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=NjzWb1LpqjCK7qGKCwnQwUK8amAZRYIrZhSj7gevIBM=; b=V9D+T22QkUX0HlDpKx4YRYTa+KPoFRHJgt0arCY6wvkNiLigIG6zx0dziBXteVMXMEz/GA gQ69oB0FwljMTh6KtQJ2TRCuNNvE6dzECvARzKfQlwAXKVTgheLIM5AtUSfi461J/ZswIT L1KXGdLfE85lB0qo4187aIb+aWCokkx1aPEhj23zU43YNvcYDeynQ53Jzm7e17QAiI3HIs TNVVRyXpM2S2Ejq+LkbVJ0nzDAd2MnSQmxzndA6WCDToWrNpWVsfiJErCM9TyqkRCxR4Em hc6brQmexS0lvg/rwdpuve3JAXzJ+lqH5hKdR1Ngf1g3POTu3o/5EsqvLQU4Qg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1635059421; a=rsa-sha256; cv=none; b=kzB9p++38SQjHTaH5VyyaGi7+iVmIZJgMBXo3hR3MqkbOkie5ZOvdkOjAUCIdszZEikSz2 qDEz7I+9VzrOmv8KUqO6V1Pi7x2lMtVQHL4kqJuZtwqa1GbO2XpAR+zD1NRvo6YyMc9p+4 WEZhp9yCxabnNiv7Xx0DmS7P3tEzznvtQvpu4TIrZUvikhFzbtGMspBSbF6/RNGvGW/FWB JNdUbQnOIPewwxzjyuAcEql/v+/jmIuDUSd5QOTPRCHdZyX6l1W3A6xj/nbLBoS1Pe0jca HFbVKr0H+eA0MSdg8m+eguRYqP4ipsAqZz012pgeJdx6xE3kSktv/i0X8B0czA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=nL+5k7IZ; dmarc=pass (policy=none) header.from=gmail.com; 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-Migadu-Spam-Score: -3.12 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=nL+5k7IZ; dmarc=pass (policy=none) header.from=gmail.com; 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-Migadu-Queue-Id: 1BBA723FBB X-Spam-Score: -3.12 X-Migadu-Scanner: scn0.migadu.com X-TUID: ksm+5N2MAtwV Ihor Radchenko writes: > Tim Cross writes: > >> What would really be needed is some way to check when org is going to be >> compiled that no existing org functionality is loaded. Doubt this can be >> easily done within org itself because of a chicken and egg problem - you >> would have to load org to run the code to check if org is loaded. > > I attached a tentative patch checking if org is loaded. It is not > ideal, but it can capture some scenarios. > > The patch will not work if older org.el is loaded before newer version > of Org. Though we may put extra checks in other lisp files. > > WDYT? > > This is along the lines of what I was thinking. Of course, the big limitation is requirement org.el is not loaded. I would imagine it is rare for org to be loaded and org.el not to be? However, I think this sort of approach i.e. warning if there is an attempt to upgrade org when org is already loaded, is the way to go. Achieving this in a clean and reliable manner is the challenge. False positives are an issue as that would likely prevent legitimate upgrades.