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 141817

Summary: Replace external.py with Ant task to download binaries
Product: www Reporter: Jesse Glick <jglick>
Component: Builds & RepositoriesAssignee: Jesse Glick <jglick>
Status: RESOLVED FIXED    
Severity: blocker CC: anebuzelsky, mzlamal, pjiricka
Priority: P1    
Version: 6.x   
Hardware: All   
OS: All   
URL: http://wiki.netbeans.org/ExternalBinaries
Issue Type: TASK Exception Reporter:
Attachments: Working patch (without update of actual external bins)
Updated patch

Description Jesse Glick 2008-07-27 22:14:55 UTC
Due to problems that have arisen with the external binaries Hg hook (mainly with MQ and 3-way merges), I would like to
replace it with a download task run as the very first part of the build. (Upload would then be manual - you would need
to open http://hg.netbeans.org/upload in a web browser, as well as edit a textual manifest to register the binary.) I
think on balance it would make NB Hg usage more predictable, despite the increased number of steps involved in making
changes to external binaries.

Obviously everyone who manipulates external binaries would need to be aware of the change. The change would need to also
include code (left in for several months at least) to remove the old external.py registration from .hg/hgrc and
otherwise clean up from existing working copies. People developing branches with new external binaries would need to
correct their registration of these binaries in the branch after merging in the change from main (I would fix all the
binaries in main).
Comment 1 Jesse Glick 2008-07-27 22:57:23 UTC
The only change needed on the server side, to the CGI script, is in the resulting message:

< <p>Uploaded as:</p>
> <p>Uploaded. Add to your manifest:</p>
Comment 2 Jesse Glick 2008-07-27 23:38:25 UTC
Created attachment 65756 [details]
Working patch (without update of actual external bins)
Comment 3 Jesse Glick 2008-07-28 00:21:28 UTC
Conversion of existing binaries can be accomplished with

for f in `ls -1 */external/*.{zip,jar,gz,bz2,gem,dll} | sort`; do hash=`cut -c 13-52 $f`; n=`basename $f`; d=`dirname
$f`; echo $hash $n >> $d/binaries-list; hg rm $f; hg add $d/binaries-list; done
Comment 4 Jesse Glick 2008-07-28 01:01:06 UTC
Created attachment 65758 [details]
Updated patch
Comment 5 Jesse Glick 2008-07-28 01:10:07 UTC
Patch seems to be working well. Starting with a revision from main which has been built (thus has .hg/hgrc substituted
and ext bins checked out in real form), if I merge with the patched revision, versioned ext bins are correctly deleted;
after running 'ant bootstrap', the external.py registration in hgrc is correctly removed and ext bins are correctly
recreated by the Ant task.

I would like to get this change into main this week. I don't need anything specific from Michal other than to be
available to help resolve any issues that might arise on build servers to which I have no shell access (such as konik
and hlemyzd).
Comment 6 Antonin Nebuzelsky 2008-07-28 12:04:05 UTC
Jesse, this week is not a good timing at all.

Next Monday we are "branching" 6.5 Beta release. This week is critical from the stability point of view.
Comment 7 Antonin Nebuzelsky 2008-07-28 12:11:04 UTC
Actually, is there a strong reason why not wait until a separate repo is created for 6.5? (mid September)

There will be much more space for changes like this which affect all developers and force them to change the way they work.
Comment 8 Jesse Glick 2008-07-28 14:30:49 UTC
Waiting until September is too long. People have problems with the external hook during any active development.
Comment 9 Jesse Glick 2008-08-22 16:33:03 UTC
main #29c30ed3006a, main #2109af7f1da2, contrib #606c1d1e04a6
Comment 10 Quality Engineering 2008-08-23 05:21:28 UTC
Integrated into 'main-golden', available in build *200808230201* on http://bits.netbeans.org/dev/nightly/
Changeset: http://hg.netbeans.org/main/rev/29c30ed3006a
User: Jesse Glick <jglick@netbeans.org>
Log: Issue #141817: replace external.py encode/decode hook with Ant task to download external binaries.