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

Random "*emacs*" buffers are created with default config #61

Closed
domsch1988 opened this issue Feb 26, 2024 · 4 comments
Closed

Random "*emacs*" buffers are created with default config #61

domsch1988 opened this issue Feb 26, 2024 · 4 comments

Comments

@domsch1988
Copy link

domsch1988 commented Feb 26, 2024

I'm trying to make this compact, as i have been tracking this down for weeks now and just linked it to blamer.

Basically, moving through a file creates a random number of emacs buffers
image
This only starts once blamer is actually loaded. The default defers this to 20 Seconds of idle time. After a fresh restart this behavior only starts once blamer is loaded.

Buffers are mostly empty, some contain Lisp Expression: and nothing else.

My entire config is here: https://gitlab.com/domsch1988/domacs
But the blamer configuration is basically copied from the Readme

(use-package blamer
  :bind (("C-c g b" . blamer-show-commit-info))
  :defer 20
  :custom
  (blamer-idle-time 0.3)
  (blamer-min-offset 70)
  :custom-face
  (blamer-face ((t :background nil
                   :height 100
                   :italic t)))
  :config
  (global-blamer-mode 1))

I'm running a fresh compilation of emacs master (30.0.50) on Arch in WSL. But i'm able to reproduce this with a stable 29 on debian, also WSL. I'll test this on a bare meta Arch install later, but i'm pretty sure it's not WSL related. The Arch WSL Setup is also a fresh install from this morning and does nothing but run emacs.

Currently i don't have more information, but i'm happy to help out and provide what ever is necesarry. I'm just not sure how to get more information on how these buffers come to be. I'd love to use blamer, but having around 70 buffers open after half an hour, sadly isn't workable for me.

Edit:
From the Reddit thread here, i got some hints to where the issue might be:

blamer.el/blamer.el

Lines 1153 to 1163 in f79a742

(defun blamer--async-start (start-func &optional finish-func)
"Optional wrapper over \\='async-start function.
Needed for toggling async execution for better debug.
START-FUNC - function to start
FINISH-FUNC - callback which will be printed after main function finished"
(if blamer-enable-async-execution-p
(async-start start-func finish-func)
(if finish-func
(funcall finish-func (funcall start-func))
(funcall start-func))))

Note that their wrapper makes the finish-func optional. If it is not provided, "emacs" buffers will be left to clean up as described in the async docs I linked earlier.

@Artawower
Copy link
Owner

Thanks for such a good explanation. Unfortunately even finish-func is provided it also spawn such buffers. I will look into this issue in more detail

This is due to the recent switch to async api, it may have some bugs in it.
Until then, you can use (setq blamer-enable-async-execution-p nil) in your config to avoid asynchronous execution issues.

@domsch1988
Copy link
Author

Thanks, this setting seems to work for me. I'll keep an eye out if it has any negative impact for me.

@Artawower
Copy link
Owner

Could you please try version 0.8.3 with enabled async backend? It should be fixed.

Killing the process did not kill the associated buffer.

@domsch1988
Copy link
Author

Have been running 0.8.4 (according to elpaca) for half a day now without issues. So from my point of view this seems to be fixed.

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

2 participants