threads / discuss / 13299

reflog/show question

Subject: reflog/show question

## tl;dr

11 messages between Apr 28, 2008 and May 2, 2008.

replies: 10people: 2as markdown or json

Geoff Russell· Apr 28, 2008, 01:59 UTC · lore
     git show HEAD@{"3 minutes ago"}
works as I expect, but
     git show HEAD@{"3 minutes ago"}:data/node/node.data
gives me a message:
       warning: Log for 'HEAD' only goes back to Mon, 28 Apr 2008
10:18:37 +0930.
       fatal: ambiguous argument
'HEAD@{3.minutes.ago}:data/node/node.newds1': unknown revision or path
not in the working tree.
       Use '--' to separate paths from revisions
However,
     git show HEAD@{2}:data/node/node.data
shows me the file as it was 3 minutes ago.
I'm using 1.5.4.rc4
Cheers,
Geoff Russell
Jeff King· Apr 28, 2008, 09:24 UTC · re: Geoff Russell · lore

Re: reflog/show question

On Mon, Apr 28, 2008 at 11:29:17AM +0930, Geoff Russell wrote:
Show 13 quoted lines
>      git show HEAD@{"3 minutes ago"}
> 
> works as I expect, but
> 
>      git show HEAD@{"3 minutes ago"}:data/node/node.data
> 
> gives me a message:
> 
>        warning: Log for 'HEAD' only goes back to Mon, 28 Apr 2008
> 10:18:37 +0930.
>
> [...]
> I'm using 1.5.4.rc4

I can't reproduce here, using the current master or v1.5.4-rc4. If I have a matching reflog, both work. And if I choose a much older time (say, "1.year.ago"), then both fail. What are the entries in your reflog (.git/logs/HEAD)?

-Peff
Geoff Russell· Apr 29, 2008, 01:47 UTC · re: Jeff King · lore

Re: reflog/show question

On Mon, Apr 28, 2008 at 6:54 PM, Jeff King <peff@peff.net> wrote:
Show 21 quoted lines
> On Mon, Apr 28, 2008 at 11:29:17AM +0930, Geoff Russell wrote:
>
>  >      git show HEAD@{"3 minutes ago"}
>  >
>  > works as I expect, but
>  >
>  >      git show HEAD@{"3 minutes ago"}:data/node/node.data
>  >
>  > gives me a message:
>  >
>  >        warning: Log for 'HEAD' only goes back to Mon, 28 Apr 2008
>  > 10:18:37 +0930.
>  >
>  > [...]
>
> > I'm using 1.5.4.rc4
>
>  I can't reproduce here, using the current master or v1.5.4-rc4. If I
>  have a matching reflog, both work. And if I choose a much older time
>  (say, "1.year.ago"), then both fail. What are the entries in your
>  reflog (.git/logs/HEAD)?

I think its something to do with the filename and my commit comments. The command works as expected on other files. The HEAD file is attached.

Geoff
>
>  -Peff
>
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069
Jeff King· Apr 29, 2008, 20:12 UTC · re: Geoff Russell · lore

Re: reflog/show question

On Tue, Apr 29, 2008 at 11:17:09AM +0930, Geoff Russell wrote:
Show 15 quoted lines
> >  >      git show HEAD@{"3 minutes ago"}
> >  >
> >  > works as I expect, but
> >  >
> >  >      git show HEAD@{"3 minutes ago"}:data/node/node.data
> >  >
> >  > gives me a message:
> >  >
> >  >        warning: Log for 'HEAD' only goes back to Mon, 28 Apr 2008
> >  >        10:18:37 +0930.
> >  >
> >
> I think its something to do with the filename and my commit comments.
> The command works as expected on other files.  The HEAD file is
> attached.

Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"} actually _has_ the file data/node/node.data? If it doesn't, then you get the error message you saw. And it may be that the reflog warning happens in _both_ cases, only you don't see it in the first because it is masked by the pager. In v1.5.5, that output is now sent to the pager, instead.

-Peff
Geoff Russell· Apr 29, 2008, 22:06 UTC · re: Jeff King · lore

Re: reflog/show question

On 4/30/08, Jeff King <peff@peff.net> wrote:
Show 28 quoted lines
> On Tue, Apr 29, 2008 at 11:17:09AM +0930, Geoff Russell wrote:
>
>  > >  >      git show HEAD@{"3 minutes ago"}
>  > >  >
>  > >  > works as I expect, but
>  > >  >
>  > >  >      git show HEAD@{"3 minutes ago"}:data/node/node.data
>  > >  >
>  > >  > gives me a message:
>  > >  >
>  > >  >        warning: Log for 'HEAD' only goes back to Mon, 28 Apr 2008
>  > >  >        10:18:37 +0930.
>  > >  >
>  > >
>
> > I think its something to do with the filename and my commit comments.
>  > The command works as expected on other files.  The HEAD file is
>  > attached.
>
>
> Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"}
>  actually _has_ the file data/node/node.data? If it doesn't, then you get
>  the error message you saw. And it may be that the reflog warning happens
>  in _both_ cases, only you don't see it in the first because it is masked
>  by the pager. In v1.5.5, that output is now sent to the pager, instead.
>
>  -Peff
>

Later today (touch wood) I'll prepare as small a test case as possible, then send a tar.gz of the .git directory. Okay?

Geoff.
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069
Jeff King· Apr 29, 2008, 23:07 UTC · re: Geoff Russell · lore

Re: reflog/show question

On Wed, Apr 30, 2008 at 07:36:23AM +0930, Geoff Russell wrote:
Show 6 quoted lines
> > Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"}
> >  actually _has_ the file data/node/node.data? If it doesn't, then you get
> 
> Later today (touch wood) I'll prepare as small a test case as
> possible, then send
> a tar.gz of the .git directory. Okay?
That would be great, thanks.
-Peff
Geoff Russell· Apr 30, 2008, 00:12 UTC · re: Jeff King · lore

Re: reflog/show question

On Wed, Apr 30, 2008 at 8:37 AM, Jeff King <peff@peff.net> wrote:
Show 11 quoted lines
> On Wed, Apr 30, 2008 at 07:36:23AM +0930, Geoff Russell wrote:
>
>  > > Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"}
>  > >  actually _has_ the file data/node/node.data? If it doesn't, then you get
>  >
>
> > Later today (touch wood) I'll prepare as small a test case as
>  > possible, then send
>  > a tar.gz of the .git directory. Okay?
>
>  That would be great, thanks.
Attached is tar.gz of working directory (.) - so unpack in a new directory.
       git show HEAD@{"N seconds ago"}:data/node/.gitignore
works fine for values of N back to creationof file
But:
       git show HEAD@{"N seconds ago"}:data/node/node.newds1
doesn't work for any values of N.

During my attempts to create this example, I managed created a directory which where the show command failed for both files, but when I changed the commit message, the show worked for .gitignore but not the node file. Hence my suspicion of that the slashes in the path are being interpreted as requesting a commit message match ...?

I hope you can track it down, I will install the latest version of git later on today to confirm the behaviour is still happening.

Thanks, Geoff Russell

>
>  -Peff
>
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069
Geoff Russell· Apr 30, 2008, 00:26 UTC · re: Geoff Russell · lore

Re: reflog/show question

On Wed, Apr 30, 2008 at 9:42 AM, Geoff Russell <geoffrey.russell@gmail.com> wrote:

Show 37 quoted lines
>
> On Wed, Apr 30, 2008 at 8:37 AM, Jeff King <peff@peff.net> wrote:
>  > On Wed, Apr 30, 2008 at 07:36:23AM +0930, Geoff Russell wrote:
>  >
>  >  > > Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"}
>  >  > >  actually _has_ the file data/node/node.data? If it doesn't, then you get
>  >  >
>  >
>  > > Later today (touch wood) I'll prepare as small a test case as
>  >  > possible, then send
>  >  > a tar.gz of the .git directory. Okay?
>  >
>  >  That would be great, thanks.
>
>  Attached is tar.gz of working directory (.) - so unpack in a new directory.
>
>        git show HEAD@{"N seconds ago"}:data/node/.gitignore
>
>  works fine for values of N back to creationof file
>
>  But:
>
>        git show HEAD@{"N seconds ago"}:data/node/node.newds1
>
>  doesn't work for any values of N.
>
>  During my attempts to create this example, I managed created a
>  directory which where
>  the show command failed for both files, but when I changed the commit
>  message, the
>  show worked for .gitignore but not the node file. Hence my suspicion
>  of that the slashes
>  in the path are being interpreted as requesting a commit message match ...?
>
>  I hope you can track it down, I will install the latest version of git
>  later on today to
>  confirm the behaviour is still happening.
I just confirmed behaviour is still the same in 1.5.5
Geoff.
Show 18 quoted lines
>
>  Thanks,
>  Geoff Russell
>
>  >
>  >  -Peff
>
>
> >
>
>
>
>  --
>  6 Fifth Ave,
>  St Morris, S.A. 5068
>  Australia
>  Ph: 041 8805 184 / 08 8332 5069
>
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069
Geoff Russell· May 1, 2008, 00:15 UTC · re: Geoff Russell · lore

Re: reflog/show question

N.B. This problem has vanished -- which means its probably something I messed up. I haven't worked out what yet, but I will. Apologies for any time wasted.

Cheers, Geoff.

On Wed, Apr 30, 2008 at 9:56 AM, Geoff Russell <geoffrey.russell@gmail.com> wrote:

Show 76 quoted lines
>
> On Wed, Apr 30, 2008 at 9:42 AM, Geoff Russell
>  <geoffrey.russell@gmail.com> wrote:
>  >
>  > On Wed, Apr 30, 2008 at 8:37 AM, Jeff King <peff@peff.net> wrote:
>  >  > On Wed, Apr 30, 2008 at 07:36:23AM +0930, Geoff Russell wrote:
>  >  >
>  >  >  > > Hmm. Are you sure that the commit you got from HEAD@{"3 minutes ago"}
>  >  >  > >  actually _has_ the file data/node/node.data? If it doesn't, then you get
>  >  >  >
>  >  >
>  >  > > Later today (touch wood) I'll prepare as small a test case as
>  >  >  > possible, then send
>  >  >  > a tar.gz of the .git directory. Okay?
>  >  >
>  >  >  That would be great, thanks.
>  >
>  >  Attached is tar.gz of working directory (.) - so unpack in a new directory.
>  >
>  >        git show HEAD@{"N seconds ago"}:data/node/.gitignore
>  >
>  >  works fine for values of N back to creationof file
>  >
>  >  But:
>  >
>  >        git show HEAD@{"N seconds ago"}:data/node/node.newds1
>  >
>  >  doesn't work for any values of N.
>  >
>  >  During my attempts to create this example, I managed created a
>  >  directory which where
>  >  the show command failed for both files, but when I changed the commit
>  >  message, the
>  >  show worked for .gitignore but not the node file. Hence my suspicion
>  >  of that the slashes
>  >  in the path are being interpreted as requesting a commit message match ...?
>  >
>  >  I hope you can track it down, I will install the latest version of git
>  >  later on today to
>  >  confirm the behaviour is still happening.
>
>  I just confirmed behaviour is still the same in 1.5.5
>
>  Geoff.
>
>
>
>
>
>  >
>  >  Thanks,
>  >  Geoff Russell
>  >
>  >  >
>  >  >  -Peff
>  >
>  >
>  > >
>  >
>  >
>  >
>  >  --
>  >  6 Fifth Ave,
>  >  St Morris, S.A. 5068
>  >  Australia
>  >  Ph: 041 8805 184 / 08 8332 5069
>  >
>
>
>
>  --
>  6 Fifth Ave,
>  St Morris, S.A. 5068
>  Australia
>  Ph: 041 8805 184 / 08 8332 5069
>
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069
Jeff King· May 1, 2008, 13:53 UTC · re: Geoff Russell · lore

Re: reflog/show question

On Thu, May 01, 2008 at 09:45:40AM +0930, Geoff Russell wrote:
> N.B. This problem has vanished -- which means its probably something I
> messed up. I haven't worked out what yet, but I will.  Apologies for
> any time wasted.

Vanished randomly, or after you upgraded to the latest master? Did you miss the "fix reflog approxidate parsing bug" patch I posted?

-Peff
Geoff Russell· May 2, 2008, 02:21 UTC · re: Jeff King · lore

Re: reflog/show question

On 5/1/08, Jeff King <peff@peff.net> wrote:
Show 9 quoted lines
> On Thu, May 01, 2008 at 09:45:40AM +0930, Geoff Russell wrote:
>
>  > N.B. This problem has vanished -- which means its probably something I
>  > messed up. I haven't worked out what yet, but I will.  Apologies for
>  > any time wasted.
>
>
> Vanished randomly, or after you upgraded to the latest master? Did you
>  miss the "fix reflog approxidate parsing bug" patch I posted?

I did a "git pull origin" and used both 1.5.5.1 and my original 1.5.4-rc4 and couldn't reproduce the problem. I have just looked at the patch and it certainly sounds like it is attacking the problem that I was seeing, but it shouldn't have affected the 1.5.4-rc4 code.

Thanks Geoff.

>
>  -Peff
>
-- 
6 Fifth Ave,
St Morris, S.A. 5068
Australia
Ph: 041 8805 184 / 08 8332 5069

← back to recent threads