From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#22324: 25.0.50; completion-category-defaults style doesn't override completion-styles (gets prepended instead) Date: Wed, 26 Jan 2022 03:43:17 +0200 Message-ID: References: <868u41rv84.fsf@yandex.ru> <83fuy8p8oq.fsf@gnu.org> <568FA9D0.2040609@yandex.ru> <83egdsp88n.fsf@gnu.org> <568FABFC.3000205@yandex.ru> <87tufr74of.fsf@gnus.org> <87lf0yjwpw.fsf@gnus.org> <87r1aodus0.fsf@gnus.org> <66aa873d-5f5f-9024-efb6-e6110c27ab3a@yandex.ru> <87ilvy4m94.fsf@gnus.org> <87czklnqvs.fsf@gnus.org> <3045ca8b-f5d6-c85e-d170-3fe158fec64e@yandex.ru> <87ilu94gac.fsf@gnus.org> <43725c9f-1f0a-fb43-82a2-3f284791fdf5@yandex.ru> <875yq8ypmi.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38074"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 Cc: 22324@debbugs.gnu.org To: Lars Ingebrigtsen , Daniel Mendler Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jan 26 02:44:17 2022 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 1nCXM8-0009hd-Ok for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 26 Jan 2022 02:44:16 +0100 Original-Received: from localhost ([::1]:51214 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nCXM5-0006Bd-Sd for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 25 Jan 2022 20:44:15 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:52062) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nCXLu-0006B8-P3 for bug-gnu-emacs@gnu.org; Tue, 25 Jan 2022 20:44:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:57679) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nCXLu-000304-8x for bug-gnu-emacs@gnu.org; Tue, 25 Jan 2022 20:44:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nCXLu-0001CT-4n for bug-gnu-emacs@gnu.org; Tue, 25 Jan 2022 20:44:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 26 Jan 2022 01:44:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22324 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 22324-submit@debbugs.gnu.org id=B22324.16431614074560 (code B ref 22324); Wed, 26 Jan 2022 01:44:02 +0000 Original-Received: (at 22324) by debbugs.gnu.org; 26 Jan 2022 01:43:27 +0000 Original-Received: from localhost ([127.0.0.1]:50582 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCXLL-0001BT-Em for submit@debbugs.gnu.org; Tue, 25 Jan 2022 20:43:27 -0500 Original-Received: from mail-wm1-f48.google.com ([209.85.128.48]:44596) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCXLJ-0001BG-Mf for 22324@debbugs.gnu.org; Tue, 25 Jan 2022 20:43:26 -0500 Original-Received: by mail-wm1-f48.google.com with SMTP id l35-20020a05600c1d2300b0034d477271c1so3157324wms.3 for <22324@debbugs.gnu.org>; Tue, 25 Jan 2022 17:43:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=Jy5vFVpBkUluzSInvwpR/zIdGyLJ6XZVtspqbxs+0vU=; b=Nfz41CTE8S++5Zy9paEkVVIxG18Jcb5kOa4N6jsmTigN07vxfdNTp26xed1I88kwCs qFomP8dXIuqFo9ITtmwomOL8Vc7IED613vRPrVIjS3ZXiAPDF9v92vNH/AHg74UNQkLu zj6mm9L+WNfbDJV4gVLaIZLPoFpTaUxTKEZfVOvPDgEnMb6nU1wKgxPPR6Kkm6CoTKGk RGdo+0Y46TrHi2Q+g/a5Oa/kCCoD/hYh9KQNTBdkDH2XCQp0xvZrcc3l6JuXK/7bZjoq 2G4OiFg5NwDN8gT8+TwOGDGObIeZcrVjD+1AVYKMaiJAwhS++ZeHq+r32fiIWszIUmfK HpcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Jy5vFVpBkUluzSInvwpR/zIdGyLJ6XZVtspqbxs+0vU=; b=rthBJqRS9CAl8TLNULO6YRdZVKKHwTLh3C/V39SJdTGQ3YfvQUA6qjnFeE40wEaggF BwlfcovWn6If0jm2+UVNkExytvBn8nQS4OpOGdVQwdduBdda65d5H4oxN1cPwfUzyC/q T8o8hO+ADhzz7o2aah0Zc4tMy0zFh9TA+Mje/q8mt0ZwdyTyVrflFmLmiTwuEXnwWy11 k941vnsOnj/ihVc5OWQlaSF443u1vvbNgvlJmWkINioajzLMXwb0x/7qM6d52x1vzUHg E8lG+ixzH2MKsDwOdNS4x0twOayXFkcsC2ozDPLf4a7Ygy6l/biNHd3hfZl2rXWHN54q +BQA== X-Gm-Message-State: AOAM533l6SumvMdF27ZiGbPg8pkQz8477oeAJ+DW2Yeno4W8EdwoMrg5 6YioQAhiV4KFRwPu2SyN6U98aWutHfQ= X-Google-Smtp-Source: ABdhPJxNZn3xTpTB/+EOJha6DCUKHcYuD8UaGBfsUe+kITYO8Ucgy+1bK5trx8SQf/6F6pk6rBZxrw== X-Received: by 2002:a05:600c:5028:: with SMTP id n40mr5141843wmr.10.1643161399516; Tue, 25 Jan 2022 17:43:19 -0800 (PST) Original-Received: from [10.107.115.144] ([194.36.25.53]) by smtp.googlemail.com with ESMTPSA id z3sm2330560wmp.42.2022.01.25.17.43.18 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 25 Jan 2022 17:43:18 -0800 (PST) In-Reply-To: <875yq8ypmi.fsf@gnus.org> 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:225233 Archived-At: On 25.01.2022 14:19, Lars Ingebrigtsen wrote: > Dmitry Gutov writes: > >> Given that the only times people are likely to notice the distinction >> are some odd edge cases (and the extra lag is not so big or obvious), >> there will be even fewer occasions for people to learn about and >> customize the new var. >> >> Unless we obsolete the previous one, which would be a fair approach, >> if we knew that it actually has a fair amount of users who need to >> migrate. > > Hard to say. Perhaps searching on Github for usages of the variable > might give us a clue? Sure. https://github.com/search?q=%22completion-category-overrides%22&type=code should a grand total of 2,433 matches, but the vast majority of those seem to be users of Orderless who use this scheme: (setq completion-styles '(orderless)) (setq completion-category-defaults nil) (setq completion-category-overrides '((file (styles partial-completion)))) Some add 'basic' before 'partial-completion' for better "Tramp hostname completion". Do these users expect the failover to the orderless style when partial-completion fails to complete? Possible. Orderless is more lax. But also kinda doubtful since partial-completion is fairly powerful by itself, and entering the segments of a file name in a different order is not something does often or intentionally. Apparently this config is recommended in the README of both Corfu and Vertico (https://github.com/minad/vertico#configuration), both projects by Daniel Mendler. I guess we should ask Daniel whether he has been aware of the completion-styles failover mechanic, and what he thinks about it. *** And there are occasionally configs like (setq completion-styles '(partial-completion substring initials basic)) ;; override default completion style of specific modes (setq completion-category-overrides '((file (styles . (flex))) (buffer (styles . (flex))) (project-file (styles . (flex))) (info-menu (styles . (flex))))) where the override is explicitly more powerful, so we know that failover is not desirable, just wasted CPU cycles.