gerrit and merge process: "Submitted, Merge Pending" state

classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
Hello Martin, or other gerrit expert,

I don't know if gerrit is broken or if I do not know how to use it :-)

Example with https://www.opensc-project.org/codereview/#change,6
The status is "Submitted, Merge Pending". And has not changed since
Feb 19 (one month ago).

What is the next step?
So I have to do something manually?

This patch is the first one in a (long) serie.

Thanks

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Douglas E. Engert


On 3/13/2012 5:17 AM, Ludovic Rousseau wrote:

> Hello Martin, or other gerrit expert,
>
> I don't know if gerrit is broken or if I do not know how to use it :-)
>
> Example with https://www.opensc-project.org/codereview/#change,6
> The status is "Submitted, Merge Pending". And has not changed since
> Feb 19 (one month ago).
>
> What is the next step?
> So I have to do something manually?
>
> This patch is the first one in a (long) serie.


I am no Gerrit or Git expert either, but from:

> http://source.android.com/source/life-of-a-patch.html

Googling for:  gerrit Submitted, Merge Pending

shows some articles, on what this message could mean.

It could be a bug:
http://code.google.com/p/gerrit/issues/detail?id=600

> Thanks
>

--

  Douglas E. Engert  <[hidden email]>
  Argonne National Laboratory
  9700 South Cass Avenue
  Argonne, Illinois  60439
  (630) 252-5444
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Peter Stuge-4
In reply to this post by Ludovic Rousseau
Hi,

Ludovic Rousseau wrote:
> I don't know if gerrit is broken or if I do not know how to use it :-)

I would say that gerrit has some problem.


> Example with https://www.opensc-project.org/codereview/#change,6
> The status is "Submitted, Merge Pending". And has not changed since
> Feb 19 (one month ago).
>
> What is the next step?

There should be no next step, you've done all that is needed, but for
some reason gerrit has gotten stuck. It might be differences in
gerrit configuration from when those changes were first added to
gerrit to present day. I'm not sure.


> So I have to do something manually?
> This patch is the first one in a (long) serie.

Unclear how to kick it loose. I made an attempt to kick change 1
loose. Since gerrit has complained that it must be a fast-forward on
top of staging I made it so, and Jenkins built without errors, but
at this point it needs to be approved and submitted again, since I
have uploaded a new patch set. Let's start there? Please have a look
and give +2 and submit if you still like what you see. (Patch is
unchanged.)

The detailed steps I did are as follows:

cd /tmp
git clone https://www.opensc-project.org/codereview/p/OpenSC
cd OpenSC
git config remote.origin.push HEAD:refs/for/staging
scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
git checkout -b staging origin/staging
git fetch https://www.opensc-project.org/codereview/p/OpenSC \
  refs/changes/01/1/1 && git cherry-pick -e FETCH_HEAD
# IMPORTANT: Manually add Change-Id: I3a8519eda2704eceb2d27bfbeaca44c6da7d51b2
# at the bottom of the commit message.
git push


//Peter
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
Le 13 mars 2012 18:15, Peter Stuge <[hidden email]> a écrit :

> Hi,
>
> Ludovic Rousseau wrote:
>> I don't know if gerrit is broken or if I do not know how to use it :-)
>
> I would say that gerrit has some problem.
>
>
>> Example with https://www.opensc-project.org/codereview/#change,6
>> The status is "Submitted, Merge Pending". And has not changed since
>> Feb 19 (one month ago).
>>
>> What is the next step?
>
> There should be no next step, you've done all that is needed, but for
> some reason gerrit has gotten stuck. It might be differences in
> gerrit configuration from when those changes were first added to
> gerrit to present day. I'm not sure.
>
>
>> So I have to do something manually?
>> This patch is the first one in a (long) serie.
>
> Unclear how to kick it loose. I made an attempt to kick change 1
> loose. Since gerrit has complained that it must be a fast-forward on
> top of staging I made it so, and Jenkins built without errors, but
> at this point it needs to be approved and submitted again, since I
> have uploaded a new patch set. Let's start there? Please have a look
> and give +2 and submit if you still like what you see. (Patch is
> unchanged.)

