I keep getting this error:
Error running timer ‘treemacs--process-file-events’: (error "‘recenter’ing a window that does not display current-buffer.")
Can't really pinpoint what triggers it. What can I do to debug this issue?
First make sure your treemacs is up-to-date. I did some work on the recenter parts recently, you might have caught a bad version.
Can't really pinpoint what triggers it.
Not surprising, that part is a couple macros deep. Try debug-on-error. If that won't work try (setf debug-on-message (rx (1+ any) "treemacs--process-file-events" (1+ any))).
I'm using the latest version, I think: treemacs-20190219.1558.
I've tried debug-on-error and got this:
recenter()
treemacs--maybe-recenter(on-distance)
treemacs--expand-root-node(#
treemacs--do-refresh(#
[cl-struct-treemacs-project "siiue"
"/home/gjm/work/siiue/siiue2020/src/siiue"])
treemacs--recursive-refresh()
treemacs--process-file-events()
apply(treemacs--process-file-events nil)
timer-event-handler([t 23661 31567 780260 nil
treemacs--process-file-events nil nil 859000])
Gonçalo Marrafa
On Wed, 20 Feb 2019 at 16:05, Alexander-Miller notifications@github.com
wrote:
First make sure your treemacs is up-to-date. I did some work on the
recenter parts recently, you might have caught a bad version.Can't really pinpoint what triggers it.
Not surprising, that part is a couple macros deep. Try debug-on-error. If
that won't work try (setf debug-on-message (rx (1+ any)
"treemacs--process-file-events" (1+ any))).—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Alexander-Miller/treemacs/issues/363#issuecomment-465641608,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAEuMOg4ydI1eqmB-d1AtArwokOqUtukks5vPXI9gaJpZM4bFctj
.
I think I know what to do. In the meantime you can set treemacs-recenter-after-project-expand to nil.
Will do. Thanks-
Should be fixed now. Please verify.
@Alexander-Miller I got this error now.
Debugger entered--Lisp error: (wrong-type-argument hash-table-p nil)
gethash("/Users/vincent/.emacs.d/.cache" nil nil)
treemacs--apply-deferred-git-state(#<marker at 22 in *Treemacs-Framebuffer-1*> #<process Process Future> #<buffer *Treemacs-Framebuffer-1*>)
apply(treemacs--apply-deferred-git-state (#<marker at 22 in *Treemacs-Framebuffer-1*> #<process Process Future> #<buffer *Treemacs-Framebuffer-1*>))
timer-event-handler([t 23675 23651 785673 nil treemacs--apply-deferred-git-state (#<marker at 22 in *Treemacs-Framebuffer-1*> #<process Process Future> #<buffer *Treemacs-Framebuffer-1*>) nil 0])
@seagle0128 I cannot reproduce that. That part of the code involves plenty of hash tables, can you jump into the debugger and tell me which line of treemacs--apply-deferred-git-state the error occurs in?
@Alexander-Miller it's line 469.
You sure? That line isn't doing anything hash-related.
@Alexander-Miller It should be https://github.com/Alexander-Miller/treemacs/blob/bd7767162a30fe939d0d432e6a6bc949860c0aa9/src/elisp/treemacs-rendering.el#L472 now.
What is the result you expect to see - does the error happen everywhere or only files that are (not) under version control, does it affect only a part of a project, or all of it?
It looks like this nil error can occur when the git process fails. I can close that gap, but it that'd be removing just a symptom, and not the cause. What does the follow code output for you:
(-> "/dir/where/error/happens"
(treemacs--git-status-process-function)
(pfuture-await-to-finish))
@Alexander-Miller After upgrading the package, I didn't see this error. I will keep on my eyes. Thanks!
I did recently switch up the git-mode implementation in https://github.com/Alexander-Miller/treemacs/commit/871069296400425c7ebe84dddbc4b841d40e39b0, so maybe the transition wasn't quite smooth for you. Did you restart emacs after the update that brought on the git problem?
@Opimenov how about you?
yes I did.
Best Regards
Alex Pimenov
From: Alexander-Miller notifications@github.com
Sent: Monday, March 4, 2019 2:04 PM
To: Alexander-Miller/treemacs
Cc: Alex Pimenov; Mention
Subject: Re: [Alexander-Miller/treemacs] I keep getting this error: error "‘recenter’ing a window that does not display current-buffer." (#363)
I did recently switch up the git-mode implementation in 8710692https://github.com/Alexander-Miller/treemacs/commit/871069296400425c7ebe84dddbc4b841d40e39b0, so maybe the transition wasn't quite smooth for you. Did you restart emacs after the update that brought on the git problem?
@Opimenovhttps://github.com/Opimenov how about you?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/Alexander-Miller/treemacs/issues/363#issuecomment-469379977, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ANPzODeOLmHimjT9dg5fA8nopdM-4RYzks5vTW4lgaJpZM4bFctj.
What about the test code in https://github.com/Alexander-Miller/treemacs/issues/363#issuecomment-469310284 ?
Traceback (most recent call last):
File \"~/.emacs.d/elpa/treemacs-20190303.1245/treemacs-git-status.py\," line 10 in <module>
STDOUT = sys.stdout.buffer
AttributeError: 'file' object has no attribute 'buffer'
2 things:
treemacs-python-executable.Sure, if you want to help you can give https://github.com/Alexander-Miller/treemacs/issues/370 a go.
Housekeeping.
Most helpful comment
2 things:
treemacs-python-executable.