-
Notifications
You must be signed in to change notification settings - Fork 154
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
dumb-jump "hanging" #383
Comments
Thanks for opening this. Problem 1
Problem 2This is already outlined in #101 as you mentioned but sounds like there's just no project denoter in your project so it keeps looking at the parent until it gets to
I am definitely open to either of these ideas if someone wants to open a PR but in practice, I think needing something like this ends up being quite rare. Problem 3
This is not a timeout nor do I think it is ever advertised as such. That said, I totally agree it would be nice if this was a timeout. I think I attempted to add this at some point but the single-threaded nature of emacs made this an easier said than done thing. Again, I am more than happy to consider a PR if anyone wants to add this type of functionality. |
Closing, but happy to reopen if I missed or misunderstood anything above. |
sorry to take so long... problem 1totally understood. all on my side. still confusing. problem 2The easiest solution might be to add a file to the project I'm in. But what about my (not exaggerating) 99 others ? I still think it is a mistake to back up to the user's home and search from there. I can't imagine a scenario where that is the desired outcome unless they fired it off in that directory.
That depends entirely on the VCS. Not all have hidden dirs at the top. Some have literally nothing. I still think there could be some smarts added here... Obviously there could be a custom option to determine the behavior, but even simply erroring would help clue in the user that something is wrong and problem 3It's kinda implied by the name... it's called
|
I don't follow your point here. You're only ever searching in one project at a time, so you only ever need to handle (ensure it has a denoter) one project at a time. One time cost per project. If you have 99 projects that have absolutely no popular project denoters, then worst case it's a few lines of bash to inject a
I haven't come across one. Curious to hear examples, but usually there is something in the project root (like a
Please expand on this. What exactly is triggering the error? That we landed back into your Seems like you're hitting a lot of edge cases here. I am more than happy to accept PRs, but I don't see many obvious/easy things to change that are going to be a win for everyone and I have a strong urge to keep this project as "dumb" as possible. |
I get that... I have a popular ruby project called "minitest" and people keep trying to make it not-so-mini... I'll ponder and work on a PR. |
I recently (inadvertantly) bumped from melpa-stable at 0.5.3 (iirc) to melpa and am having some pain now. I believe this is related to #101 but I have more info. Here's my basic setup, explanation below:
;; hooks/enh-ruby-mode.el (dumb-jump-mode)
so, on first load of a ruby file, dumb-jump-mode is invoked, which hits the autoload, which triggers my
eval-after-load
... that, for some reason causesdumb-jump-quick-look
to actually trigger. And that is going through the following problematic stack trace:Problem 1: I can't find how/why the
eval-after-load-helper
is invokingdumb-jump-quick-look
.It just doesn't look like
quick-look
is hooked anywhere that I can find.(in describing this problem, it dawned on my that I'm using
eval-after-load
without quoting the form (or just usingwith-eval-after-load
)... this makes problem 1 go away, but I still don't know what it is about the code above that is causing quick-look to trigger on file load/revert—feel free to ignore this one, I believe the other 2 problems are still relevant)Problem 2: is that
dumb-jump-go
and/or friends have decided to walk all the way up to my home before starting a search, which is what the actual "hang" is.Ignoring problem 1 for a sec...
I think if the traversal up winds up in the home directory, it should NOT search there and instead search in the directory of the originating file. Warn about not finding the top of a project, etc... something.
Adding config
dumb-jump-stop-if-project-not-found
(with options'stop
,'warn
,'continue
) ordumb-jump-disallow-home
or somesuch would help here too.Problem 3: is that the 2 second timeout is clearly NOT working.
With
dumb-jump-debug
set tot
, I would hope that the combination of the two would provide quick feedback as to what is going wrong. Instead, I had to turn ondebug-on-exit
to get a stack trace that pointed out it was scanning home.I see looking through the code that this only warns about the time and there is no timeout mechanism. I could see value in having an actual timeout vs having something that warns that you might be missing a faster binary.
The text was updated successfully, but these errors were encountered: