Cannot switch project to one using TRAMP
Expected behavior
Switching project to a TRAMP one should switch the project
Actual behavior
I get the error "You're not in a project". I believe there was a recent fix to projectile to fix TRAMP issues. Projectile now works great but I think there's something here too that needs something changed. Forgive my vagueness as I am very new to Emacs.
Steps to reproduce the problem
C-p p => select a project that is using TRAMP. Disabling helm-projectile allows projectile to select the project fine using the minibuffer.
Backtraces if necessary (M-x toggle-debug-on-error)
Debugger entered--Lisp error: (error "You’re not in a project")
signal(error ("You’re not in a project"))
error("You're not in a project")
helm-projectile-find-file()
projectile-switch-project-by-name("/ssh:cas:/home/mert/.emacs.d/")
#f(compiled-function (project) #<bytecode 0x177eb6d>)("/ssh:cas:/home/mert/.emacs.d/")
helm-execute-selection-action-1()
helm-execute-selection-action()
helm-internal(helm-source-projectile-projects nil "[-] Switch to project: " nil nil "*helm projectile: -*" nil nil nil)
apply(helm-internal (helm-source-projectile-projects nil "[-] Switch to project: " nil nil "*helm projectile: -*" nil nil nil))
helm(helm-source-projectile-projects nil "[-] Switch to project: " nil nil "*helm projectile: -*" nil nil nil)
apply(helm (helm-source-projectile-projects nil "[-] Switch to project: " nil nil "*helm projectile: -*" nil nil nil))
helm(:sources helm-source-projectile-projects :buffer "*helm projectile: -*" :truncate-lines nil :prompt "[-] Switch to project: ")
helm-projectile-switch-project(nil)
funcall-interactively(helm-projectile-switch-project nil)
call-interactively(helm-projectile-switch-project nil nil)
command-execute(helm-projectile-switch-project)
Environment & version information
helm-projectileversion: 20200625.443helmversion (inhelm-pkg.el): 20201117.815projectileversion (M-x projectile-version): 20201203.2220- Emacs version (
M-x emacs-version): GNU Emacs 26.3 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.24.14) of 2020-03-26, modified by Debian - OS: Ubuntu 20.10
It seems to me that this error is coming from help-projectile, as there's no such check in Projectile itself. I'll check if it's an easy fix.
Thanks. I believe the line is https://github.com/bbatsov/helm-projectile/blob/master/helm-projectile.el#L754
There is a tantalizing not-require-root variable in that macro, but I don't know enough about the project to comment any further on it.
I think the project check fails for TRAMP, unless you're already connected, so probably it needs something like https://github.com/bbatsov/projectile/commit/c8b71639300da597ac24994b22e4ac81f2c34f5e