Done.
The status is now "Merged" and the change is available in git at
https://www.opensc-project.org/codereview/p/OpenSC but not yet on
git://github.com/OpenSC/OpenSC.git

I note a bug/typo in the patch for
https://www.opensc-project.org/codereview/#patch,unified,1,2,src/libopensc/internal.h
In the Doxygen comment it should be "reader" instead of "reder"

> The detailed steps I did are as follows:
>
> cd /tmp
> git clone https://www.opensc-project.org/codereview/p/OpenSC
> cd OpenSC
> git config remote.origin.push HEAD:refs/for/staging
> scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/

Failed for me:
$ scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
Host key fingerprint is ab:d9:2d:c0:2f:4c:4e:bd:10:03:bd:d2:ef:2f:4f:61
+--[ RSA 1024]----+
|     .           |
|    . .          |
|     o .         |
|    . =          |
|     o =S E      |
|      * oo .     |
|     = =...      |
|      ++*o       |
|      o..=+      |
+-----------------+

Permission denied (publickey).


I added my SSH public key on my gerrit account but the access is still denied.

> git checkout -b staging origin/staging
> git fetch https://www.opensc-project.org/codereview/p/OpenSC \
>  refs/changes/01/1/1 && git cherry-pick -e FETCH_HEAD
> # IMPORTANT: Manually add Change-Id: I3a8519eda2704eceb2d27bfbeaca44c6da7d51b2
> # at the bottom of the commit message.
> git push

Bye

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Peter Stuge-4
In reply to this post by Peter Stuge-4
Peter Stuge wrote:
> I made an attempt to kick change 1 loose.

Ok, so that worked. It would work fine to repeat this for each
change, even if it is a bit labour intensive at least now, to clear
the backlog. I've done it also for change 2 now.

As you may recall, approving and submitting the change can be done
also via ssh:

ssh -P 8882 www.opensc-project.org gerrit review $commithash \
  --code-review +2 -s

I really like this interface to gerrit when patches need no comment
but are good to go as-is.

The way our Gerrit has been configured it enforces linear submission
of commits to the repository, ie. everything must be submitted to the
git repo in the same order changes were pushed to gerrit by
contributors.

This is in itself not a bad thing since it forces contributors to pay
attention to changes in the codebase and what commits goes into the
repository, but it does slightly raise the bar for less experienced
git users. It's not really difficult, but it's one more thing to keep
track of; make sure that your commit has the correct parent before
you push.

From practical experience with gerrit in several projects I tend to
prefer the cherry-pick strategy when submitting changes. This means
that stuff can be included into the git repository in a different
order than was pushed to gerrit. It also means that humans need to
pay more attention to not submitting changes in the wrong order when
they are interdependent.

The current config makes it impossible to do something wrong, but can
in some cases create extra work for rebase and review. The
cherry-pick merge strategy makes it very easy to do something wrong,
but can save extra work with rebasing and reviewing+submitting of
updated patch sets.

The current config has strong arguments, even if it brings slightly
more inconvenience. I actually favor not changing the config, even if
we will have to rebase each and every change.


//Peter
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Peter Stuge-4
In reply to this post by Ludovic Rousseau
Ludovic Rousseau wrote:
> > I made an attempt to kick change 1 loose.
>
> Done.
> The status is now "Merged" and the change is available in git at
> https://www.opensc-project.org/codereview/p/OpenSC but not yet on
> git://github.com/OpenSC/OpenSC.git

I guess github is synced only periodically.


> I note a bug/typo in the patch for
> https://www.opensc-project.org/codereview/#patch,unified,1,2,src/libopensc/internal.h
> In the Doxygen comment it should be "reader" instead of "reder"

Ouch. Then please don't give +2 but instead -2 and don't submit but
give review in an inline comment. I would then have fixed it and
pushed an updated patch.


> > The detailed steps I did are as follows:
> >
> > cd /tmp
> > git clone https://www.opensc-project.org/codereview/p/OpenSC
> > cd OpenSC
> > git config remote.origin.push HEAD:refs/for/staging
> > scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
>
> Failed for me:
> $ scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
> Host key fingerprint is ab:d9:2d:c0:2f:4c:4e:bd:10:03:bd:d2:ef:2f:4f:61
> +--[ RSA 1024]----+
> |     .           |
> |    . .          |
> |     o .         |
> |    . =          |
> |     o =S E      |
> |      * oo .     |
> |     = =...      |
> |      ++*o       |
> |      o..=+      |
> +-----------------+
>
> Permission denied (publickey).
>
>
> I added my SSH public key on my gerrit account but the access is
> still denied.

So the username between local host and gerrit doesn't match. Check
https://www.opensc-project.org/codereview/#settings

And possibly add:
Host opensc-gerrit
  Hostname www.opensc-project.org
  Port 8882
  User yourusernamefromgerrit

Then you can instead use:

scp -p opensc-gerrit:hooks/commit-msg .git/hooks/

(And ssh opensc-gerrit gerrit review ... for setting code-review and
doing submit.)


//Peter
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Peter Stuge-4
In reply to this post by Peter Stuge-4
Peter Stuge wrote:
> The current config has strong arguments, even if it brings slightly
> more inconvenience. I actually favor not changing the config, even if
> we will have to rebase each and every change.

Thinking again about this, there's another possible problematic
situation which I don't like as much..

If there's a long list of changes which haven't been reviewed yet,
and review starts with some older change, and review results in that
older change being updated, as I've done for changes 1 and 2 now,
then *every* change after that one has to be updated, and they have
to be updated in the order that they will be submitted.

This is a bit awkward..


//Peter
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
In reply to this post by Peter Stuge-4
Le 13 mars 2012 19:04, Peter Stuge <[hidden email]> a écrit :
> Ludovic Rousseau wrote:
>> I added my SSH public key on my gerrit account but the access is
>> still denied.
>
> So the username between local host and gerrit doesn't match. Check
> https://www.opensc-project.org/codereview/#settings

My username was not setup at gerrit.
It is working now.

Thanks

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
In reply to this post by Peter Stuge-4
Le 13 mars 2012 18:59, Peter Stuge <[hidden email]> a écrit :
> Peter Stuge wrote:
>> I made an attempt to kick change 1 loose.
>
> Ok, so that worked. It would work fine to repeat this for each
> change, even if it is a bit labour intensive at least now, to clear
> the backlog. I've done it also for change 2 now.

Change 2 now merged.

I also tried with change 3
https://www.opensc-project.org/codereview/#change,3 but I get the
error:
"Gerrit Code Review 8:45 PM

Change cannot be merged due to unsatisfiable dependencies.

The following dependency errors were found:

    Depends on patch set 1 of I8b483369, however the current patch set is 2.
    Depends on commit 3a8519eda2704eceb2d27bfbeaca44c6da7d51b2 which
has no change associated with it.

Please rebase the change and upload a replacement commit."

Do we now have to rebase all the patches?

Bye

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Viktor Tarasov-3
In reply to this post by Peter Stuge-4


On Tue, Mar 13, 2012 at 6:59 PM, Peter Stuge <[hidden email]> wrote:
Peter Stuge wrote:
> I made an attempt to kick change 1 loose.

Ok, so that worked. It would work fine to repeat this for each
change, even if it is a bit labour intensive at least now, to clear
the backlog. I've done it also for change 2 now.

As you may recall, approving and submitting the change can be done
also via ssh:

ssh -P 8882 www.opensc-project.org gerrit review $commithash \
 --code-review +2 -s

I really like this interface to gerrit when patches need no comment
but are good to go as-is.

The way our Gerrit has been configured it enforces linear submission
of commits to the repository, ie. everything must be submitted to the
git repo in the same order changes were pushed to gerrit by
contributors.

This is in itself not a bad thing since it forces contributors to pay
attention to changes in the codebase and what commits goes into the
repository, but it does slightly raise the bar for less experienced
git users. It's not really difficult, but it's one more thing to keep
track of; make sure that your commit has the correct parent before
you push.

