From unknown Wed Jun 18 23:13:13 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#55245 <55245@debbugs.gnu.org> To: bug#55245 <55245@debbugs.gnu.org> Subject: Status: 28.1; project--read-project-buffer predicate fails with wrong-type-argument listp Reply-To: bug#55245 <55245@debbugs.gnu.org> Date: Thu, 19 Jun 2025 06:13:13 +0000 retitle 55245 28.1; project--read-project-buffer predicate fails with wrong= -type-argument listp reassign 55245 emacs submitter 55245 Reindert-Jan Ekker severity 55245 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Tue May 03 11:08:44 2022 Received: (at submit) by debbugs.gnu.org; 3 May 2022 15:08:44 +0000 Received: from localhost ([127.0.0.1]:40678 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nlu8p-00074l-8s for submit@debbugs.gnu.org; Tue, 03 May 2022 11:08:44 -0400 Received: from lists.gnu.org ([209.51.188.17]:35122) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nlrIh-00062N-KD for submit@debbugs.gnu.org; Tue, 03 May 2022 08:06:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43354) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nlrIh-0002p8-CL for bug-gnu-emacs@gnu.org; Tue, 03 May 2022 08:06:43 -0400 Received: from outbound1.mail.transip.nl ([2a01:7c8:7c8::72]:36630) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nlrId-0006LL-4z for bug-gnu-emacs@gnu.org; Tue, 03 May 2022 08:06:42 -0400 Received: from submission9.mail.transip.nl (unknown [10.103.8.160]) by outbound1.mail.transip.nl (Postfix) with ESMTP id 4KszG063DYzRjMG for ; Tue, 3 May 2022 14:06:32 +0200 (CEST) Received: from www.codesensei.nl (unknown [IPv6:2a01:7c8:bb02:73:5054:ff:fe0b:4b1]) by submission9.mail.transip.nl (Postfix) with ESMTPSA id 4KszFz4mtmz1y56 for ; Tue, 3 May 2022 14:06:31 +0200 (CEST) Received: from dhcp-077-248-199-195.chello.nl ([77.248.199.195] helo=CodeSensei-MacBook-Air.local) by www.codesensei.nl with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nlrOy-0007R0-Th for bug-gnu-emacs@gnu.org; Tue, 03 May 2022 14:13:12 +0200 User-agent: mu4e 1.6.10; emacs 28.1 From: Reindert-Jan Ekker To: bug-gnu-emacs@gnu.org Subject: 28.1; project--read-project-buffer predicate fails with wrong-type-argument listp Date: Tue, 03 May 2022 14:01:05 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain X-Scanned-By: ClueGetter at submission9.mail.transip.nl DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; s=transip-a; d=codesensei.nl; t=1651579591; h=from:subject:to:date: mime-version:content-type; bh=YTTPHsI8FQAkcTIeOlMEP54rEUMujRjcsAaIG50OLXA=; b=ME50SRC5yOugAUQ3DqvjIGZWgLrsSh/kAr4VZwFkNFUz+yYpdeHanR5XswnGa9Z7bhttkR N85rgH2dfJLQgIglRMAniNuHDTims+fV4yKH6feKliU8Uj7wgJ/4E+dKBDRz7GTUNKXqf0 W6VH+PI4/cXws1WyM4RJuvbbAvNjA+/XPB41vmOPhwbOqxAMl2Cb04aPi6B1u4e/NqCmEG IfEehnLr2fU/zsfpr08nBQHXANZe9f9XoWreH89Br0i0ggylZeeanp4LD87p6r6/yHrrz8 vTOznPpgr+11qlBg/dI1X95iOjKpW94pEFX5k5ASoHMyN1T3xX2bABQbyfKavA== X-Report-Abuse-To: abuse@transip.nl Received-SPF: pass client-ip=2a01:7c8:7c8::72; envelope-from=info@codesensei.nl; helo=outbound1.mail.transip.nl X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Tue, 03 May 2022 11:08:42 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) I encountered this bug because I use helm. After the following: (require 'helm) (require 'helm-config) (helm-mode 1) the command project-switch-to-buffer always fails with "wrong type argument listp". I posted this as a helm issue at first and got the following answer (quoting from https://github.com/emacs-helm/helm/issues/2506): The bug is not helm related, it is a bug in project--read-project-buffer (and possibly other functions which use the same predicate?), where its predicate expect a cons cell like (bufname . buf_object) and when the first call of the predicate used to determine default for read-buffer returns a buffer-name, this one is called next by the predicate function of read-buffer (which use the same predicate) with a buffer-name as argument instead of a cons cell hence the error "wrong type argument listp". Here a possible (quick) fix (not fully safe as it should check if buffer is a string or a buffer or nil): (defun project--read-project-buffer () (let* ((pr (project-current t)) (current-buffer (current-buffer)) (other-buffer (other-buffer current-buffer)) (other-name (buffer-name other-buffer)) (buffers (project-buffers pr)) (predicate (lambda (buffer) ;; BUFFER is an entry (BUF-NAME . BUF-OBJ) of Vbuffer_alist. (if (consp buffer) (memq (cdr buffer) buffers) (memq (get-buffer buffer) buffers))))) (read-buffer "Switch to buffer: " (when (funcall predicate (cons other-name other-buffer)) other-name) nil predicate))) In GNU Emacs 28.1 (build 2, aarch64-apple-darwin20.6.0, NS appkit-2022.60 Version 11.5.2 (Build 20G95)) of 2022-05-01 built on CodeSensei-MacBook-Air.local Windowing system distributor 'Apple', version 10.3.2022 System Description: macOS 11.5.2 Configured using: 'configure --disable-dependency-tracking --disable-silent-rules --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp --infodir=/opt/homebrew/Cellar/emacs-plus@28/28.1/share/info/emacs --prefix=/opt/homebrew/Cellar/emacs-plus@28/28.1 --with-xml2 --with-gnutls --with-native-compilation --without-dbus --without-imagemagick --with-modules --with-rsvg --with-ns --disable-ns-self-contained 'CFLAGS=-I/opt/homebrew/opt/gcc/include -I/opt/homebrew/opt/libgccjit/include -I/opt/homebrew/opt/gmp/include -I/opt/homebrew/opt/jpeg/include' 'LDFLAGS=-L/opt/homebrew/lib/gcc/11 -I/opt/homebrew/opt/gcc/include -I/opt/homebrew/opt/libgccjit/include -I/opt/homebrew/opt/gmp/include -I/opt/homebrew/opt/jpeg/include'' Configured features: ACL GIF GLIB GMP GNUTLS JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP NOTIFY KQUEUE NS PDUMPER PNG RSVG THREADS TIFF TOOLKIT_SCROLL_BARS XIM ZLIB Important settings: value of $LC_ALL: en_US.UTF-8 value of $LC_CTYPE: UTF-8 value of $LANG: en_US.UTF-8 locale-coding-system: utf-8-unix Major mode: elisp Minor modes in effect: edebug-mode: t helm-mode: t helm-minibuffer-history-mode: t helm--remap-mouse-mode: t async-bytecomp-package-mode: t rainbow-delimiters-mode: t which-key-mode: t super-save-mode: t recentf-mode: t savehist-mode: t save-place-mode: t global-diff-hl-mode: t diff-hl-mode: t global-anzu-mode: t anzu-mode: t volatile-highlights-mode: t windmove-mode: t global-flycheck-mode: t flycheck-mode: t global-company-mode: t company-mode: t global-hl-line-mode: t show-smartparens-global-mode: t show-smartparens-mode: t smartparens-strict-mode: t smartparens-mode: t global-undo-tree-mode: t undo-tree-mode: t override-global-mode: t magit-wip-initial-backup-mode: t magit-wip-before-change-mode: t magit-wip-after-apply-mode: t magit-wip-after-save-mode: t magit-wip-mode: t global-git-commit-mode: t magit-auto-revert-mode: t global-auto-revert-mode: t shell-dirtrack-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t buffer-read-only: t size-indication-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Load-path shadows: ~/.emacs.d/rje/custom hides /opt/homebrew/Cellar/emacs-plus@28/28.1/share/emacs/28.1/lisp/custom /Users/reindert/.emacs.d/elpa/transient-20220425.1314/transient hides /opt/homebrew/Cellar/emacs-plus@28/28.1/share/emacs/28.1/lisp/transient Features: (shadow pulse bug-reference helm-config helm-projectile vc-mtn vc-hg vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs cl-print debug ace-window avy goto-addr view emacsbug eieio-opt speedbar ezimage dframe shortdoc help-fns radix-tree tabify man helm-command helm-elisp helm-eval edebug backtrace helm-mode helm-misc gnutls epa-file network-stream nsm mailalias sort gnus-cite mail-extr qp vc-git winner tramp-archive tramp-gvfs helm-x-files helm-for-files helm-bookmark helm-adaptive helm-info bookmark pp helm-external helm-net helm-files image-dired helm-tags helm-locate helm-buffers helm-occur helm-grep helm-regexp helm-utils helm-help helm-types helm helm-core async-bytecomp helm-global-bindings helm-easymenu helm-source helm-multi-match helm-lib async rainbow-delimiters course course-ui course-server course-publish course-backend course-topic-link course-meta course-log course-projects course-deps publish-course yasnippet projectile lisp-mnt grep compile ibuf-ext ibuffer ibuffer-loaddefs ox-reveal ox-odt rng-loc rng-uri rng-parse rng-match rng-dt rng-util rng-pttrn nxml-parse nxml-ns nxml-enc xmltok nxml-util ox-latex ox-icalendar ox-html table ox-ascii ox-publish ox htmlize exec-path-from-shell midnight which-key flyspell ispell sane-term dired-x rje-savefiles super-save recentf tree-widget savehist saveplace rje-looks dimmer face-remap color diff-hl log-view vc-dir ewoc vc vc-dispatcher anzu volatile-highlights whitespace diminish rje-move move-text windmove rje-keys rje-windows rje-programming flycheck hl-todo rje-company company-oddmuse company-keywords company-etags etags fileloop xref project company-gtags company-dabbrev-code company-dabbrev company-files company-clang company-capf company-cmake company-semantic company-template company-bbdb company pcase rje-pass password-store auth-source-pass rje-agenda org-agenda rje-theme org-element avl-tree generator ol-w3m org-inlinetask ol-info ol-eww eww xdg url-queue mm-url ol-doi org-link-doi ol-docview org-ctags org-crypt deeper-blue-theme rje-mail org-mu4e mu4e mu4e-org mu4e-main mu4e-view mu4e-view-gnus gnus-art mm-uu mml2015 mm-view mml-smime smime dig gnus-sum gnus-group gnus-undo gnus-start gnus-dbus dbus gnus-cloud nnimap nnmail mail-source utf7 netrc nnoo gnus-spec gnus-int gnus-range gnus-win gnus nnheader wid-edit mu4e-view-common mu4e-headers mu4e-compose mu4e-context mu4e-draft mu4e-actions ido rfc2368 smtpmail sendmail mu4e-mark mu4e-proc mu4e-utils doc-view jka-compr image-mode exif mu4e-lists mu4e-message shr kinsoku svg xml dom flow-fill hl-line mu4e-vars mu4e-meta f s rje-edit zop-to-char sudo-edit smartparens-config smartparens-org smartparens-text smartparens-python smartparens thingatpt browse-kill-ring undo-tree queue rje-org org-tempo tempo org-id org-refile org org-macro org-footnote org-pcomplete org-list org-faces org-entities noutline outline org-version ob-emacs-lisp ob-plantuml ob-ditaa ob-python python tramp-sh tramp tramp-loaddefs trampver tramp-integration files-x tramp-compat parse-time ls-lisp ob-shell ob ob-tangle org-src ob-ref ob-lob ob-table ob-exp ob-comint ob-core ob-eval org-table oc-basic bibtex iso8601 ol org-keys oc org-compat advice org-macs org-loaddefs find-func cal-menu calendar cal-loaddefs use-package use-package-ensure use-package-delight use-package-diminish use-package-bind-key bind-key use-package-core rje-packages epl finder-inf magit-wip magit-log which-func imenu magit-diff smerge-mode diff diff-mode git-commit log-edit easy-mmode message rmc puny dired dired-loaddefs rfc822 mml mml-sec epa derived epg rfc6068 epg-config gnus-util rmail rmail-loaddefs text-property-search time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr mailabbrev mail-utils gmm-utils mailheader pcvs-util add-log magit-core magit-autorevert autorevert filenotify magit-margin magit-transient magit-process with-editor shell pcomplete comint ring server ansi-color magit-mode transient comp comp-cstr warnings cl-extra edmacro kmacro help-mode magit-git magit-base magit-section format-spec crm dash compat-27 compat-26 compat delsel cus-load rx info package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs password-cache json subr-x map url-vars seq byte-opt gv bytecomp byte-compile cconv cl-loaddefs cl-lib iso-transl tooltip eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/ns-win ns-win ucs-normalize mule-util term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote threads kqueue cocoa ns lcms2 multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 1061008 99689) (symbols 48 62100 17) (strings 32 253698 9988) (string-bytes 1 8470187) (vectors 16 110269) (vector-slots 8 2374615 163638) (floats 8 672 364) (intervals 56 36959 1700) (buffers 992 47)) -- Reindert-Jan Ekker Code Sensei From debbugs-submit-bounces@debbugs.gnu.org Wed May 04 06:45:13 2022 Received: (at 55245-done) by debbugs.gnu.org; 4 May 2022 10:45:13 +0000 Received: from localhost ([127.0.0.1]:41899 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nmCVN-0005V3-EQ for submit@debbugs.gnu.org; Wed, 04 May 2022 06:45:13 -0400 Received: from mail-wm1-f45.google.com ([209.85.128.45]:39577) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nmCVL-0005Ul-6h for 55245-done@debbugs.gnu.org; Wed, 04 May 2022 06:45:12 -0400 Received: by mail-wm1-f45.google.com with SMTP id ay11-20020a05600c1e0b00b0038eb92fa965so2951792wmb.4 for <55245-done@debbugs.gnu.org>; Wed, 04 May 2022 03:45:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=em4/E5sX7Q5Q+0XCf0tJx+WG1OlbC10+73axO2kQL0M=; b=qwfJ2LYsfeHvJ5eOa+hGHdMymoZuS4vLWkkEfQxhwY+Mi8A1wFbD0RM7ruCYdIW4tj xvk2sv6VpCjjlwf3/n4++UNvPsFBBSGLMFQlvBpwkhGpVnd87y7cOpfIc7n28Qd1a3Q+ 5TZHlzLzOXhGO/ykSVG1xbLHF1LmVbtUUYmwDJTWg8YTZuLhM/LVDdIWVZt7T+kEhbpO eFmBm60UGEkCsoOJwjgsWW6WHFXMLnGDD2R9DCrcHhOjp5oxRltuaa7i5duVJHK7kI+G HdXNsF2idgDHSZlbjw1OssQr1YCm9bQdwzZ/Gl6W1Xg0K/Ap0t6VLUZc+WnnpoKAPTRs WKNw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:message-id:date:mime-version:user-agent :subject:content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=em4/E5sX7Q5Q+0XCf0tJx+WG1OlbC10+73axO2kQL0M=; b=Drq8eF5PRbA1xtCpTcenv3I1M4OzsjTTGg3Vb2EoxQeTm1HRiBJ+QcCOAjYja6X5H0 vjNItBzOdA420QRnoez9KdafrjG5SsQxIS29ojxjPjOu+L+qiLq+ini6zdq6dIKbEJcN nzFAIgAAn5J6l49QvmlpeUF+Z1cb+S3ADyF5acea3OkaaIcACDkz40dwU5xjm32/cr81 QXnxhx4nw6Z2vnBUgTkpU0zZsBWALhDGtQZ5wPhakQAj8qh6O2IXa3TUmo7IcUQ6nmcB vBTmPd6lCAf1NvlZQpNK08SbsvnFaM9IyPmxwuirSdQSlHJDtjlSjkx2HHxXOOnc7m6M 286Q== X-Gm-Message-State: AOAM533OuP+UU0BNgSDehqAe7/OwLYm7lUjDr7QgqrF239u+jdkauzlz hMUR9jEdETxhY+slELKdwdI= X-Google-Smtp-Source: ABdhPJznJHsDeOXU+oocaXQFvf5tfKyE1WmlEy5OBq/S91Jl6ZZO0sW6g1KuY8Gw1+HFCXdPF+0MyA== X-Received: by 2002:a05:600c:3c99:b0:392:b49c:7b79 with SMTP id bg25-20020a05600c3c9900b00392b49c7b79mr7082149wmb.199.1651661105042; Wed, 04 May 2022 03:45:05 -0700 (PDT) Received: from [192.168.0.6] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id h25-20020a7bc939000000b003942a244ee8sm3639864wml.45.2022.05.04.03.45.04 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 04 May 2022 03:45:04 -0700 (PDT) Message-ID: <2e7f1b91-c133-0d3b-e2cf-713b5fac2898@yandex.ru> Date: Wed, 4 May 2022 13:45:02 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: bug#55245: 28.1; project--read-project-buffer predicate fails with wrong-type-argument listp Content-Language: en-US To: Reindert-Jan Ekker , 55245-done@debbugs.gnu.org References: From: Dmitry Gutov In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 55245-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.5 (/) On 03.05.2022 15:01, Reindert-Jan Ekker wrote: > > I encountered this bug because I use helm. After the following: > > (require 'helm) > (require 'helm-config) > (helm-mode 1) > > the command project-switch-to-buffer always fails with "wrong type > argument listp". I posted this as a helm issue at first and got the > following answer (quoting from > https://github.com/emacs-helm/helm/issues/2506): > > The bug is not helm related, it is a bug in project--read-project-buffer > (and possibly other functions which use the same predicate?), where its > predicate expect a cons cell like (bufname . buf_object) and when the > first call of the predicate used to determine default for read-buffer > returns a buffer-name, this one is called next by the predicate function > of read-buffer (which use the same predicate) with a buffer-name as > argument instead of a cons cell hence the error "wrong type argument > listp". Here a possible (quick) fix (not fully safe as it should check > if buffer is a string or a buffer or nil): Thanks for the report. Looks like we got it fixed in Helm. From unknown Wed Jun 18 23:13:13 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 01 Jun 2022 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator