perspective-el icon indicating copy to clipboard operation
perspective-el copied to clipboard

Perspective.el wipes out perspectives when a emacsclient frame is closed.

Open graven04 opened this issue 2 years ago • 2 comments

The backdrop

When using emacs in daemon mode if you open a emacsclient frame and open a file and delete frame without killing buffer then next emacsclient frame you open will have that buffer in it. This is the behaviour of emacs daemon. I heavily rely on this behaviour for emacs workflow.

The problem

After learning about perspective.el I thought it will help my workflow terendously and tried it out. It works well in most respects except one case i have come upon which i will make a separate issue about. The problem is when i open emacsclient for the first time and create some perspectives and open some files and then close the frame to open a new one, all the files and perspective are gone. Now this may be useful when you are not using emacs in daemon mode but it kill the purpose of daemon mode when this behavior happens.

The solution?

i am not sure why perspective.el behaves like this when using emacs in daemon mode. I see how that behavior is useful when opening many non emacsclient frames so maybe perspective.el should not kill all perspectives when emacs in running in daemon mode. If this is not possible to do could I at least have some hack-able solution.

graven04 avatar Dec 13 '22 18:12 graven04

Actually this seems to have been talked about in some open issues. I normally check both closed and open issues for my own issues before opening one but i seem to have forgotten check the open ones. I will not close this straight away as i am still interested in the future of this issue/enhancement and wish to know when it may be implemented or if there is some temporary solution to this as my own temporary solution have not worked.

graven04 avatar Dec 13 '22 18:12 graven04

Daemon mode is poorly supported in Perspective because perspectives are tracked inside frame(-specific) parameters. Refactoring this a long-term goal of the project. See #41, #91, and #186.

gcv avatar Dec 14 '22 00:12 gcv