Skip to content
GitLab
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • TortoiseGit TortoiseGit
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
    • Locked files
  • Issues 384
    • Issues 384
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 14
    • Merge requests 14
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
    • Test cases
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Model experiments
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • TortoiseGitTortoiseGit
  • TortoiseGitTortoiseGit
  • Issues
  • #3820
Closed
Open
Issue created Nov 12, 2021 by Marcono1234@Marcono1234

"Stash changes" should not offer stash pop/apply after no changes were stashed

When you use the "Stash changes" command, but there are no changes to stash the command still acts successfully. This is problematic because:

  • It might indicate you forgot to add files to the index before or chose the wrong stash options. Because the dialog looks successful you might erroneously assume you have saved your changes and overwrite them irrevocably.
  • The success dialog offers you a "Stash Pop" button. However, because you did not actually save anything on the stash you will end up popping completely unrelated changes.

What steps will reproduce the problem?

  1. In a repository without any changes, run "Stash changes"
  2. Have a look at the progress dialog
    ❌ It says: "Success" and has a green progress bar

What is the expected output? What do you see instead?

Expected: When "Stash changes" does not find any changes to stash it should fail:

  • The progress text should say in red that the operation failed (like it is the case for other failed Git operations).
  • The progress bar should be red (like it is the case for other failed Git operations).
  • The dialog should neither offer a "Stash Pop" nor "Stash Apply" button

Actual: The dialog says "Success" and offers a "Stash Pop" and "Stash Apply" button.

What version of TortoiseGit and Git are you using? On what operating system?

Microsoft Windows [Version 10.0.19043.1348]
TortoiseGit 2.12.0.0
git version 2.33.1.windows.1

Edited Dec 29, 2021 by Sven Strickroth
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking