r3inbowari / go-mod-explorer

Go Module Explorer for Visual Studio Code (beta)
https://marketplace.visualstudio.com/items?itemName=r3inbowari.gomodexplorer
MIT License
33 stars 6 forks source link

Can not update gomod explore view when update go mod file #35

Closed qktrzrj closed 1 year ago

qktrzrj commented 2 years ago

When I updated go mod file like add new package,gomod explore does not update。

r3inbowari commented 2 years ago

Thank you for reporting, but we need some specific reproductions.

qktrzrj commented 2 years ago
微信图片_20221031112721

I delete one package, but it still show in explorer

r3inbowari commented 2 years ago

Dear @bxcxygg 🤗, All right, It seems that in some cases (depending on how the user added the package) adding a package which is not cached locally might not trigger the view update event. (Because the go get installation may not modify the go.mod file) But I'm confused about the package still showing in explorer after removing it and I can not reproduce it.

https://user-images.githubusercontent.com/30739857/198953303-7e42c10a-67b5-4ebb-a40b-ab7516a15358.mov

So, I have the following suggestions and questions for you:

  1. Which platform do you use?
  2. Would you tell me whether you used go get command to add and install it to the current module?
  3. Please check whether the package item is removed from explorer when pressing Ctrl+s on go.mod file.
  4. It would be better if you could provide the log of vscode.

Thank you very much!

qktrzrj commented 2 years ago

I used wsl2 linux(ubuntu22.04) on windows. I used go get to add package, and go mod file has been update.But explorer does not update. But today when I code on macos, explorer update right.

r3inbowari commented 2 years ago

I used wsl2 linux(ubuntu22.04) on windows. I used go get to add package, and go mod file has been update.But explorer does not update. But today when I code on macos, explorer update right.

What if you press ctrl+s or what if not using wsl on windows. I will try wsl if i have free time.

Could you please provide the log image