This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 143483 - hg fetch fails when merging changes in binary libraries
Summary: hg fetch fails when merging changes in binary libraries
Status: RESOLVED INVALID
Alias: None
Product: www
Classification: Unclassified
Component: Builds & Repositories (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: Michal Zlamal
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-11 15:19 UTC by Jan Lahoda
Modified: 2010-10-13 07:23 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Lahoda 2008-08-11 15:19:21 UTC
Not sure if this is a Mercurial problem or problem of the NetBeans external binaries hook, so starting here.

I tried to fetch new changes from the remote repository, and the fetch ended with:
abort: /usr/local/home/lahvac/src/nb/outgoing/libs.javacimpl/external/javac-impl-nb-7.0-b07.jar looks like a binary file.

(full session is:
pulling from http://hg.netbeans.org/main
searching for changes
adding changesets
adding manifests
adding file changes
added 62 changesets with 246 changes to 241 files (+1 heads)
updating to 95548:7c70be712357
Downloading http://hg.netbeans.org/binaries/2366BE318BCA6C0434673F1382028B7B5DF357BA-javac-impl-nb-7.0-b07.jar
243 files updated, 0 files merged, 12 files removed, 0 files unresolved
merging with 95486:0145ad606dcb
merging libs.javacimpl/external/javac-impl-nb-7.0-b07.jar
abort: /usr/local/home/lahvac/src/nb/outgoing/libs.javacimpl/external/javac-impl-nb-7.0-b07.jar looks like a binary file.
)

The problem seems to be that the "libs.javacimpl/external/javac-impl-nb-7.0-b07.jar" library has been changed both
"locally" and "remotely", and the merge will fail. The log contains the change ids, so it should be possible to
reproduce the merge once I push all my changes (which will take a while now, because I am going to delete the
repository, clone a new one, do merge without the external hook, do a full build, etc.).

I saw this problem once, and the solution was to disable the external binaries hook, and do the merge over "textual"
.jar files.
Comment 1 Michal Zlamal 2008-08-11 15:31:22 UTC
The behavior is correct you were tried to merge file which was changed by somebody other.  You just need to update the external file once more and then 
commit it. You don't need to clone again. If you want to re-do the merge, you can just run: hg up -C, hg merge and you're done.
Comment 2 Jesse Glick 2008-08-21 01:21:24 UTC
The bug is real; it is due to the fact that Mercurial does not properly consult encode/decode hooks when merging. Anyway
we plan to cease using the external binaries hook very soon.