git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git bug

From
MSmoti sd <motisd8@gmail.com>
Date
Feb 4, 2024, 23:42 UTC
Message-ID
<CAPvDF0P7_s-iy_V7FNSHtXXc9v5E3Fm=AdgduDDsd0rM-zNg-g@mail.gmail.com>
Dear Git Team,

I am writing to report a potential bug encountered while using the "git stash" command. The issue was observed during a troubleshooting. Please find the details below:

*Problem Description:*

The "git stash" command is not providing any feedback or indication of execution, even though modifications are present and the stash operation is attempted. *Steps to Reproduce:*

Make modifications to a file. Execute "git stash" to stash changes. *Expected Behavior:*

The "git stash" command should provide feedback on the stash operation, confirming whether it was successful or if there were any errors. *Additional Information:* The issue was initially observed when executing "git commit -a --amend" and pressing Ctrl+Z to exit. Subsequent attempts to use "git stash" resulted in an error. Testing with a provided ZIP file containing a problematic repository confirmed the issue's recurrence. *Investigation and Findings:*

Upon investigation, it was discovered that the use of Ctrl+Z after "git commit -a --amend" might be the root cause. Deleting a lock file left behind by the incomplete git command resolved the issue, indicating a potential bug in how "git stash" handles incomplete commands. *Recommendation:*

The "git stash" command should provide meaningful feedback or error messages to users, even in cases where the operation is incomplete or encounters issues. *Steps to Reproduce the Bug:*

Execute "git commit -a --amend." Press Ctrl+Z to exit the command. Attempt "git stash." *Attachment:* A ZIP file containing a problematic repository is attached for your reference. *Impact:*

The bug affects users' ability to use the "git stash" command effectively, leading to potential confusion and hindering workflow. Resolution:

I appreciate your attention to this matter, and I believe addressing this bug will enhance the overall user experience with Git. If further information or testing is required, please feel free to reach out.

Best regards, Moti

Thank you for filling out a Git bug report! Please answer the following questions to help us understand your issue.

What did you do before the bug happened? (Steps to reproduce your issue) I executed "git commit -a --amend," where I pressed Ctrl+Z to exit. Later, when trying again, an error occurred.

What did you expect to happen? (Expected behavior) I intended to execute the "git stash" command, but it is not functioning as expected. I wish to receive an error message to better understand the issue and address it accordingly. The command is silent, whereas during a commit, error messages are displayed, providing helpful feedback for resolution. What happened instead? (Actual behavior) Due to .git/lock file, git stash does not behave normally, and the error message does not show up

Please review the rest of the bug report below. You can delete any lines you don't wish to share.

[System Info] git version: git version 2.38.1.windows.1 cpu: x86_64 built from commit: b85c8f604d375d4d773a36842964e8a7ec056aae sizeof-long: 4 sizeof-size_t: 8 shell-path: /bin/sh feature: fsmonitor--daemon uname: Windows 10.0 22631 compiler info: gnuc: 12.2 libc info: no libc information available $SHELL (typically, interactive shell): <unset>

[Enabled Hooks]
Next: Patrick Steinhardt
Message 1 of 8 in “git bug”
  1. moti sdFeb 4, 2024
  2. Patrick SteinhardtFeb 5, 2024
  3. builtin/stash: report failure to write to indexPatrick Steinhardt, Feb 5, 2024
  4. Rubén JustoFeb 5, 2024
  5. Patrick SteinhardtFeb 6, 2024
  6. Junio C HamanoFeb 6, 2024
  7. Patrick SteinhardtFeb 6, 2024
  8. builtin/stash: report failure to write to indexPatrick Steinhardt, Feb 6, 2024

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.