Subject: bug#71538: closed (Re: bug#71538: 29.3; project-find-file stopped working for files in git submodules)

From: [email-masked] (GNU bug Tracking System)
Date: Sat, 01 Mar 2025 02:05:03 +0000

Your bug report

#71538: 29.3; project-find-file stopped working for files in git submodules

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
71538: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=71538
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#71538: 29.3; project-find-file stopped working for files in git submodules
From: Stefan Kangas <[email-masked]>
To: Pär Bohrarper <[email-masked]>
Cc: Dmitry Gutov <[email-masked]>, [email-masked]
Date: Fri, 28 Feb 2025 18:04:09 -0800
List-Id: <debbugs-submit.debbugs.gnu.org>

Pär Bohrarper <[email-masked]> writes:

> It works great in 0.11.1! Thanks for getting it fixed so quick.
>
> On Fri, Jun 14, 2024 at 5:34 PM Dmitry Gutov <[email-masked]> wrote:
>
>  On 14/06/2024 11:01, Pär Bohrarper wrote:
>  > I'm getting project.el via ELPA.
>
>  Very good. I've bumped the version, the update should get deployed
>  within the next 24 hours, please check it out.

This was fixed.  I'm therefore closing this bug report.

Subject: 29.3; project-find-file stopped working for files in git submodules
From: Pär Bohrarper <[email-masked]>
To: [email-masked]
Date: Thu, 13 Jun 2024 16:55:01 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

Since
https://github.com/emacs-mirror/emacs/commit/370b216f08699bdd85b910868642df441c06306c
project-find-file will produce a list where files located in a git
submodule is listed relative to the submodule instead of relative to the
project root. The problem happens when recursing into submodules if
project--vc-merge-submodules-p is true. I managed to fix it locally by
concating the module name to the file in the recursive call:

    (let ((sub-files-maybe-relative
   (project--vc-list-files
    (concat default-directory module)
    backend
    extra-ignores)))
      (if project-files-relative-names
  ;; If project--vc-list-files returns relative names, then concat the
submodule name
  (mapcar (lambda (file) (concat (file-name-as-directory module) file))
sub-files-maybe-relative)
                         sub-files-maybe-relative))

I don't know if this is the correct approach though.

In GNU Emacs 29.3 (build 1, aarch64-apple-darwin23.5.0, NS
 appkit-2487.60 Version 14.5 (Build 23F79)) of 2024-06-12 built on
 WRY7PK7266
Windowing system distributor 'Apple', version 10.3.2487
System Description:  macOS 14.5

Configured using:
 'configure --disable-dependency-tracking --disable-silent-rules
 --enable-locallisppath=/opt/homebrew/share/emacs/site-lisp
 --infodir=/opt/homebrew/Cellar/emacs-plus@29/29.3/share/info/emacs
 --prefix=/opt/homebrew/Cellar/emacs-plus@29/29.3 --with-xml2
 --with-gnutls --without-compress-install --without-dbus
 --without-imagemagick --with-modules --with-rsvg --with-ns
 --disable-ns-self-contained 'CFLAGS=-Os -w -pipe
 -mmacosx-version-min=14
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk
 -DFD_SETSIZE=10000 -DDARWIN_UNLIMITED_SELECT'
 'CPPFLAGS=-I/opt/homebrew/opt/icu4c/include
 -I/opt/homebrew/opt/sqlite/include -I/opt/homebrew/opt/readline/include
 -isystem/opt/homebrew/include -F/opt/homebrew/Frameworks
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk'
 'LDFLAGS=-L/opt/homebrew/opt/icu4c/lib -L/opt/homebrew/opt/sqlite/lib
 -L/opt/homebrew/opt/readline/lib -L/opt/homebrew/lib
 -F/opt/homebrew/Frameworks -Wl,-headerpad_max_install_names
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk''

Configured features:
ACL GIF GLIB GMP GNUTLS JPEG JSON LCMS2 LIBXML2 MODULES NOTIFY KQUEUE NS
PDUMPER PNG RSVG SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER
WEBP XIM ZLIB

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: ELisp/l

Minor modes in effect:
  tree-sitter-hl-mode: t
  global-tree-sitter-mode: t
  tree-sitter-mode: t
  marginalia-mode: t
  savehist-mode: t
  vertico-mode: t
  corfu-popupinfo-mode: t
  global-corfu-mode: t
  corfu-mode: t
  which-key-mode: t
  rainbow-delimiters-mode: t
  global-whitespace-mode: t
  doom-modeline-mode: t
  server-mode: t
  windmove-mode: t
  recentf-mode: t
  override-global-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
