From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id sDmEHj33c2HvUwAAgWs5BA (envelope-from ) for ; Sat, 23 Oct 2021 13:51:25 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id UPYXGj33c2GDeAAAbx9fmQ (envelope-from ) for ; Sat, 23 Oct 2021 11:51:25 +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 E217B12EA5 for ; Sat, 23 Oct 2021 13:51:24 +0200 (CEST) Received: from localhost ([::1]:46270 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1meFYZ-0004Ai-U3 for larch@yhetil.org; Sat, 23 Oct 2021 07:51:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46774) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1meFXb-0004Aa-1Q for emacs-orgmode@gnu.org; Sat, 23 Oct 2021 07:50:23 -0400 Received: from mail-pg1-x532.google.com ([2607:f8b0:4864:20::532]:44686) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1meFXZ-0004li-2i for emacs-orgmode@gnu.org; Sat, 23 Oct 2021 07:50:22 -0400 Received: by mail-pg1-x532.google.com with SMTP id c4so5845139pgv.11 for ; Sat, 23 Oct 2021 04:50:20 -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=Ko3t77rch19BzaCQscV+VPruvwUVj41cO+9iOytg4i0=; b=K62kUs42Pll4X1CzypiDoHoMbdJPMFdT+UiHH6J4rHNxeKekHlzjTFcx2TJBqbhyQo x7LaTtuBOmylYCQ6o8iKZs3CNTLO2apMzdw75mKgwopuPZ5SQ64QNSkUY8JYmCkn3AIl DeXvO5O0YbZO+jV2kLk5jahy2Nv7F8BiqbaE3nFdAg4cnWV+BRM+RAvzIlXw+96ymfPj YbmnocdxWBhS1yeVHrafnCd0Iok5uJZ6ZJ9n2Ukf3ctKSW8w+E0a90ItY3fziI3X3hto X8oxk0mcxJiaY1PTNwx16U4XZKTFE3SxR1PZYJu5VHtBbPMoD7W0i/zJ5q01R9P8joob piVg== 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=Ko3t77rch19BzaCQscV+VPruvwUVj41cO+9iOytg4i0=; b=rYM+Ok4ZjX7pAK1V+RAniuO3Gpcpsh6Sgj59/b9fcK6vSnwBk+kD8EqyEwZkhUIeAU QgZFD9d4OKJYvIJk0Mtgs8nWBlj8nw6vs4eL8t1zGVAXTG1X8nIIZ+nSy7SJHKt90MBF FAcVoeN3C69nuNVBxtdrhf37Oobpht46MzbuVDlEZiqzEQlBJkv5J3mYIlaCjoUUExGr YdSRctTEOX+htnZqr5fRkPHxX15wKC30O3aLSW0RPMSyfQDxDCvZD7CIViR+Gzn9oqo1 ZvpR2gAU2G+68INoIjhEW/Ymn6S+xxtJ7YMQlUoETVTrvOkexEEhdpP89ttZW3U1x5pK JLzw== X-Gm-Message-State: AOAM530HrdE6g85mnlrsJ99tnEU0N5W24QStjz56gvgTCEKTAuChCp/Y InSCmC6RnLNsKsS2jrpsPC3fmwAIYQk= X-Google-Smtp-Source: ABdhPJzIHmQCiPWl7aNIcAR/B0NnOe5I+Gts+ujQyvozPWUq5rm5Kpe3dOl6QkoPS1xy71T/gH2mXg== X-Received: by 2002:a63:8f4c:: with SMTP id r12mr4244763pgn.0.1634989819436; Sat, 23 Oct 2021 04:50:19 -0700 (PDT) Received: from blind-drunk.fritz.box (124-171-51-79.dyn.iinet.net.au. [124.171.51.79]) by smtp.gmail.com with ESMTPSA id d2sm14117066pfj.42.2021.10.23.04.50.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 23 Oct 2021 04:50:19 -0700 (PDT) References: <733d6598-0efd-519d-ba13-08d127256b87@gmail.com> <3dd9032d-c18e-47ec-a26d-a3c2f1e3cbf7@gmail.com> <1366768.1634984772@apollo2.minshall.org> User-agent: mu4e 1.6.7; emacs 27.2 From: Tim Cross To: Greg Minshall Subject: Re: Fwd: errors when using org-agenda Date: Sat, 23 Oct 2021 22:34:02 +1100 In-reply-to: <1366768.1634984772@apollo2.minshall.org> Message-ID: MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::532; envelope-from=theophilusx@gmail.com; helo=mail-pg1-x532.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: 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=1634989885; 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=Ko3t77rch19BzaCQscV+VPruvwUVj41cO+9iOytg4i0=; b=IHuG77p/ObfTiC7kZ6cE7v2G1iRjuLDAagodqmr5ZjuRTe3B0voKhtFFgKRb7V8ZCEhpaM zNptA1VPo9AXw26qiIiPQhBW43PL4GV4Bm9XZb6VnBL4IpYz8Qj/MpoYjTgLd0RtIZRkUo 5sp2+AFrcVoJLDs37CAaWoZMF44RoMWa/+u0wEIC1VSKnrG7QgfItB5rhIF830b+pQQwCx zNmcXUxYqJBnNpfvBRcpKaSIg32tByDwsKV4njbJeAxbNR0i6SmkehhbRlYqDfo8fuX1Nw ORjcwHDrwaFucG6cGDbN+XNCRlm6lNDA5VlE0QlplxVdzHks3GUxsMOfNtUYKw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1634989885; a=rsa-sha256; cv=none; b=JMkup077r6xFMRGVzlTxCXNANp90qb4ELvAmAVfshIhkqqDc/REHhkpXcTiqyhGrHa9R1Z FB3MpOdMNfrJRMac7YiGzWgNuLya9z9unYEEFpECTWJH/J0WsHDoUG+j5RhZACIiYXMJG2 KotVC/9um0uOeS95vLA2T0Zr9YoqlfhtVeC7GPHLTY5zM+/9kR/TfPvaeYqquuE0edBdrT 2cLwz0GgTZDISXv37mw6bFN+8cyLW1lpfEraZvLeN1pAJ6DGEZNlVMMLr/LH79tQ8Bn5tp 4KoWL+3uuNOsaxh3NejUSPWqlEYgIjsthdOB9XDJ4mFz+i8vEk0dOa14F4DP8g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=K62kUs42; 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: -2.53 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=K62kUs42; 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: E217B12EA5 X-Spam-Score: -2.53 X-Migadu-Scanner: scn1.migadu.com X-TUID: F68iRKBbcKr3 Greg Minshall writes: > Tim, et al., > >> These types of errors are frequently caused by a 'mixed' installation >> of org versions. This will happen if you upgrade org when org is >> already loaded in the instance of emacs used to perform the upgrade. > > a question: is there any way that we can, as org starts up, detect > either the actuality, or possibility, of a mixed installation? > maybe something like > ---- > (assert (eq 1 > (length > (seq-filter > (lambda (d) (file-exists-p (concat d "/" "org.el"))) > load-path)))) > ---- > or some such? (well, maybe fail in a more user-friendly way... :) > I'm not sure auto detecting is possible. It isn't so much about what files exist, but what functions are already defined and/or what libraries are already loaded when the upgrade process tries to compile the new version. The 'mixed' refers to the resulting *.elc files, which havbe been compiled with definitions from two different org versions. With package.el for example, once the upgrade has been completed, the old ELPA version doesn't exist anymore, so it isn't as simple as just checking for multiple references to org source files in the load path and at different locations. 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. It could be possible to add something to the package installer, but that would mean doing something with all the package installers e.g. package.el, straight.el, etc. Some distributions, like spacemacs, manage this by separating marking of packages to be upgraded and doing the upgrade into separate sessions. You check for updates, write the list of packages to be updated, move the existing packages to a recovery area and then you have to restart Emacs. On restart, the list of packages to be upgraded (it is really an install because the previous versions have been moved out into a separate 'recovery' area) and if org is in the list, move it to the front of the list so that it is installed before any other packages (to protect against other packages loading org as part of their installation). All this means, with spacemacs, you can be pretty confident an upgrade will work without the mixed install issue. Even better, if the upgraded package has problems and you want to downgrade back to the previous version, that is supported as well. The bad aspect of spacemacs is that after you have used it for a while, your pretty much ruined when it comes to running vanilla Emacs. You get very use to the VI style modal editing and find it hard to use emacs without evil mode installed.