easy-dotnet.nvim icon indicating copy to clipboard operation
easy-dotnet.nvim copied to clipboard

bug: Buffer with that name already exists

Open franroa opened this issue 6 months ago • 0 comments

I am gettings this error when running Dotnet testrunner twice:

Error executing Lua callback: .../easy-dotnet.nvim/lua/easy-dotnet/test-runner/render.lua:16: Vim:E95: Buffer with this name already exists
stack traceback:
	[C]: in function 'nvim_buf_set_name'
	.../easy-dotnet.nvim/lua/easy-dotnet/test-runner/render.lua:16: in function 'setBufferOptions'
	.../easy-dotnet.nvim/lua/easy-dotnet/test-runner/render.lua:84: in function 'render'
	.../easy-dotnet.nvim/lua/easy-dotnet/test-runner/runner.lua:91: in function 'runner'
	...hare/nvim/lazy/easy-dotnet.nvim/lua

Context: I have added the filtetype "easy-dotnet" to the edgy.nvim layout, so I can easily hide/open/change/etc.. the window. Maybe, and also thinking about the other issue (https://github.com/GustavEikaas/easy-dotnet.nvim/issues/36), an option would be to pass an argument to Dotnet testrunner. Something like:

  • Dotnet testrunner toggle all (opens or creates a buffer. If it creates the buffer run the discovery job)
  • Dotnet testrunner toggle failed (opens or creates a buffer. If it creates the buffer I guess it shoud discover, run and filter failed tests)

franroa avatar Aug 22 '24 06:08 franroa