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

Global git commands don't show errors #41519

Closed
ronaldruzicka opened this issue Jan 12, 2018 · 14 comments
Closed

Global git commands don't show errors #41519

ronaldruzicka opened this issue Jan 12, 2018 · 14 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug git GIT issues good first issue Issues identified as good for first-time contributors help wanted Issues identified as good community contribution opportunities verified Verification succeeded
Milestone

Comments

@ronaldruzicka
Copy link

Hi 👋,

Would it be possible to have notifications of successful/unsuccessful git push, git pull, etc?

It happens sometimes that git push or git pull is unsuccessful and I don't even know about it and don't even know what went wrong. There is just the small arrow in the bottom left of the screen that indicate pending push, but it's really easy to miss.

Thanks!

@vscodebot vscodebot bot added the git GIT issues label Jan 12, 2018
@joaomoreno
Copy link
Member

An unsuccessful push or pull should report an error message for sure. How do you run the actions themselves?

@joaomoreno joaomoreno added the info-needed Issue requires more information from poster label Jan 12, 2018
@ronaldruzicka
Copy link
Author

I'm using the integrated Git by VS Code from Command palette. If I use the terminal I see an error there, but I got used to the Command palette, it's faster.

screen shot 2018-01-12 at 09 52 27

@lohxx
Copy link

lohxx commented Jan 15, 2018

Thats is a great idea

@joaomoreno joaomoreno changed the title Have git notifications or messages Global git commands don't show errors Jan 18, 2018
@joaomoreno joaomoreno added bug Issue identified by VS Code Team member as probable bug and removed info-needed Issue requires more information from poster labels Jan 18, 2018
@joaomoreno joaomoreno added this to the Backlog milestone Jan 18, 2018
@ronaldruzicka
Copy link
Author

Hi @joaomoreno, please are there any news about this issue? I see that even after the changes in notifications it still ignores Git actions.

@joaomoreno joaomoreno added help wanted Issues identified as good community contribution opportunities good first issue Issues identified as good for first-time contributors labels Apr 16, 2018
@joaomoreno
Copy link
Member

I've added a couple tags, let's see if someone picks it up.

@chenhowa
Copy link

chenhowa commented Apr 22, 2018

@joaomoreno I'd like to pick this up as a first issue if possible.

@ronaldruzicka Is there a simple way to reproduce the issue of a push/pull failing without notification? It seems very simple to add a notification (in git/src/commands.ts) if the push did not throw any errors. But I'm not very experienced with git, so I haven't found a way to make push/pull fail silently -- for the "common" cases I've tried, I get an error message dialog.

@chenhowa
Copy link

@joaomoreno Do you know where the cause of the silent errors might be? I don't know if there are cases where git.push/pull doesn't throw an error even though it should. It seems like the calling code is already set up to catch errors thrown by git.push/pull, and show a dialog displaying the error.

@ronaldruzicka
Copy link
Author

@chenhowa Well the most common case is, when you try to push something into remote but you have to pull changes first. When I use the integrated VS Code git, I don't get a notification, that my changes haven't been pushed and that I need to pull changes first. I just see on the bottom left that the push is still pending like this screen shot 2018-04-22 at 22 04 33, although on this screenshot I don't have any remote changes to be pulled, but you know what I mean.

It would be nice to be notified that the push, or other actions, failed and why, like when you do it from the console.

@chenhowa
Copy link

chenhowa commented Apr 27, 2018

Sorry it took a while to get back to you.

What I've found is that from Command Palette, Git: Push and Git: Pull always warn me when they fail according to your scenario. However, Git: Push To and Git: Pull From do not always warn me when there is a conflict.

Are "Pull from" and "Push to" the commands that are giving you trouble?

@chenhowa
Copy link

@ronaldruzicka ping

@ronaldruzicka
Copy link
Author

Hi, I'm using pull rebase and push to:

pull-rebase

push-to

Next time I'll try just pull and push and let you know.

@chenhowa
Copy link

chenhowa commented Apr 29, 2018

Okay, thanks. But actually, let me know if Pull (Rebase) still fails to report Failure to you. I've fixed the issue for Push To and Pull From (at least on my machine), and based on my understanding of the fix, Pull (Rebase) should report errors to the user.

If it isn't doing that for you, then I haven't found the actual source(s) of the problem.

Also, I don't know if you still want this, but I don't think it would be a net positive to add a notification for when the push/pull is successful. In the long term, it would be more distracting than informative.

@ronaldruzicka
Copy link
Author

Hi @chenhowa , sorry for late reply.

So I have VS Code Version 1.23.1 and still have the issue. If I do push I have a notification, but not classic one on the bottom right, but some alert message on top. But if I do push to I don't get any notification, I can only see the small arrow on bottom left, that commit is still pending.

git-push-no-notification

@chenhowa
Copy link

@ronaldruzicka
As far as I could tell, most if not all Git errors from the command palette are handled using the alert message on top, instead of the classic on on the bottom right. So in my commit, "Push to" handles errors using the alert message on top, to stay consistent.

Unfortunately, the commit hasn't been merged yet: it's in the Backlog. Hopefully it will make it to a future version of VS Code, but the timeline for that isn't clear.

@vscodebot vscodebot bot locked and limited conversation to collaborators Aug 2, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug git GIT issues good first issue Issues identified as good for first-time contributors help wanted Issues identified as good community contribution opportunities verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

5 participants