# [BUG] git pull with pull.rebase and rebase.autoStash is not working anymore in 2.16

3 messages from 2018-01-24 to 2018-01-25. Participants: Dimitriy, Igor Djordjevic.
Thread: https://gitlist.dev/t/47680

## Dimitriy, 2018-01-24 12:19

Subject: [BUG] git pull with pull.rebase and rebase.autoStash is not working anymore in 2.16
Message-ID: <CAPUT4mS+p+2n85dB-iWtae+0SDkUoYA5bqtUs+6OaFchjJJeuA@mail.gmail.com>
URL: https://gitlist.dev/e/CAPUT4mS%2Bp%2B2n85dB-iWtae%2B0SDkUoYA5bqtUs%2B6OaFchjJJeuA%40mail.gmail.com

```
Looks like regression in 2.16.
Worked fine before update.
Seems like git stash is not always working.
Any ideas?

$ git --version
git version 2.16.0.windows.2

$ git config pull.rebase
true

$ git config rebase.autoStash
true

$ git status
On branch develop
Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

        modified:   source_work/xxxxx.cpp

no changes added to commit (use "git add" and/or "git commit -a")

$ git pull
Created autostash: 7ddcdf2ba
HEAD is now at ba14a4c3f some commit
Cannot rebase: You have unstaged changes.
Please commit or stash them.

$ git status
On branch develop
Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)

You are currently rebasing.
  (all conflicts fixed: run "git rebase --continue")

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

        modified:   source_work/xxxxx.cpp

no changes added to commit (use "git add" and/or "git commit -a")

$ git rebase --abort
Applied autostash.

$ git stash
Saved working directory and index state WIP on develop: ba14a4c3f  some commit

$ git status
On branch develop
Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)


        modified:   source_work/xxxxx.cpp

no changes added to commit (use "git add" and/or "git commit -a")

$ git stash
Saved working directory and index state WIP on develop: ba14a4c3f  some commit

$ git status
On branch develop
Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)

nothing to commit, working tree clean

-- 
Sincerely,
Dimitriy Ryazantcev

```

## Igor Djordjevic, 2018-01-24 18:54

Subject: Re: [BUG] git pull with pull.rebase and rebase.autoStash is not working anymore in 2.16
Message-ID: <25ce5341-1200-c54c-eb69-eccfcc088155@gmail.com>
URL: https://gitlist.dev/e/25ce5341-1200-c54c-eb69-eccfcc088155%40gmail.com
In-Reply-To: <CAPUT4mS+p+2n85dB-iWtae+0SDkUoYA5bqtUs+6OaFchjJJeuA@mail.gmail.com>

```
Hi Dimitriy,

On 24/01/2018 13:19, Dimitriy wrote:
> 
> Looks like regression in 2.16.
> Worked fine before update.
> Seems like git stash is not always working.
> Any ideas?

Could this be the same one as reported as Git for Windows issue 
#1437[1] ("`git status` reports (non-existent) modifications after 
`git stash push`", 2018-01-20), fixed in Git for Windows v2.16.1...?

Care to try it out? :)

Regards, Buga

[1] https://github.com/git-for-windows/git/issues/1437

> $ git --version
> git version 2.16.0.windows.2
> 
> $ git config pull.rebase
> true
> 
> $ git config rebase.autoStash
> true
> 
> $ git status
> On branch develop
> Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
>   (use "git pull" to update your local branch)
> 
> Changes not staged for commit:
>   (use "git add <file>..." to update what will be committed)
>   (use "git checkout -- <file>..." to discard changes in working directory)
> 
>         modified:   source_work/xxxxx.cpp
> 
> no changes added to commit (use "git add" and/or "git commit -a")
> 
> $ git pull
> Created autostash: 7ddcdf2ba
> HEAD is now at ba14a4c3f some commit
> Cannot rebase: You have unstaged changes.
> Please commit or stash them.
> 
> $ git status
> On branch develop
> Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
>   (use "git pull" to update your local branch)
> 
> You are currently rebasing.
>   (all conflicts fixed: run "git rebase --continue")
> 
> Changes not staged for commit:
>   (use "git add <file>..." to update what will be committed)
>   (use "git checkout -- <file>..." to discard changes in working directory)
> 
>         modified:   source_work/xxxxx.cpp
> 
> no changes added to commit (use "git add" and/or "git commit -a")
> 
> $ git rebase --abort
> Applied autostash.
> 
> $ git stash
> Saved working directory and index state WIP on develop: ba14a4c3f  some commit
> 
> $ git status
> On branch develop
> Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
>   (use "git pull" to update your local branch)
> 
> Changes not staged for commit:
>   (use "git add <file>..." to update what will be committed)
>   (use "git checkout -- <file>..." to discard changes in working directory)
> 
> 
>         modified:   source_work/xxxxx.cpp
> 
> no changes added to commit (use "git add" and/or "git commit -a")
> 
> $ git stash
> Saved working directory and index state WIP on develop: ba14a4c3f  some commit
> 
> $ git status
> On branch develop
> Your branch is behind 'origin/develop' by 3 commits, and can be fast-forwarded.
>   (use "git pull" to update your local branch)
> 
> nothing to commit, working tree clean

```

## Dimitriy, 2018-01-25 11:04

Subject: Re: [BUG] git pull with pull.rebase and rebase.autoStash is not working anymore in 2.16
Message-ID: <CAPUT4mTsJUd6uQRWVDwooEr4QeQa2=n1bdeJUUt3KXrT-tRDRg@mail.gmail.com>
URL: https://gitlist.dev/e/CAPUT4mTsJUd6uQRWVDwooEr4QeQa2%3Dn1bdeJUUt3KXrT-tRDRg%40mail.gmail.com
In-Reply-To: <25ce5341-1200-c54c-eb69-eccfcc088155@gmail.com>

```
Yeah it seems like this bug. Thank you for sharing this with me.
-- 
Sincerely,
Dimitriy Ryazantcev

> Could this be the same one as reported as Git for Windows issue
> #1437[1] ("`git status` reports (non-existent) modifications after
> `git stash push`", 2018-01-20), fixed in Git for Windows v2.16.1...?
>
> Care to try it out? :)
>
> Regards, Buga
>
> [1] https://github.com/git-for-windows/git/issues/1437

```
