Skip to content
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

"Delete Branch" option is sometimes missing (Branches view desync's from git status; requires manual refresh to appear) #3707

Open
kkaja123 opened this issue Nov 1, 2024 · 0 comments
Labels
bug Something isn't working triage Needs to be looked at

Comments

@kkaja123
Copy link

kkaja123 commented Nov 1, 2024

Description

Might be a regression of #3582

From what I can tell, the Delete Branch option does not show up for branch A if you start on branch A, switch to branch B, and then try to use the Delete Branch option.

This may be related to using the built-in source control feature to switch branches instead of using the GitLens Branches view. Once I used the Refresh button on the Branches view, the "Delete Branch" option appeared on the inactive branch A.

In the Branches view after performing a Refresh of the view, GitLens seems to not realize that the current branch is active after performing a switch.

E.g. Switch from "initial-release" to "main", Git reports "main" as the current branch, but the Branches view still allows me to attempt to switch to the "main" branch (note that the switch branch button is enabled for both branches):
Image

When I use the button to switch to the "main" (current) branch, it asks which branch I want to switch to (not the normal behavior for this button). When I use the button to switch to the "initial-release" (inactive) branch, it switches to that branch right away (as expected), but then the Branches view disables the switch button for the "main" (now inactive) branch, and the switch button for the "initial-release" (now current) branch remains enabled. Refreshing the Branches view returns the button states to the example image (both enabled; not expected behavior).

GitLens Version

15.6.2

VS Code Version

Version: 1.94.2 (system setup)
Commit: 384ff7382de624fb94dbaf6da11977bba1ecd427
Date: 2024-10-09T16:08:44.566Z
Electron: 30.5.1
ElectronBuildId: 10262041
Chromium: 124.0.6367.243
Node.js: 20.16.0
V8: 12.4.254.20-electron.0
OS: Windows_NT x64 10.0.19045

Git Version

git version 2.39.2.windows.1

Logs, Screenshots, Screen Captures, etc

No response

@kkaja123 kkaja123 added bug Something isn't working triage Needs to be looked at labels Nov 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage Needs to be looked at
Projects
None yet
Development

No branches or pull requests

1 participant