Error while pushing commits for bug 93240

classic Classic list List threaded Threaded
15 messages Options
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Error while pushing commits for bug 93240

Hi,

I'm unable to figure out why my commits are not being pushed.

 $ git push --set-upstream origin my_93240 
Counting objects: 61, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
Total 11 (delta 8), reused 0 (delta 0)
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)
error: failed to push some refs to 'ssh://logerrit/core'

How do I fix this?

Regards,
Shreyansh
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Samuel Mehrbrodt-2 Samuel Mehrbrodt-2
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Try

./logerrit submit master

Check https://wiki.documentfoundation.org/Development/gerrit for more information.

Samuel

Am 28.08.2015 um 10:58 schrieb Shreyansh Gandhi:
Hi,

I'm unable to figure out why my commits are not being pushed.

 $ git push --set-upstream origin my_93240 
Counting objects: 61, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
Total 11 (delta 8), reused 0 (delta 0)
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: refs: 1, done    
To <a class="moz-txt-link-freetext" href="ssh://logerrit/core">ssh://logerrit/core
 ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)
error: failed to push some refs to '<a class="moz-txt-link-freetext" href="ssh://logerrit/core">ssh://logerrit/core'

How do I fix this?

Regards,
Shreyansh
--
Regards,
Shreyansh Gandhi


_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice


_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

./logerrit submit master
Counting objects: 64, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
Total 11 (delta 8), reused 0 (delta 0)
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (change 9724 closed)
error: failed to push some refs to 'ssh://logerrit/core'


On Fri, Aug 28, 2015 at 2:51 PM Samuel Mehrbrodt <[hidden email]> wrote:
Try

./logerrit submit master

Check https://wiki.documentfoundation.org/Development/gerrit for more information.

Samuel


Am 28.08.2015 um 10:58 schrieb Shreyansh Gandhi:
Hi,

I'm unable to figure out why my commits are not being pushed.

 $ git push --set-upstream origin my_93240 
Counting objects: 61, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
Total 11 (delta 8), reused 0 (delta 0)
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: refs: 1, done    
 ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)
error: failed to push some refs to 'ssh://logerrit/core'

How do I fix this?

Regards,
Shreyansh
--
Regards,
Shreyansh Gandhi


_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

In reply to this post by Samuel Mehrbrodt-2
This is the output of ./logerrit submit master

./logerrit submit master
Counting objects: 64, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
Total 11 (delta 8), reused 0 (delta 0)
remote: Resolving deltas: 100% (8/8)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (change 9724 closed)
error: failed to push some refs to 'ssh://logerrit/core'
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Eike Rathke-2 Eike Rathke-2
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Hi Shreyansh,

On Friday, 2015-08-28 10:07:00 +0000, Shreyansh Gandhi wrote:

>  ! [remote rejected] HEAD -> refs/for/master (change 9724 closed)

You are attempting to push a change to gerrit that has the same
Change-Id as change number 9724 on gerrit, which happens to be a long
closed change, coincidentally authored by you, see
https://gerrit.libreoffice.org/9724/

Apparently you recycled the Change-Id in the commit message of your new
change, or you are accidentally trying to push the same change again.

  Eike

--
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
GPG key "ID" 0x65632D3A - 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Better use 64-bit 0x6A6CD5B765632D3A here is why: https://evil32.com/
Care about Free Software, support the FSFE https://fsfe.org/support/?erack

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

attachment0 (836 bytes) Download Attachment
Eike Rathke-2 Eike Rathke-2
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

In reply to this post by Samuel Mehrbrodt-2
Hi,

On Friday, 2015-08-28 11:21:45 +0200, Samuel Mehrbrodt wrote:

> Try
>
> ./logerrit submit master

Be careful though, ./logerrit pushes every change from your local branch
that is on top of the origin, which may explain why you had the problem
with the closed 9724 change if that commit still lingered on your
branch.

The  git review  plugin command checks and warns if more than one change
is to be pushed, see git review --help for usage.

  Eike

--
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
GPG key "ID" 0x65632D3A - 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Better use 64-bit 0x6A6CD5B765632D3A here is why: https://evil32.com/
Care about Free Software, support the FSFE https://fsfe.org/support/?erack

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

attachment0 (836 bytes) Download Attachment
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh

On Fri, Aug 28, 2015 at 4:43 PM Eike Rathke <[hidden email]> wrote:
Hi,

On Friday, 2015-08-28 11:21:45 +0200, Samuel Mehrbrodt wrote:

> Try
>
> ./logerrit submit master

Be careful though, ./logerrit pushes every change from your local branch
that is on top of the origin, which may explain why you had the problem
with the closed 9724 change if that commit still lingered on your
branch.

The  git review  plugin command checks and warns if more than one change
is to be pushed, see git review --help for usage.

  Eike

--
LibreOffice Calc developer. Number formatter stricken i18n transpositionizer.
GPG key "ID" 0x65632D3A - 2265 D7F3 A7B0 95CC 3918  630B 6A6C D5B7 6563 2D3A
Better use 64-bit 0x6A6CD5B765632D3A here is why: https://evil32.com/
Care about Free Software, support the FSFE https://fsfe.org/support/?erack
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Markus Mohrhard Markus Mohrhard
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Hey,

On Fri, Aug 28, 2015 at 2:10 PM, Shreyansh Gandhi <[hidden email]> wrote:

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh




You are not allowed to push to master. Instead you need to use something like git push origin HEAD:refs/for/master which will push it to the review queue.

Regards,
Markus

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Same result:-

git push origin HEAD:refs/for/master
Counting objects: 63, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)
error: failed to push some refs to 'ssh://logerrit/core'


On Fri, Aug 28, 2015 at 5:41 PM Markus Mohrhard <[hidden email]> wrote:
Hey,


On Fri, Aug 28, 2015 at 2:10 PM, Shreyansh Gandhi <[hidden email]> wrote:

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh




You are not allowed to push to master. Instead you need to use something like git push origin HEAD:refs/for/master which will push it to the review queue.

Regards,
Markus
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Ashod Nakashian-2 Ashod Nakashian-2
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

On Fri, Aug 28, 2015 at 8:15 AM, Shreyansh Gandhi <[hidden email]> wrote:
Same result:-

git push origin HEAD:refs/for/master

Try replacing HEAD with the branch name.

 
Counting objects: 63, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)
error: failed to push some refs to 'ssh://logerrit/core'


On Fri, Aug 28, 2015 at 5:41 PM Markus Mohrhard <[hidden email]> wrote:
Hey,


On Fri, Aug 28, 2015 at 2:10 PM, Shreyansh Gandhi <[hidden email]> wrote:

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh




You are not allowed to push to master. Instead you need to use something like git push origin HEAD:refs/for/master which will push it to the review queue.

Regards,
Markus
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice



_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Markus Mohrhard Markus Mohrhard
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Hey,

On Fri, Aug 28, 2015 at 4:52 PM, Ashod Nakashian <[hidden email]> wrote:
On Fri, Aug 28, 2015 at 8:15 AM, Shreyansh Gandhi <[hidden email]> wrote:
Same result:-

git push origin HEAD:refs/for/master

Try replacing HEAD with the branch name.

No. Please read the error message. (" [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)")

You have somewhere a merge commit. Can you pastebin the first lines of git log?

Regards,
Markus
 

 
Counting objects: 63, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)
error: failed to push some refs to 'ssh://logerrit/core'


On Fri, Aug 28, 2015 at 5:41 PM Markus Mohrhard <[hidden email]> wrote:
Hey,


On Fri, Aug 28, 2015 at 2:10 PM, Shreyansh Gandhi <[hidden email]> wrote:

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh




You are not allowed to push to master. Instead you need to use something like git push origin HEAD:refs/for/master which will push it to the review queue.

Regards,
Markus
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice




_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240


On Fri, Aug 28, 2015 at 8:24 PM Markus Mohrhard <[hidden email]> wrote:
Hey,

On Fri, Aug 28, 2015 at 4:52 PM, Ashod Nakashian <[hidden email]> wrote:
On Fri, Aug 28, 2015 at 8:15 AM, Shreyansh Gandhi <[hidden email]> wrote:
Same result:-

git push origin HEAD:refs/for/master

Try replacing HEAD with the branch name.

No. Please read the error message. (" [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)")

You have somewhere a merge commit. Can you pastebin the first lines of git log?

Regards,
Markus
 

 
Counting objects: 63, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)
error: failed to push some refs to 'ssh://logerrit/core'


On Fri, Aug 28, 2015 at 5:41 PM Markus Mohrhard <[hidden email]> wrote:
Hey,


On Fri, Aug 28, 2015 at 2:10 PM, Shreyansh Gandhi <[hidden email]> wrote:

Hi,

So, the problem was that an original initial commit (with no actual changes) was being inherited from master. Now when I try to push my changes,

git push origin HEAD:master
Counting objects: 56, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (13/13), 1.44 KiB | 0 bytes/s, done.
Total 13 (delta 9), reused 0 (delta 0)
remote: Resolving deltas: 100% (9/9)
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done    
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

How should I fix this?

-Shreyansh




You are not allowed to push to master. Instead you need to use something like git push origin HEAD:refs/for/master which will push it to the review queue.

Regards,
Markus
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice


--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Daniel-6 Daniel-6
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

In reply to this post by Shreyansh Gandhi
Shreyansh,

This may already have been answered, but after looking at your pastebin
it looks like you have three local commits. So I think you'll have to
re-write a bit of history before you commit.

You could try something like the following

git rebase -i HEAD~3

This will drop you into your favorite editor with something like the
following at the top of the file.

pick ec51cbb Initial commit
pick 2c6e661 Merge branch 'master' of http://anongit.freedesktop.org/git/libreoffice/core
pick 9904508 tdf#93240: replace boost::ptr_container with std::unique_ptr

I don't know what is in the commits, so I can't tell you exactly what to
do, but from the commit messages, I can assume you can delete the first
commit "Initial commit" by removing the line. Then things get more
complicated especially if any of the work you did in the third commit is
based off of anything included from the merge commit. The easiest method
I can hope will work is to also delete the merge commit line. So you'll
be left with the following at the top of the file.

pick 9904508 tdf#93240: replace boost::ptr_container with std::unique_ptr

save and close the file and then try the following

git rebase origin/master
git push origin HEAD:refs/for/master

In general as opposed to merging origin/master you would be better off
using rebase origin/master. Reason being, merging adds a commit in the
log, while rebasing merely applys your commits past the common commit to
the last commit of origin/master.

I'm still a noobie to this project, so I can't promise this will work
or is the cause of the problem you're facing, but I hope it helps! If
you would like more information about rebasing I would strongly suggest
the Rewriting History section of Pro Git.

Book:
    http://www.git-scm.com/book/en/v2

Rewriting History section:
    http://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History

Hope it helps!

Best,

Daniel

On Fri, Aug 28, 2015 at 10:04:47AM +0000, Shreyansh Gandhi wrote:

> *./logerrit submit master*
> Counting objects: 64, done.
> Delta compression using up to 4 threads.
> Compressing objects: 100% (10/10), done.
> Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
> Total 11 (delta 8), reused 0 (delta 0)
> remote: Resolving deltas: 100% (8/8)
> remote: Processing changes: refs: 1, done
> To ssh://logerrit/core
>  ! [remote rejected] HEAD -> refs/for/master (change 9724 closed)
> error: failed to push some refs to 'ssh://logerrit/core'
>
>
> On Fri, Aug 28, 2015 at 2:51 PM Samuel Mehrbrodt <[hidden email]>
> wrote:
>
> > Try
> >
> > ./logerrit submit master
> >
> >
> > Check https://wiki.documentfoundation.org/Development/gerrit for more
> > information.
> >
> > Samuel
> >
> >
> > Am 28.08.2015 um 10:58 schrieb Shreyansh Gandhi:
> >
> > Hi,
> >
> > I'm unable to figure out why my commits are not being pushed.
> >
> >  *$ git push --set-upstream origin my_93240 *
> > Counting objects: 61, done.
> > Delta compression using up to 4 threads.
> > Compressing objects: 100% (10/10), done.
> > Writing objects: 100% (11/11), 1.15 KiB | 0 bytes/s, done.
> > Total 11 (delta 8), reused 0 (delta 0)
> > remote: Resolving deltas: 100% (8/8)
> > remote: Processing changes: refs: 1, done
> > To ssh://logerrit/core
> >  ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)
> > error: failed to push some refs to 'ssh://logerrit/core'
> >
> > How do I fix this?
> >
> > Regards,
> > Shreyansh
> > --
> > Regards,
> > Shreyansh Gandhi
> >
> >
> > _______________________________________________
> > LibreOffice mailing [hidden email]://lists.freedesktop.org/mailman/listinfo/libreoffice
> >
> >
> > --
> Regards,
> Shreyansh Gandhi

> _______________________________________________
> LibreOffice mailing list
> [hidden email]
> http://lists.freedesktop.org/mailman/listinfo/libreoffice


_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

signature.asc (484 bytes) Download Attachment
Norbert Thiebaud Norbert Thiebaud
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

On Sat, Aug 29, 2015 at 12:21 PM, Daniel <[hidden email]> wrote:
> In general as opposed to merging origin/master you would be better off
> using rebase origin/master.

To add to that: it is not just 'in general'
for this project it is a rule. no merge commit.

when refreshing you local master always use 'git pull -r'

now, Shreyansh:

1/ You _really_ need to spend some time to read a git primer.. there
are plenty of them on the internet, text, slideshow, video etc,
explaining it in all kind of ways, I'm just you'll find one that
resonate with you.

2/ you _really_ need to read what the tools are telling you when you
run a command:

for example:

> $ git push --set-upstream origin my_93240

where did you get that from?. this command tell gerrit to push you
branch my_93240 to a branch of the same name on origin and remember
that association for the next time
no surprizingly:
To ssh://logerrit/core
 ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)

Yes you are prohibited to create random branches on the upstream repo.

then
> ./logerrit submit master
[..]]
>! [remote rejected] HEAD -> refs/for/master (change 9724 closed)

even if that does not talk to you google of "! [remote rejected] HEAD
-> refs/for/master (change 9724 closed)"

In any case you should really understand what you are trying to push

git log --decorate goes a long way.

next:

> git push origin HEAD:master
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

you ask again: How should I fix this?
by readin the long and clear message:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect

you are trying to push directly to master, bypassing gerrit review
altogether, of course that is not allowed.

finally:

>git push origin HEAD:refs/for/master
[...]
> ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)

yaou said : "same result"
Well again read the message. no it is not the 'same result' not even close.
This time you would be allowed to push to the destination you
indicated.. but you are trying to push
a merge commit, which the message is clearly telling you you are not
allowed to do.

your subsequent git log show a 'merge commit' and a puzzling 'initial
commit' in you history...
I have no idea how you got there.. but as the first Law of Holes
state: if you find yourself in a hole, stop digging.

The random try and error method require that you go back to a known
sane state between tries.


Norbert
_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice
Shreyansh Gandhi Shreyansh Gandhi
Reply | Threaded
Open this post in threaded view
|

Re: Error while pushing commits for bug 93240

Thanks for all the help everyone. Finally pushed the commit for review. :)

On a side note, does gerrit.libreoffice.org have https support for pushing patches?
If so, can anyone send me the http link to be used for pushing?

-Shreyansh.

On Sun, Aug 30, 2015 at 12:56 AM Norbert Thiebaud <[hidden email]> wrote:
On Sat, Aug 29, 2015 at 12:21 PM, Daniel <[hidden email]> wrote:
> In general as opposed to merging origin/master you would be better off
> using rebase origin/master.

To add to that: it is not just 'in general'
for this project it is a rule. no merge commit.

when refreshing you local master always use 'git pull -r'

now, Shreyansh:

1/ You _really_ need to spend some time to read a git primer.. there
are plenty of them on the internet, text, slideshow, video etc,
explaining it in all kind of ways, I'm just you'll find one that
resonate with you.

2/ you _really_ need to read what the tools are telling you when you
run a command:

for example:

> $ git push --set-upstream origin my_93240

where did you get that from?. this command tell gerrit to push you
branch my_93240 to a branch of the same name on origin and remember
that association for the next time
no surprizingly:
To ssh://logerrit/core
 ! [remote rejected] my_93240 -> my_93240 (prohibited by Gerrit)

Yes you are prohibited to create random branches on the upstream repo.

then
> ./logerrit submit master
[..]]
>! [remote rejected] HEAD -> refs/for/master (change 9724 closed)

even if that does not talk to you google of "! [remote rejected] HEAD
-> refs/for/master (change 9724 closed)"

In any case you should really understand what you are trying to push

git log --decorate goes a long way.

next:

> git push origin HEAD:master
remote: Branch refs/heads/master:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect
remote: Processing changes: refs: 1, done
To ssh://logerrit/core
 ! [remote rejected] HEAD -> master (prohibited by Gerrit)

you ask again: How should I fix this?
by readin the long and clear message:
remote: You are not allowed to perform this operation.
remote: To push into this reference you need 'Push' rights.
remote: User: phenom
remote: Please read the documentation and contact an administrator
remote: if you feel the configuration is incorrect

you are trying to push directly to master, bypassing gerrit review
altogether, of course that is not allowed.

finally:

>git push origin HEAD:refs/for/master
[...]
> ! [remote rejected] HEAD -> refs/for/master (you are not allowed to upload merges)

yaou said : "same result"
Well again read the message. no it is not the 'same result' not even close.
This time you would be allowed to push to the destination you
indicated.. but you are trying to push
a merge commit, which the message is clearly telling you you are not
allowed to do.

your subsequent git log show a 'merge commit' and a puzzling 'initial
commit' in you history...
I have no idea how you got there.. but as the first Law of Holes
state: if you find yourself in a hole, stop digging.

The random try and error method require that you go back to a known
sane state between tries.


Norbert
--
Regards,
Shreyansh Gandhi

_______________________________________________
LibreOffice mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/libreoffice