-
Notifications
You must be signed in to change notification settings - Fork 464
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
Error when use gr
to rename
#1306
Comments
It has to do with |
@ayamir Did u mean |
I'm coding for my company so the files are business secrets. But I can also reproduce this error on other files. 2024-06-24-22-02-07.mp4package main
import (
"fmt"
"net"
"sync"
"time"
)
const (
MAX_CONN = 10
)
func main() {
var wg sync.WaitGroup
wg.Add(1)
for i := 0; i < MAX_CONN; i++ {
go Conn("127.0.0.1:8089", i)
time.Sleep(time.Millisecond * 100)
}
wg.Wait()
}
func Conn(addr string, id int) {
conn, err := net.Dial("tcp", addr)
if err != nil {
fmt.Println(err)
return
}
fmt.Println("connect ", id)
go func() {
buf := make([]byte, 1024)
for {
n, err := conn.Read(buf)
if err != nil {
break
}
fmt.Println(id, "read: ", string(buf[:n]))
}
}()
time.Sleep(time.Second * 1)
for {
_, err := conn.Write([]byte("hello"))
if err != nil {
break
}
time.Sleep(time.Second * 10)
}
} |
At first glance it seems like there's something odd happening with |
This issue can be stably reproduced for the above file. The only method to eliminate the errors is quitting |
Maybe we can use https://github.com/smjonas/inc-rename.nvim to do rename. I prefer this style and has used it for my own config. |
@ayamir I think I saw the |
I think this issue is resolved with the changes made in this commit. |
Version confirmation
Following prerequisites
Not a user config issue
Neovim version
NVIM v0.10.0
Operating system/version
macOS 14.5 (23F79)
Terminal name/version
kitty
$TERM environment variable
No response
Branch info
0.10 (Nightly)
Fetch Preferences
SSH (use_ssh = true)
How to reproduce the issue
Trying to rename a function that appears in different files.
Expected behavior
No error
Actual behavior
Additional information
No response
The text was updated successfully, but these errors were encountered: