Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Versioning conflict must be resolved from command line
Versioning conflict must be resolved from command line [message #582554] Mon, 23 August 2010 11:26 Go to next message
GianMaria Romanato is currently offline GianMaria RomanatoFriend
Messages: 72
Registered: July 2009
Member
Hello,

I am experiencing the following issue. Please let me understand if this flow is normal as of today due to the fact that EGit is still in an early stage or if something is wrong and I should open a defect.

1. If two users modify the same file, the first user who commits and pushes will be able to publish his/her changes to the repository, while the second user will be stuck with a "Rejected" error message in the push dialog, without really understanding which file is being rejected nor why.

2. At this point the second user will perform a fetch and a merge using EGit. Fetch succeeds, while Merge will report that EGit does not support merging yet. So the user reverts back to command line (git merge origin/master), receiving the following error message: "Automatic merge failed; fix conflicts and then commit the result."

3. In step 2 the local file has been changed by EGit to include both the change sets from the two users.

4. The second user opens the editor and fixes the file manually, then he/she tries to commit.

5. Via command line the user stages the file again (this cannot be done using EGit). Via command line user commits (this would not work using EGit)

5B. I guess that as a GUI alternative to 5 one should try to commit directly from EGit selecting files to be staged in the dialog, but this fails with "Repository state: Conflicts".

6. Finally the user can push from EGit

Every now and then we also get the following error message: "Cannot work with other stages than zero right now. Won't write corrupt index"

Thanks
Giamma.


Developing for Virgo using PDE: http://bit.ly/1w0tTit
Global JNDI in Virgo: http://bit.ly/1to42mn
Hyperic to monitor Virgo: http://bit.ly/W1Fst9
Profile Virgo with JProfiler http://bit.ly/1FBLGCw
Re: Versioning conflict must be resolved from command line [message #582568 is a reply to message #582554] Wed, 25 August 2010 09:02 Go to previous messageGo to next message
Stefan Lay is currently offline Stefan LayFriend
Messages: 342
Registered: July 2009
Senior Member
Hi Giamma,

you hit a feature that is not implemented in the current release egit 0.8.4 but which will be contained in the next release 0.9.1 which will be delievered with Helios SR1 in september.

> Please let me understand if this flow is normal as of today due to the fact that EGit is still in an early stage or if something is wrong and I should open a defect.

There is already an enhancement request: https://bugs.eclipse.org/bugs/show_bug.cgi?id=303404

> 1. If two users modify the same file, the first user who commits and pushes will be able to publish his/her changes to the repository, while the second user will be stuck with a "Rejected" error message in the push dialog, without really understanding which file is being rejected nor why.

That's really annoying. There is also an open bug 319974

> 3. In step 2 the local file has been changed by EGit to include both the change sets from the two users.

This change is done by the merge on the command line, right?

> 5. Via command line the user stages the file again (this cannot be done using EGit). Via command line user commits (this would not work using EGit)

Both these features are not contained in 0.8.4 but work already in the current nightly build.

> 5B. I guess that as a GUI alternative to 5 one should try to commit directly from EGit selecting files to be staged in the dialog, but this fails with "Repository state: Conflicts".

I think that the staging step is mandatory because with this the user explicitly states that he considers a conflict as being resolved.

> Every now and then we also get the following error message: "Cannot work with other stages than zero right now. Won't write corrupt index"

This occurs for example when you want to reset in case of conflicts. For this there is the open bug 319844. That should definitely be fixed until release 1.0. Did you get that error on other situations?

So in summary, the merge scenario should work with the next release 0.9.1. However, there will possibly still be some limitations, for example that reset will not work in case of a merge.

Stefan
Re: Versioning conflict must be resolved from command line [message #582594 is a reply to message #582568] Fri, 27 August 2010 07:59 Go to previous message
GianMaria Romanato is currently offline GianMaria RomanatoFriend
Messages: 72
Registered: July 2009
Member
>> 3. In step 2 the local file has been changed by EGit to include both the change sets from the two users.
> This change is done by the merge on the command line, right?

Yes, and it's normal behaviour for GIT afaik, so no surprise here.

>> Every now and then we also get the following error message: "Cannot work with other stages than zero right now. Won't write corrupt index"

>This occurs for example when you want to reset in case of conflicts. For this there is
>the open bug 319844. That should definitely be fixed until release 1.0. Did you get that
>error on other situations?

Nope so far that is the only case I got this issue.

>So in summary, the merge scenario should work with the next release 0.9.1.
>However, there will possibly still be some limitations, for example that reset will not work in case of a merge.
>
>Stefan


Thank you very much for your help.

Giamma.


Developing for Virgo using PDE: http://bit.ly/1w0tTit
Global JNDI in Virgo: http://bit.ly/1to42mn
Hyperic to monitor Virgo: http://bit.ly/W1Fst9
Profile Virgo with JProfiler http://bit.ly/1FBLGCw
Previous Topic:Freeze when committing
Next Topic:An egit push does not change my files
Goto Forum:
  


Current Time: Fri Mar 29 11:38:15 GMT 2024

Powered by FUDForum. Page generated in 0.03647 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top