/Users/bohrarper/.emacs.d/elpa/cmake-mode-20240412.1329/cmake-mode hides
/opt/homebrew/share/emacs/site-lisp/cmake/cmake-mode
/Users/bohrarper/.emacs.d/elpa/protobuf-mode-20240222.1652/protobuf-mode
hides /opt/homebrew/share/emacs/site-lisp/protobuf/protobuf-mode
/Users/bohrarper/.emacs.d/elpa/transient-20240609.2020/transient hides
/opt/homebrew/Cellar/emacs-plus@29/29.3/share/emacs/29.3/lisp/transient
/Users/bohrarper/.emacs.d/elpa/jsonrpc-1.0.25/jsonrpc hides
/opt/homebrew/Cellar/emacs-plus@29/29.3/share/emacs/29.3/lisp/jsonrpc
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-jump
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-jump
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-diminish
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-diminish
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-delight
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-delight
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-lint
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-lint
/Users/bohrarper/.emacs.d/elpa/bind-key-20230203.2004/bind-key hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/bind-key
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-core
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-core
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-ensure
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-ensure
/Users/bohrarper/.emacs.d/elpa/use-package-20230426.2324/use-package-bind-key
hides /opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/use-package/use-package-bind-key
/Users/bohrarper/.emacs.d/elpa/flymake-1.3.7/flymake hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/progmodes/flymake
/Users/bohrarper/.emacs.d/elpa/xref-1.7.0/xref hides
/opt/homebrew/Cellar/emacs-plus@29/29.3/share/emacs/29.3/lisp/progmodes/xref
/Users/bohrarper/.emacs.d/elpa/project-0.11.0/project hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/progmodes/project
/Users/bohrarper/.emacs.d/elpa/eglot-1.17/eglot hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/progmodes/eglot
/Users/bohrarper/.emacs.d/elpa/eldoc-1.15.0/eldoc hides
/opt/homebrew/Cellar/emacs-plus@29
/29.3/share/emacs/29.3/lisp/emacs-lisp/eldoc

Features:
(shadow sort mail-extr emacsbug message puny rfc822 mml mml-sec epa
derived epg rfc6068 epg-config gnus-util mailabbrev gmm-utils mailheader
sendmail mail-utils misearch multi-isearch face-remap yank-media
markdown-mode noutline outline vc-git vc-dispatcher eglot
external-completion jsonrpc xref flymake thingatpt diff diff-mode ert
ewoc debug backtrace advice find-func filenotify warnings icons imenu
vertico-directory cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles
cc-align cc-engine cc-vars cc-defs orderless cursor-sensor
vertico-repeat project consult bookmark pulse color persistent-soft
list-utils pcache eieio-base cl font-utils parse-time iso8601 time-date
tree-sitter-langs tree-sitter-langs-build tar-mode arc-mode archive-mode
pp tree-sitter-hl tree-sitter tree-sitter-load tree-sitter-cli tsc
tsc-dyn tsc-dyn-get compile text-property-search comint ansi-osc
ansi-color dired-aux dired dired-loaddefs tsc-obsolete marginalia
savehist vertico clang-format xml corfu-popupinfo corfu cus-load
which-key two-column hydra ring lv edmacro kmacro rainbow-delimiters
disp-table whitespace material-theme doom-modeline
doom-modeline-segments doom-modeline-env doom-modeline-core shrink-path
f s dash nerd-icons nerd-icons-faces nerd-icons-data
nerd-icons-data-mdicon nerd-icons-data-flicon nerd-icons-data-codicon
nerd-icons-data-devicon nerd-icons-data-sucicon nerd-icons-data-wicon
nerd-icons-data-faicon nerd-icons-data-powerline nerd-icons-data-octicon
nerd-icons-data-pomicon nerd-icons-data-ipsicon compat unicode-fonts
exec-path-from-shell delight server windmove recentf tree-widget
wid-edit quelpa-use-package quelpa mm-decode mm-bodies mm-encode
mail-parse rfc2231 rfc2047 rfc2045 mm-util ietf-drums mail-prsvr
lisp-mnt help-fns radix-tree cl-extra help-mode use-package
use-package-ensure use-package-delight use-package-diminish
use-package-bind-key bind-key easy-mmode use-package-core finder-inf
all-the-icons-completion-autoloads all-the-icons-autoloads
async-autoloads auto-compile-autoloads bazel-autoloads rx
blacken-autoloads cargo-autoloads clang-format-autoloads
cmake-mode-autoloads consult-autoloads copilot-autoloads
corfu-terminal-autoloads corfu-autoloads dart-mode-autoloads
doom-modeline-autoloads editorconfig-autoloads eglot-java-autoloads
eglot-autoloads exec-path-from-shell-autoloads expand-region-autoloads
flutter-autoloads flymake-autoloads eldoc-autoloads jsonrpc-autoloads
kind-icon-autoloads magit-autoloads pcase git-commit-autoloads
magit-section-autoloads marginalia-autoloads markdown-mode-autoloads
multiple-cursors-autoloads nerd-icons-autoloads orderless-autoloads
org-page-autoloads htmlize-autoloads prescient-autoloads
project-autoloads project-mode-line-tag-autoloads
protobuf-mode-autoloads quelpa-use-package-autoloads quelpa-autoloads
rust-mode-autoloads f-autoloads simple-httpd-autoloads svg-lib-autoloads
transient-autoloads tree-sitter-langs-autoloads tree-sitter-autoloads
treemacs-autoloads posframe-autoloads dash-autoloads tsc-autoloads
typescript-mode-autoloads unicode-fonts-autoloads vertico-autoloads
web-mode-autoloads which-key-autoloads with-editor-autoloads info
compat-autoloads xref-autoloads yaml-autoloads yaml-mode-autoloads
yasnippet-snippets-autoloads yasnippet-autoloads zig-mode-autoloads
reformatter-autoloads package browse-url url url-proxy url-privacy
url-expand url-methods url-history url-cookie generate-lisp-file
url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq
eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv
bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip
cconv 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 nadvice seq simple cl-generic indonesian philippine
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 abbrev obarray oclosure
cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp
files window text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget keymap hashtable-print-readable backquote
threads kqueue cocoa ns lcms2 multi-tty make-network-process emacs)

Memory information:
((conses 16 495522 257431)
 (symbols 48 30607 3)
 (strings 32 172029 24046)
 (string-bytes 1 4360706)
 (vectors 16 48125)
 (vector-slots 8 670691 444580)
 (floats 8 359 1216)
 (intervals 56 3756 2278)
 (buffers 984 19))