From practical experience with gerrit in several projects I tend to
prefer the cherry-pick strategy when submitting changes. This means
that stuff can be included into the git repository in a different
order than was pushed to gerrit. It also means that humans need to
pay more attention to not submitting changes in the wrong order when
they are interdependent.

The current config makes it impossible to do something wrong, but can
in some cases create extra work for rebase and review. The
cherry-pick merge strategy makes it very easy to do something wrong,
but can save extra work with rebasing and reviewing+submitting of
updated patch sets.

The current config has strong arguments, even if it brings slightly
more inconvenience. I actually favor not changing the config, even if
we will have to rebase each and every change.


Commit 51630a844e8e95e7108cb1966c5f3e21b93a463b is the last common commit for OpenSC/OpenSC.git(staging) and gerrit's repo.
(By the way, this commit where not submitted to OpenSC.git by gerrit -- there is no Change-Id in comments)

Two last commits merged into the gerrit's repo are not replicated into OpenSC/OpenSC.git.
Something wrong with replication configuration?
GitHub refuses not ff merges?
Have you an access to the gerrit's logs?

I would propose to start from zero:
- merge the OpenSC-SM branch into OpenSC-staging (or simply switch to -- recently the OpenSC-staging was merged into OpenSC-SM).
- pick from the current gerrit's changesets the useful proposals and apply them to this branch.
- re-install the Gerit's OpenSC project with the updated github repository.
- limit direct commits to github's OpenSC-staging (or replicate these changes to the gerrit's repo on the regular base)
- update the list of the Jenkins admins, or install an alternative Jenkins (like this one https://opensc.fr/jenkins/, https://opensc.fr/gerrit/ -- still under construction),  dedicated to the OpenSC-staging and OpenSC-master. It's needed to implement the glaring lack of an actual jenkins -- the build of OpenSC linux packages.
 

//Peter

Kind wishes,
Viktor.
 
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel


_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Douglas E. Engert
Good to see Ludovic and Peter making progress, Thanks!"

Rather the stating from zero, or taking a very large branch with many little patches,
would it be better to have the authors of these patches combine them into one or
a hand full  of larger patches? For example my ECDH was 4 separate patches, but I have
combined it ito one patch.  (But the ECDH is also in the SM branch so if it get in either
way that is OK too.)

On 3/14/2012 3:59 AM, Viktor Tarasov wrote:

>
>
> On Tue, Mar 13, 2012 at 6:59 PM, Peter Stuge <[hidden email] <mailto:[hidden email]>> wrote:
>
>     Peter Stuge wrote:
>      > I made an attempt to kick change 1 loose.
>
>     Ok, so that worked. It would work fine to repeat this for each
>     change, even if it is a bit labour intensive at least now, to clear
>     the backlog. I've done it also for change 2 now.
>
>     As you may recall, approving and submitting the change can be done
>     also via ssh:
>
>     ssh -P 8882 www.opensc-project.org <http://www.opensc-project.org> gerrit review $commithash \
>       --code-review +2 -s
>
>     I really like this interface to gerrit when patches need no comment
>     but are good to go as-is.
>
>     The way our Gerrit has been configured it enforces linear submission
>     of commits to the repository, ie. everything must be submitted to the
>     git repo in the same order changes were pushed to gerrit by
>     contributors.
>
>     This is in itself not a bad thing since it forces contributors to pay
>     attention to changes in the codebase and what commits goes into the
>     repository, but it does slightly raise the bar for less experienced
>     git users. It's not really difficult, but it's one more thing to keep
>     track of; make sure that your commit has the correct parent before
>     you push.
>
>      >From practical experience with gerrit in several projects I tend to
>     prefer the cherry-pick strategy when submitting changes. This means
>     that stuff can be included into the git repository in a different
>     order than was pushed to gerrit. It also means that humans need to
>     pay more attention to not submitting changes in the wrong order when
>     they are interdependent.
>
>     The current config makes it impossible to do something wrong, but can
>     in some cases create extra work for rebase and review. The
>     cherry-pick merge strategy makes it very easy to do something wrong,
>     but can save extra work with rebasing and reviewing+submitting of
>     updated patch sets.
>
>     The current config has strong arguments, even if it brings slightly
>     more inconvenience. I actually favor not changing the config, even if
>     we will have to rebase each and every change.
>
>
>
> Commit 51630a844e8e95e7108cb1966c5f3e21b93a463b is the last common commit for OpenSC/OpenSC.git(staging) and gerrit's repo.
> (By the way, this commit where not submitted to OpenSC.git by gerrit -- there is no Change-Id in comments)
>
> Two last commits merged into the gerrit's repo are not replicated into OpenSC/OpenSC.git.
> Something wrong with replication configuration?
> GitHub refuses not ff merges?
> Have you an access to the gerrit's logs?
>
> I would propose to start from zero:
> - merge the OpenSC-SM branch into OpenSC-staging (or simply switch to -- recently the OpenSC-staging was merged into OpenSC-SM).
> - pick from the current gerrit's changesets the useful proposals and apply them to this branch.
> - re-install the Gerit's OpenSC project with the updated github repository.
> - limit direct commits to github's OpenSC-staging (or replicate these changes to the gerrit's repo on the regular base)
> - update the list of the Jenkins admins, or install an alternative Jenkins (like this one https://opensc.fr/jenkins/, https://opensc.fr/gerrit/ <https://opensc.fr/jenkins/> -- still under
> construction),  dedicated to the OpenSC-staging and OpenSC-master. It's needed to implement the glaring lack of an actual jenkins -- the build of OpenSC linux packages.
>
>
>     //Peter
>
>
> Kind wishes,
> Viktor.
>
>     _______________________________________________
>     opensc-devel mailing list
>     [hidden email] <mailto:[hidden email]>
>     http://www.opensc-project.org/mailman/listinfo/opensc-devel
>
>
>
>
> _______________________________________________
> opensc-devel mailing list
> [hidden email]
> http://www.opensc-project.org/mailman/listinfo/opensc-devel

--

  Douglas E. Engert  <[hidden email]>
  Argonne National Laboratory
  9700 South Cass Avenue
  Argonne, Illinois  60439
  (630) 252-5444
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
In reply to this post by Viktor Tarasov-3
Le 14 mars 2012 09:59, Viktor Tarasov <[hidden email]> a écrit :

> Commit 51630a844e8e95e7108cb1966c5f3e21b93a463b is the last common commit
> for OpenSC/OpenSC.git(staging) and gerrit's repo.
> (By the way, this commit where not submitted to OpenSC.git by gerrit --
> there is no Change-Id in comments)
>
> Two last commits merged into the gerrit's repo are not replicated into
> OpenSC/OpenSC.git.
> Something wrong with replication configuration?
> GitHub refuses not ff merges?
> Have you an access to the gerrit's logs?

No, I do not have access to the gerrit's logs.

I also think something is broken.
Martin, can you have a look when you have some free time?

Thanks

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Jean-Michel Pouré - GOOZE
In reply to this post by Douglas E. Engert
Le mercredi 14 mars 2012 à 10:36 -0500, Douglas E. Engert a écrit :
> Rather the stating from zero, or taking a very large branch with many
> little patches,
> would it be better to have the authors of these patches combine them
> into one or
> a hand full  of larger patches? For example my ECDH was 4 separate
> patches, but I have
> combined it ito one patch.  (But the ECDH is also in the SM branch so
> if it get in either
> way that is OK too.)

Thank you all for your work.

Viktor explained that OpenSC-staging was merged into OpenSC-SM.
Switching to OpenSC-SM as the lead branch would fix all issues.

Kind regards,
--
                  Jean-Michel Pouré - Gooze - http://www.gooze.eu

_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel

smime.p7s (8K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Peter Stuge-4
In reply to this post by Ludovic Rousseau
Ludovic Rousseau wrote:
> Change 2 now merged.

Ok!


> I also tried with change 3
> https://www.opensc-project.org/codereview/#change,3 but I get the
> error:
> "Gerrit Code Review 8:45 PM
>
> Change cannot be merged due to unsatisfiable dependencies.
>
> The following dependency errors were found:
>
>     Depends on patch set 1 of I8b483369, however the current patch set is 2.
>     Depends on commit 3a8519eda2704eceb2d27bfbeaca44c6da7d51b2 which
> has no change associated with it.
>
> Please rebase the change and upload a replacement commit."
>
> Do we now have to rebase all the patches?

With the current gerrit configuration yes, unfortunately this is the
case. Gerrit can also be configured differently, but I'm not sure if
we want to.. In other projects where I use gerrit we do not have this
rather strict policy, but it does also force contributors to pay
attention to what they are doing, and if they rebase they should also
look at the result of that, before pushing to gerrit again.

In practise I don't know if it works; I didn't review the rebase of
change 2, only the one for change 1. And while rebasing is easy in
git I think it's bad that contributors are forced by gerrit to do it
so much.

On the other hand, changing gerrit to use submittype cherry-pick
makes all dependencies merely advisory, ie. humans using gerrit must
pay close attention so that nothing gets submitted out of order, or
changes will have to be rebased anyway.

What to choose depends on how the project will work with commits..

If we will generally have only very few very recent changes in gerrit
then the current configuration can work pretty well, except that it
must be clear already before pushing which commits will be submitted
in gerrit before the one(s) being pushed.

If we suspect that we will have some changes in gerrit which lay
around for a long time without getting attention from either
reviewers or contributors, and it was assumed by someone that those
commits would be submitted first, then the someone will have to
rebase, and everyone assuming that someone's change would go in will
have to rebase in turn, and so on.. Not so nice.


//Peter
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
In reply to this post by Peter Stuge-4
Le 13 mars 2012 18:15, Peter Stuge <[hidden email]> a écrit :

> Hi,
>
> Ludovic Rousseau wrote:
>> I don't know if gerrit is broken or if I do not know how to use it :-)
>
> I would say that gerrit has some problem.
>
>
>> Example with https://www.opensc-project.org/codereview/#change,6
>> The status is "Submitted, Merge Pending". And has not changed since
>> Feb 19 (one month ago).
>>
>> What is the next step?
>
> There should be no next step, you've done all that is needed, but for
> some reason gerrit has gotten stuck. It might be differences in
> gerrit configuration from when those changes were first added to
> gerrit to present day. I'm not sure.
>
>
>> So I have to do something manually?
>> This patch is the first one in a (long) serie.
>
> Unclear how to kick it loose. I made an attempt to kick change 1
> loose. Since gerrit has complained that it must be a fast-forward on
> top of staging I made it so, and Jenkins built without errors, but
> at this point it needs to be approved and submitted again, since I
> have uploaded a new patch set. Let's start there? Please have a look
> and give +2 and submit if you still like what you see. (Patch is
> unchanged.)
>
> The detailed steps I did are as follows:
>
> cd /tmp
> git clone https://www.opensc-project.org/codereview/p/OpenSC
> cd OpenSC
> git config remote.origin.push HEAD:refs/for/staging
> scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
> git checkout -b staging origin/staging
> git fetch https://www.opensc-project.org/codereview/p/OpenSC \
>  refs/changes/01/1/1 && git cherry-pick -e FETCH_HEAD
> # IMPORTANT: Manually add Change-Id: I3a8519eda2704eceb2d27bfbeaca44c6da7d51b2
> # at the bottom of the commit message.
> git push

I tried to push a rebased version of change 3.
https://www.opensc-project.org/codereview/#change,3

Everything worked fine except the last command:

$ git push
error: The requested URL returned error: 403 while accessing
https://www.opensc-project.org/codereview/p/OpenSC/info/refs

fatal: HTTP request failed


$ cat .git/config
[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true
        ignorecase = true
[remote "origin"]
        fetch = +refs/heads/*:refs/remotes/origin/*
        url = https://www.opensc-project.org/codereview/p/OpenSC
        push = HEAD:refs/for/staging
[branch "master"]
        remote = origin
        merge = refs/heads/master
[branch "staging"]
        remote = origin
        merge = refs/heads/staging



The page https://www.opensc-project.org/codereview/p/OpenSC/info/refs gives me:
HTTP ERROR: 403

Problem accessing /codereview/p/OpenSC/info/refs. Reason:

    Forbidden

Powered by Jetty://


A missing configuration on my side?

Thanks

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel
Reply | Threaded
Open this post in threaded view
|

Re: gerrit and merge process: "Submitted, Merge Pending" state

Ludovic Rousseau
Le 16 mars 2012 21:58, Ludovic Rousseau <[hidden email]> a écrit :

> Le 13 mars 2012 18:15, Peter Stuge <[hidden email]> a écrit :
>> Hi,
>>
>> Ludovic Rousseau wrote:
>>> I don't know if gerrit is broken or if I do not know how to use it :-)
>>
>> I would say that gerrit has some problem.
>>
>>
>>> Example with https://www.opensc-project.org/codereview/#change,6
>>> The status is "Submitted, Merge Pending". And has not changed since
>>> Feb 19 (one month ago).
>>>
>>> What is the next step?
>>
>> There should be no next step, you've done all that is needed, but for
>> some reason gerrit has gotten stuck. It might be differences in
>> gerrit configuration from when those changes were first added to
>> gerrit to present day. I'm not sure.
>>
>>
>>> So I have to do something manually?
>>> This patch is the first one in a (long) serie.
>>
>> Unclear how to kick it loose. I made an attempt to kick change 1
>> loose. Since gerrit has complained that it must be a fast-forward on
>> top of staging I made it so, and Jenkins built without errors, but
>> at this point it needs to be approved and submitted again, since I
>> have uploaded a new patch set. Let's start there? Please have a look
>> and give +2 and submit if you still like what you see. (Patch is
>> unchanged.)
>>
>> The detailed steps I did are as follows:
>>
>> cd /tmp
>> git clone https://www.opensc-project.org/codereview/p/OpenSC
>> cd OpenSC
>> git config remote.origin.push HEAD:refs/for/staging
>> scp -p -P 8882 www.opensc-project.org:hooks/commit-msg .git/hooks/
>> git checkout -b staging origin/staging
>> git fetch https://www.opensc-project.org/codereview/p/OpenSC \
>>  refs/changes/01/1/1 && git cherry-pick -e FETCH_HEAD
>> # IMPORTANT: Manually add Change-Id: I3a8519eda2704eceb2d27bfbeaca44c6da7d51b2
>> # at the bottom of the commit message.
>> git push
>
> I tried to push a rebased version of change 3.
> https://www.opensc-project.org/codereview/#change,3
>
> Everything worked fine except the last command:
>
> $ git push
> error: The requested URL returned error: 403 while accessing
> https://www.opensc-project.org/codereview/p/OpenSC/info/refs
>
> fatal: HTTP request failed
>
>
> $ cat .git/config
> [core]
>        repositoryformatversion = 0
>        filemode = true
>        bare = false
>        logallrefupdates = true
>        ignorecase = true
> [remote "origin"]
>        fetch = +refs/heads/*:refs/remotes/origin/*
>        url = https://www.opensc-project.org/codereview/p/OpenSC
>        push = HEAD:refs/for/staging
> [branch "master"]
>        remote = origin
>        merge = refs/heads/master
> [branch "staging"]
>        remote = origin
>        merge = refs/heads/staging
>
>
>
> The page https://www.opensc-project.org/codereview/p/OpenSC/info/refs gives me:
> HTTP ERROR: 403
>
> Problem accessing /codereview/p/OpenSC/info/refs. Reason:
>
>    Forbidden
>
> Powered by Jetty://
>
>
> A missing configuration on my side?

Problem solved using the commands documented at
https://www.opensc-project.org/opensc/wiki/SourceCode

I also updated the wiki with the valid "git push" command.

Bye

--
 Dr. Ludovic Rousseau
_______________________________________________
opensc-devel mailing list
[hidden email]
http://www.opensc-project.org/mailman/listinfo/opensc-devel