Comments (8)
There are a number of cases where the current window when the response handler is called is expected to be the window that initiated the request. Therefore, I don't think win_execute
can be easily swapped in here. Vim-go could check the window id and only attempt to change the window if the window to be changed to is different. Vim-go could also potentially track state and avoid attempts to change the window when one of the conditions that requires textlock is active.
Given that the fix to return early when changing the window to the current window has already landed in Vim, and that fix handles the most common cases appropriately without putting additional burden on plugin authors, I'm closing this.
Thank you for the clear bug report, the fast turnaround in Vim, and the discussion.
from vim-go.
vim version : 9.1.125
from vim-go.
from vim-go.
vim/vim#14073
vim/vim#14074
@fatih
thank you! plz see
from vim-go.
The win_gotoid
call locations that were referenced in vim/vim#14073 as being causes is most likely a correct analysis. Specifically, this looks like a likely candidate.
However, given that they've proposed a patch and submitted a patch, you've confirmed it resolves the problem in Vim, and that this only affects Vim versions >= 9.1.0119 and less than whatever version the patch makes it into, I don't consider this high priority.
I'll look into using win_execute
, but that may be more complicated than it first appears, and I'm less than enthusiastic about pursuing that course of action, as they've also indicated they that perhaps textlock
checking should be added to it.
from vim-go.
from vim-go.
The patch in question has now been included upstream as v9.1.0128.
I'll look into using win_execute, but that may be more complicated than it first appears, and I'm less than enthusiastic about pursuing that course of action, as they've also indicated they that perhaps textlock checking should be added to it.
That's mostly just me musing out loud. If there exists ways to close windows (or specifically, the "saved" curwin) during textlock from win_execute, it'd likely be better to just patch those holes out. (I've yet to find any.)
Anyway, provided that this plugin does not attempt win_gotoid
to a different window during textlock, there should be no more problems (but maybe it's still possible if a LSP response comes in late, say, while the completion function is sleeping?).
from vim-go.
i felt some kinds of bad feeling was happening there
Please be assured that there are no ill feelings here.
That's mostly just me musing out loud.
Thank you for clarifying.
from vim-go.
Related Issues (20)
- Vim jumps to end of file on save HOT 2
- GoSameIds end position miscalculated for identifiers at the end of line
- GoExtract sends incorrect location to LSP HOT 1
- Error detected while processing Buf WritePre HOT 1
- Error detected while processing function <SNR>129_debugasync: E117 Unknown function: state ... HOT 1
- Typecheck errors when calling a function in another go file in the same package. HOT 9
- Godef has been Invalid in code with "import C" HOT 4
- Merged #3617 breaks UltiSnips placeholder mechanism HOT 3
- Cannot install or make it work with NeoVim gives error E492: Not an editor command :GoDef HOT 2
- Auto imports not working HOT 1
- Error in identifier/syntax prevents autocommands to be executed HOT 7
- Support quoting arguments to :GoImpl HOT 3
- Development: `make lint` always fails using GNU grep 3.8 or later HOT 5
- Vim randomly stops when go_highlight_function_calls is on HOT 4
- Execution: GoFmt changes the Chinese at the end to <e4> HOT 2
- Startup time ~4 s on nvim, macos, even with empty init.lua HOT 1
- Running :GoDef or any other commands that require gopls fails without error HOT 9
- vim has defined a set of key positions that span the ages
- Thank you for sharing
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vim-go.