"Push Merge Commit" gave,but still "error:"you are not allowed to upload merges""

3,828 views
Skip to first unread message

Chunlin Zhang

unread,
Oct 19, 2011, 4:18:39 AM10/19/11
to Repo and Gerrit Discussion
cmd:
'''
potato@huang:~/android/a66/a66_evb/alps$ git push le avatar69wg_evb
Counting objects: 4, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (2/2), 306 bytes, done.
Total 2 (delta 1), reused 0 (delta 0)
remote: Resolving deltas: 0% (0/1)
To sma:/a66.git
! [remote rejected] avatar69wg_evb -> avatar69wg_evb (you are not
allowed to upload merges)
error: failed to push some refs to 'sma:/a66.git'
'''
gitk see the attatchment.

Is'nt this permission provided to this situation ?

2011-10-19_153711.jpg

Edwin Kempin

unread,
Oct 19, 2011, 4:31:32 AM10/19/11
to Chunlin Zhang, Repo and Gerrit Discussion
If you are running Gerrit 2.2.1 then it's probably the bug described
in issue 1072. [1]

[1] http://code.google.com/p/gerrit/issues/detail?id=1072

2011/10/19 Chunlin Zhang <zhangc...@gmail.com>:

> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> More info at http://groups.google.com/group/repo-discuss?hl=en
>

Chunlin Zhang

unread,
Oct 19, 2011, 4:51:08 AM10/19/11
to Edwin Kempin, Repo and Gerrit Discussion
On Wed, Oct 19, 2011 at 4:31 PM, Edwin Kempin <edwin....@gmail.com> wrote:
> If you are running Gerrit 2.2.1 then it's probably the bug described
> in issue 1072. [1]

Yes,I am just upgrade to gerrit 2.2.1.
But this issue is ''' "Push Merge Commit" permission not working on
refs/heads/* ''',but after I give Push/Push Merge Commit permission
with "refs/heads/avatar69wg_evb",there still come with same error "you

Chunlin Zhang

unread,
Oct 19, 2011, 5:05:38 AM10/19/11
to Alex Blewitt, Repo and Gerrit Discussion
On Wed, Oct 19, 2011 at 4:38 PM, Alex Blewitt <alex.b...@gmail.com> wrote:
> The Merge permission is required for pushing merges, yes. The error
> indicates that the merge permissions are not set, or apply to different refs
> than the one you are trying to push to. If you are pushing to a different
> ref (which isn't under the spec listed in the 'merge permission' branches)
> then you'll get this error.
The use who run the git push have the "Push/Push Merge Commit"
permission to "refs/heads/*",so I think the user do have the
permission.

And Edwin tell me it maybe the Issue 1072,but after I gave the
"Push/Push Merge Commit" permission to "refs/heads/MERGE_FROM_BRANCH"
and "refs/heads/MERGE_TO_BRANCH",the git push action still output with
same error.

>
> Alex

>> <2011-10-19_153711.jpg>
>
>

Chunlin Zhang

unread,
Oct 21, 2011, 2:05:48 AM10/21/11
to Repo and Gerrit Discussion
At last I use rebase to work around this problem.

Chunlin Zhang

unread,
Feb 22, 2012, 2:47:57 AM2/22/12
to Edwin Kempin, Repo and Gerrit Discussion
This issue can not be resolved? ( https://code.google.com/p/gerrit/issues/detail?id=1072
)
I can not push merge commit and I need to do it ...

Edwin Kempin

unread,
Feb 22, 2012, 2:54:18 AM2/22/12
to Chunlin Zhang, Repo and Gerrit Discussion
Yes, this issue is still open.

Have you tried the workaround [1] described in comments 4 and 6?

[1] https://code.google.com/p/gerrit/issues/detail?id=1072

2012/2/22 Chunlin Zhang <zhangc...@gmail.com>

Chunlin Zhang

unread,
Feb 22, 2012, 4:02:54 AM2/22/12
to Edwin Kempin, Repo and Gerrit Discussion
I think the workaround is: give the permission of "Push Merge Commit"
to both "refs/for/refs/heads/BRANCH" and "refs/heads/BRACH",and give
the permission of "Push" to "refs/heads/BRACH".
Is it?

Edwin Kempin

unread,
Feb 22, 2012, 6:58:59 AM2/22/12
to Chunlin Zhang, Repo and Gerrit Discussion
2012/2/22 Chunlin Zhang <zhangc...@gmail.com>

I think the workaround is: give the permission of "Push Merge Commit"
to both "refs/for/refs/heads/BRANCH" and "refs/heads/BRACH",and give
I think assigning "Push Merge Commit" just to "refs/for/refs/heads/BRANCH" should be enough
 
the permission of "Push" to "refs/heads/BRACH".
Is it?
yes
 

Shawn Pearce

unread,
Feb 22, 2012, 10:05:15 AM2/22/12
to Edwin Kempin, Chunlin Zhang, Repo and Gerrit Discussion
On Wed, Feb 22, 2012 at 03:58, Edwin Kempin <edwin....@gmail.com> wrote:
> 2012/2/22 Chunlin Zhang <zhangc...@gmail.com>
>>
>> I think the workaround is: give the permission of "Push Merge Commit"
>> to both "refs/for/refs/heads/BRANCH" and "refs/heads/BRACH",and give
>
> I think assigning "Push Merge Commit" just to "refs/for/refs/heads/BRANCH"
> should be enough

With the current bug yes. But when we fix it, you will need to change
it to be on refs/heads/BRANCH. :-)

Reply all
Reply to author
Forward
0 new messages