Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

projectile-find-file crashes when viewing a file over SSH #1898

Open
modulitos opened this issue Jul 25, 2024 · 0 comments
Open

projectile-find-file crashes when viewing a file over SSH #1898

modulitos opened this issue Jul 25, 2024 · 0 comments

Comments

@modulitos
Copy link

Expected behavior

When I'm viewing a file over an SSH connection on a remote server, M-x projectile-find-file opens the minibuffer with a list of files in the project to select.

Actual behavior

Minibuffer doesn't open, with these messages in my *Messages* buffer:

Projectile is initializing cache for /ssh:my.example.com:/home/me/projects/my-remote-project/ ...
project--read-file-cpd-relative: Wrong type argument: stringp, nil

Note that the "Projectile is initializing cache..." message appears every time I run projectile-find-file, as if the project isn't being created/cached successfully.

Steps to reproduce the problem

  1. open a file over SSH with TRAMP, where the file is within a git repo (C-x C-f /ssh:my.example.com:/home/me/projects/my-remote-project/readme.md)
  2. the file opens successfully (SSH and TRAMP are working)
  3. run M-x projectile-find-file

My minibuffer should show list of files within that repo that I can select, but there are no files.

Note that everything works as expected when I open a file on my local machine:

  1. The minibuffer opens, with a prompt like 1/12 [my-local-project] Find file:, and a list of files to select
  2. The "Projectile is initializing cache..." only happens the first time I run projectile-find-file within that repo, indicating that the project was created and cached successfully.

Environment & Version information

Projectile version information

2.9.0-snapshot

(via Doom Emacs)

Emacs version

29.1

Operating system

Macos Sonoma 14.5 (23F79)

Other notes

projectile-indexing-method is set to hybrid

fd is present on my remote machine, and is on my path when I run TERM=dumb ssh my.example.com

Perhaps related to this issue: #1886

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant