Thread

  1. Git out of sync vs. CVS

    Peter Eisentraut <peter_e@gmx.net> — 2010-01-17T19:05:43Z

    Maybe I'm hallucinating and someone could check this in their
    environment, but it appears to me that the Git repository is missing
    parts of two non-recent commits.  See attached patch.
    
  2. Re: Git out of sync vs. CVS

    Magnus Hagander <magnus@hagander.net> — 2010-01-17T19:50:23Z

    2010/1/17 Peter Eisentraut <peter_e@gmx.net>:
    > Maybe I'm hallucinating and someone could check this in their
    > environment, but it appears to me that the Git repository is missing
    > parts of two non-recent commits.  See attached patch.
    
    Not having looked at the repo in detail, but I bet this happened
    because the git mirror grabbed it's snapshot in the middle of a cvs
    commit with multiple files. Since cvs doesn't have atomic commits, I
    think that kind of thing can happen. Does that seem possible wrt these
    commits specifically?
    
    I don't really know how to fix that. It's kind of hard to do
    transaction safe replication from a system without transactions ;)
    
    As for fixing it, I guess we can try the
    rewind-to-commit-before-this-and-rerun. That'll break people who have
    branched after, but last time it seemed that most peoples git clients
    would clean that up automatically. Which commits are these exactly?
    
    -- 
     Magnus Hagander
     Me: http://www.hagander.net/
     Work: http://www.redpill-linpro.com/
    
    
  3. Re: Git out of sync vs. CVS

    Peter Eisentraut <peter_e@gmx.net> — 2010-01-17T20:34:12Z

    On sön, 2010-01-17 at 20:50 +0100, Magnus Hagander wrote:
    > As for fixing it, I guess we can try the
    > rewind-to-commit-before-this-and-rerun. That'll break people who have
    > branched after, but last time it seemed that most peoples git clients
    > would clean that up automatically. Which commits are these exactly?
    
    These two belong together:
    
    http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/contrib/start-scripts/freebsd?rev=1.5
    http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/contrib/start-scripts/osx/PostgreSQL?rev=1.4
    
    And this is a separate one:
    
    http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/config/python.m4?rev=1.17
    
    
    
    
  4. Re: Git out of sync vs. CVS

    Magnus Hagander <magnus@hagander.net> — 2010-01-17T20:57:45Z

    2010/1/17 Peter Eisentraut <peter_e@gmx.net>:
    > On sön, 2010-01-17 at 20:50 +0100, Magnus Hagander wrote:
    >> As for fixing it, I guess we can try the
    >> rewind-to-commit-before-this-and-rerun. That'll break people who have
    >> branched after, but last time it seemed that most peoples git clients
    >> would clean that up automatically. Which commits are these exactly?
    >
    > These two belong together:
    >
    > http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/contrib/start-scripts/freebsd?rev=1.5
    > http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/contrib/start-scripts/osx/PostgreSQL?rev=1.4
    >
    > And this is a separate one:
    >
    > http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/config/python.m4?rev=1.17
    
    Well, if we're going to roll something back in git, it's the git
    comits that are interesting... To figure out how far back in time to
    go.
    
    -- 
     Magnus Hagander
     Me: http://www.hagander.net/
     Work: http://www.redpill-linpro.com/
    
    
  5. Re: Git out of sync vs. CVS

    Tom Lane <tgl@sss.pgh.pa.us> — 2010-01-17T21:42:39Z

    Magnus Hagander <magnus@hagander.net> writes:
    > 2010/1/17 Peter Eisentraut <peter_e@gmx.net>:
    >> Maybe I'm hallucinating and someone could check this in their
    >> environment, but it appears to me that the Git repository is missing
    >> parts of two non-recent commits. See attached patch.
    
    > Not having looked at the repo in detail, but I bet this happened
    > because the git mirror grabbed it's snapshot in the middle of a cvs
    > commit with multiple files. Since cvs doesn't have atomic commits, I
    > think that kind of thing can happen.
    
    That would explain a single CVS commit appearing as two separate commits
    in the git history; but it hardly seems like an acceptable excuse for
    missing changes altogether, which is what I think Peter said he saw.
    
    			regards, tom lane
    
    
  6. Re: Git out of sync vs. CVS

    Magnus Hagander <magnus@hagander.net> — 2010-01-17T21:53:47Z

    2010/1/17 Tom Lane <tgl@sss.pgh.pa.us>:
    > Magnus Hagander <magnus@hagander.net> writes:
    >> 2010/1/17 Peter Eisentraut <peter_e@gmx.net>:
    >>> Maybe I'm hallucinating and someone could check this in their
    >>> environment, but it appears to me that the Git repository is missing
    >>> parts of two non-recent commits.  See attached patch.
    >
    >> Not having looked at the repo in detail, but I bet this happened
    >> because the git mirror grabbed it's snapshot in the middle of a cvs
    >> commit with multiple files. Since cvs doesn't have atomic commits, I
    >> think that kind of thing can happen.
    >
    > That would explain a single CVS commit appearing as two separate commits
    > in the git history; but it hardly seems like an acceptable excuse for
    > missing changes altogether, which is what I think Peter said he saw.
    
    It's likely the combination of that, and the cvs to git sync script
    not considering that this can happen. So when it does the second pass
    (once it's all been synced) it detects it as a single commit, and
    doesn't re-import it.
    
    We've seen this happen before.
    
    
    -- 
     Magnus Hagander
     Me: http://www.hagander.net/
     Work: http://www.redpill-linpro.com/