From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eric Ludlam Newsgroups: gmane.emacs.bugs Subject: bug#46841: [PATCH] Make package downloading in inversion.el obsolete Date: Tue, 2 Mar 2021 17:13:09 -0500 Message-ID: <8d4fcdeb-a058-e28f-8ba1-85070179f41e@gmail.com> References: <87pn0j81vv.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36292"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 Cc: "Eric M. Ludlam" , 46841@debbugs.gnu.org To: Stefan Kangas , Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Mar 02 23:14:11 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lHDHO-0009Jz-IU for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 02 Mar 2021 23:14:10 +0100 Original-Received: from localhost ([::1]:38822 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lHDHN-0002Va-J7 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 02 Mar 2021 17:14:09 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37644) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lHDHG-0002VS-Rx for bug-gnu-emacs@gnu.org; Tue, 02 Mar 2021 17:14:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42903) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lHDHG-000381-L7 for bug-gnu-emacs@gnu.org; Tue, 02 Mar 2021 17:14:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lHDHG-0000bd-GH for bug-gnu-emacs@gnu.org; Tue, 02 Mar 2021 17:14:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eric Ludlam Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 02 Mar 2021 22:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46841 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 46841-submit@debbugs.gnu.org id=B46841.16147232052274 (code B ref 46841); Tue, 02 Mar 2021 22:14:02 +0000 Original-Received: (at 46841) by debbugs.gnu.org; 2 Mar 2021 22:13:25 +0000 Original-Received: from localhost ([127.0.0.1]:54449 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lHDGe-0000ab-Na for submit@debbugs.gnu.org; Tue, 02 Mar 2021 17:13:25 -0500 Original-Received: from mail-qk1-f181.google.com ([209.85.222.181]:43727) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lHDGb-0000aK-O0 for 46841@debbugs.gnu.org; Tue, 02 Mar 2021 17:13:23 -0500 Original-Received: by mail-qk1-f181.google.com with SMTP id b130so10414940qkc.10 for <46841@debbugs.gnu.org>; Tue, 02 Mar 2021 14:13:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=zgOwSN3w/BFq/OVW5RmN4VOk84STSLGdzA/as3FyRM8=; b=Wv79e16otOBscHPj653VKVvHq1Q8V69fo8IybnS7p2mbRHwAm5A8AlIoWfrMGpDH6F bJPkCEYtGJ9rclhKIWMSsyLc993lNA7qBIs5Da6vnG1NdzDFIzN86NvAUHUx+AbLFt8p ZbLWgkUS3swFdQ3rZzzBIyWfzOlxGd3YSXDa+ctIsg2f2dFOwESEiD1bxBT2ZKZjzL0a 5JUWsZ7CmhJ0t6RiGjKkX1P7TCJHYmV3cC6EdyfBCjrjaeg237flL1kfP2WzScLxkbjC +aWd90JJqGt1B2re126eYqTNP7+xpktqjHJPBB1/ZmrGKpePVhsWuU2DwHrSDhE5cxS8 G+0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=zgOwSN3w/BFq/OVW5RmN4VOk84STSLGdzA/as3FyRM8=; b=LBJFKxlG4llS0jPeo7chN6IGbBb6+OUZokZXyqdT7GWmaClMUsWQL7bARzxwhTAGwL wjnsyrKru3s07ZRGJWYlPGxKaDXUdOpGpOVV6HRmqGMMSrcgAu6vy9SYGHpKjEkydXZb qZ9c9OpbIiXs2MKjbEj+AszKEEMH8ELSNOir4p94VJWRnmzkneglQEu3tAYxcsRSg6/T eOwdx2/5d3tF1/rBhTMe9dLFHgiD3S1QootwbVcX75VJx6HlXHWhi2JMPJkGFP8xMzWj uaV59NkDko5eEz/DM0UBEZHvbF6Aslihw4Cc57O/1a9HSdZoPn9oncmjcSbist/Q0i1B F44Q== X-Gm-Message-State: AOAM531VX866CopIn/xe0SMCpmnqAZj5gGaGrNEK/EyI/wr3/BDuHJpe sK/LLuJsQOemW2p1S3TejOk= X-Google-Smtp-Source: ABdhPJxHxZoVWE3U0uQHmdM9uvTQHwuFU/Sexo4zlqtxt8FoyBuojxsRHodKfl0mJ6VkDv10Vu5AkQ== X-Received: by 2002:a37:9c4d:: with SMTP id f74mr4436981qke.202.1614723195940; Tue, 02 Mar 2021 14:13:15 -0800 (PST) Original-Received: from ?IPv6:2601:184:80:3a60:79dd:a2b0:7e67:baec? ([2601:184:80:3a60:79dd:a2b0:7e67:baec]) by smtp.googlemail.com with ESMTPSA id z2sm14717323qkg.22.2021.03.02.14.13.15 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 02 Mar 2021 14:13:15 -0800 (PST) In-Reply-To: Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:201244 Archived-At: Thanks for checking in about inversion.el. I used to have a lot of issues with different versions of things when CEDET was separate from Emacs and new versions of CEDET could overlay on top of an Emacs with an earlier version of CEDET included.  Inversion was a way of getting things tied together, and upgrading save files to new versions, and things like that. None of those old issues exist anymore since external CEDET is too hard to merge back into Emacs and I now post patches direct to Emacs instead, so it makes sense to clean this up. Thanks Eric On 3/1/21 11:08 AM, Stefan Kangas wrote: > (Copying in Eric Ludlam in case he has something to add.) > > Lars Ingebrigtsen writes: > >> Stefan Kangas writes: >> >>> There is some code to download packages in cedet/inversion.el which >>> seems completely redundant now that we have package.el. I suggest >>> marking that part as obsolete, see the attached patch. >>> >>> To be honest, I don't exactly see that there is any need for >>> inversion.el since the problem it tries to solve is already solved by >>> package.el. Perhaps we should just move the entire library to >>> obsolete/. >> Utility functions like `inversion-package-version' are used in the rest >> of CEDET, though? (I just did a quick grep, but didn't actually read >> the call sites.) > Yes. I took a closer look. The uses all seem to be of dubious value > these days, and could probably themselves be obsoleted or changed to not > need inversion. Here is what I could find: > > ./lisp/cedet/cedet.el106: (filever (car (inversion-find-version sym))) > > The function `cedet-version' produces a screen like this: > > CEDET Version: 2.0 > Requested File Loaded > Package Version Version Version > ---------------------------------------------------------- > cedet: 2.0 ok ok > eieio: 1.4 ok ok > semantic: 2.2 ok Not Loaded > srecode: 1.2 ok Not Loaded > ede: 1.2 2.0 Not Loaded > > > C-h f cedet-version RET > for details on output format. > > But all these packages are distributed with Emacs itself. > > ./lisp/cedet/semantic/ede-grammar.el165: (list "eieio" "semantic" > "inversion" "ede"))) > ./lisp/cedet/semantic/ede-grammar.el168: ;; Inversion for versioning system. > > Add inversion to loadpath in Makefiles produced by EDE, for some reason. > If inversion is obsolete, that would not be useful. > > ./lisp/cedet/semantic/db-file.el176: (if (not (inversion-test > 'semanticdb-file fv)) > ./lisp/cedet/semantic/db-file.el177: (when (inversion-test > 'semantic-tag tv) > ./lisp/cedet/cedet-cscope.el156: (if (inversion-check-version rev nil > cedet-cscope-min-version) > ./lisp/cedet/cedet-idutils.el185: (if (inversion-check-version rev nil > cedet-idutils-min-version) > ./lisp/cedet/cedet-global.el160: (if (inversion-check-version rev nil > cedet-global-min-version) > > Several similar functions that just check for the installed version, > which is either the one distributed with Emacs or the latest released > version. The latter would normally be the one you automatically > installed with package.el. > > So it's all just about making sure the correct version of a package is > installed. AFAICT, that is fully obsoleted by `package-install'. > > ./lisp/cedet/ede/make.el76: (setq ans (not (inversion-check-version > rev nil ede-make-min-version)))) > > This parses the make version and ensures its recent enough. Perhaps > useful, but could likely be replaced by the built-in `version<' or > somesuch. > > ./lisp/cedet/semantic.el61: (inversion-test 'semantic > > Here we have a function `semantic-require-version' that allows callers > to check if this is a recent enough version of Semantic. > > They should instead be checking for the major version of Emacs, or if > Semantic is installed from the external CEDET repository deal with it > themselves, or if Semantic is turned into a core package and installed > that way they should just make sure their dependencies are correct. > > Am I missing something here? Eric? > >> But, yes, the download bits don't seem very useful. > Thanks.