rmagatti / auto-session

A small automated session manager for Neovim
MIT License
1.21k stars 49 forks source link

[BUG] "n buffers wiped out" message pops up on every startup #379

Open MaroonedMind opened 16 hours ago

MaroonedMind commented 16 hours ago

Describe the bug For every existing session regardless of the amount of buffers opened in the project, on each startup of neovim the autosession plugin produces the following message: "2 buffers wiped out". I could not find the root cause or what exactly are these 2 buffers that get wiped out every time. It's clear that this happens for every session restoration, because when opening neovim by passing a path argument to it (which skips session restoration) or after deleting a corresponding session for the given workdir, there's no such message on startup. Immediately quitting and reopening neovim leads to the same message again.

To Reproduce Unclear if there's anything specific about my setup that leads to this behavior. The only step I'm taking:

  1. Open neovim without passing any path arguments.

Expected behavior There shouldn't be an identical "2 buffers wiped out" message for every single neovim run.

Screenshots

image

Checkhealth

auto-session: require("auto-session.health").check()

vim options ~
- OK vim.o.sessionoptions

Lazy.nvim settings ~
- Lazy.nvim not loaded

Config ~
- OK 
  {
    auto_create = true,
    log_level = "info",
    suppressed_dirs = { "~/Downloads", "/" }
  }

General Info ~
- Session directory: /Users/{username}/.local/share/nvim/sessions/
- Current session: /Users/{username}/Code/kong-library
- Current session file: /Users/{username}/.local/share/nvim/sessions/%2FUsers%2F{username}%2FCode%2Fkong-library.vim

Baseline (please complete the following information):

Additional context This has only started to occur after the upgrade to the recent version of autosession plugin about 3 weeks ago

cameronr commented 8 hours ago

Thanks for the report. I see the issue. It's a simple fix; I'll put together a PR shortly.