Re: Dymystifying Gump Code...
Adam R. B. Jack wrote: Honestly, I am not capable of learn any more languages. I am an old dog, and not interested in learning it. By the time Java is no longer a "job opportunity" or fun, I will retire to fishing. Is that understandable? Niclas, I understand. I should've said 'make it readable/understandable to Java programmers' ... ' who care to read it'. For those who don't, then I'll try to make Gump documented clearly enough (at user level) to work for you. (Not knowing Python doesn't stop folk from using a MoinMoin Wiki. Hopefully, I can achieve that for Gump users.) What I am trying to say... I would love to help out with Gump at code level, but Python is a hinder that I won't try to climb. Fishing sounds more tantalizing. ;o) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dymystifying Gump Code...
> > It is clear that for Python Gump to flourish, it's code needs to be clear & > > documented (to make it readable/understandable to Java programmers). It need > > to be transparent, and accessible. I'll do my best to help with that. > > Could you also post a link to a Python-to-Java translator?? :o) Read right to left. ;-) http://www.daimi.au.dk/~chili/CSS/pythonForJavaProgrammers.htm http://www.razorvine.net/python/PythonComparedToJava > Honestly, I am not capable of learn any more languages. I am an old > dog, and not interested in learning it. By the time Java is no longer > a "job opportunity" or fun, I will retire to fishing. Is that > understandable? Niclas, I understand. I should've said 'make it readable/understandable to Java programmers' ... ' who care to read it'. For those who don't, then I'll try to make Gump documented clearly enough (at user level) to work for you. (Not knowing Python doesn't stop folk from using a MoinMoin Wiki. Hopefully, I can achieve that for Gump users.) The world doesn't wait for us old dogs to retire. Maybe I'm just hoping to ride out a tad longer. ;-) regards, Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dymystifying Gump Code...
Adam R. B. Jack wrote: It is clear that for Python Gump to flourish, it's code needs to be clear & documented (to make it readable/understandable to Java programmers). It need to be transparent, and accessible. I'll do my best to help with that. Could you also post a link to a Python-to-Java translator?? :o) Honestly, I am not capable of learn any more languages. I am an old dog, and not interested in learning it. By the time Java is no longer a "job opportunity" or fun, I will retire to fishing. Is that understandable? Cheers Niclas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dymystifying Gump Code...
Along these lines, could I get feedback on these two modules? If folks can grok these, maybe there is hope for Python Gump. The builder: (see method buildProject): http://cvs.apache.org/viewcvs.cgi/gump/python/gump/build/builder.py?rev=1.7&view=markup The AntBuilder (there are also ScriptBuilder, MavenBuilder) -- called from above: http://cvs.apache.org/viewcvs.cgi/gump/python/gump/build/ant.py?view=markup All feedback on style/comments (or lack) would be appreicated so I can improve them. Heck, even 'what the bleep does this mean, in Python?" would be fine. regards Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Gump Wiki] Updated: GumpCode
Date: 2004-07-12T12:37:16 Editor: 67.235.113.203 <> Wiki: Gump Wiki Page: GumpCode URL: http://wiki.apache.org/gump/GumpCode no comment Change Log: -- @@ -23,7 +23,7 @@ The [http://brutus.apache.org/gump/pydoc/gump.runner.html Runner] loops throug the build sequence and (when needed) does an [http://brutus.apache.org/gump/pydoc/gump.update.html update] on a module before doing a [http://brutus.apache.org/gump/pydoc/gump.build.html build] of the project. When done (with each) a [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#RunEvent Run Event] is dispatched to all listening worker/actors. The workers/actors do their thing (e.g. update stats, generate documentation, etc.) -Note: Currently context (such as output from exec commands) are stored on the model, not on a wrapper, hence the module is poluted by the run & not re-usable. [Work todo...] +Note: Currently context (such as output from exec commands) are stored on the model, not on a wrapper, hence the model/tree is poluted by the run & not re-usable. [Work todo...] '''Workers (Actors)''': - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Gump Wiki] Updated: GumpCode
Date: 2004-07-12T12:35:54 Editor: 67.235.113.203 <> Wiki: Gump Wiki Page: GumpCode URL: http://wiki.apache.org/gump/GumpCode Closed ] Change Log: -- @@ -40,7 +40,7 @@ '''Random Important''': * [http://brutus.apache.org/gump/pydoc/gump.loader.html Loading from XML to model] - * [http://brutus.apache.org/gump/pydoc/gump.utils.html Utility code (e.g. file sync, DOM, exec) + * [http://brutus.apache.org/gump/pydoc/gump.utils.html Utility code] (e.g. file sync, DOM, exec, etc.) '''Random Minor''': - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/project jakarta-commons.xml
leosutic2004/07/12 12:23:32 Modified:project jakarta-commons.xml Log: Adding Attributes to build. (It's been promoted from Sandbox.) Revision ChangesPath 1.139 +29 -0 gump/project/jakarta-commons.xml Index: jakarta-commons.xml === RCS file: /home/cvs/gump/project/jakarta-commons.xml,v retrieving revision 1.138 retrieving revision 1.139 diff -u -r1.138 -r1.139 --- jakarta-commons.xml 8 Jul 2004 14:54:51 - 1.138 +++ jakarta-commons.xml 12 Jul 2004 19:23:32 - 1.139 @@ -23,6 +23,35 @@ + +org.apache.commons.attributes +Commons Attributes + + + + + + + + + + + + + + + + + + + + + org.apache.commons.beanutils Bean Utilities (Core) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/project jakarta-commons-sandbox.xml
leosutic2004/07/12 12:22:54 Modified:project jakarta-commons-sandbox.xml Log: Removing Attributes from sandbox build. (It's been promoted.) Revision ChangesPath 1.168 +0 -29 gump/project/jakarta-commons-sandbox.xml Index: jakarta-commons-sandbox.xml === RCS file: /home/cvs/gump/project/jakarta-commons-sandbox.xml,v retrieving revision 1.167 retrieving revision 1.168 diff -u -r1.167 -r1.168 --- jakarta-commons-sandbox.xml 6 Jul 2004 09:59:48 - 1.167 +++ jakarta-commons-sandbox.xml 12 Jul 2004 19:22:54 - 1.168 @@ -22,35 +22,6 @@ - -org.apache.commons.attributes -Commons Attributes - - - - - - - - - - - - - - - - - - - - - org.apache.commons.compress Commons Compression Package - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Gump Wiki] Updated: GumpCode
Date: 2004-07-12T12:31:11 Editor: 67.235.113.203 <> Wiki: Gump Wiki Page: GumpCode URL: http://wiki.apache.org/gump/GumpCode no comment Change Log: -- @@ -23,6 +23,8 @@ The [http://brutus.apache.org/gump/pydoc/gump.runner.html Runner] loops throug the build sequence and (when needed) does an [http://brutus.apache.org/gump/pydoc/gump.update.html update] on a module before doing a [http://brutus.apache.org/gump/pydoc/gump.build.html build] of the project. When done (with each) a [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#RunEvent Run Event] is dispatched to all listening worker/actors. The workers/actors do their thing (e.g. update stats, generate documentation, etc.) +Note: Currently context (such as output from exec commands) are stored on the model, not on a wrapper, hence the module is poluted by the run & not re-usable. [Work todo...] + '''Workers (Actors)''': The workers work on the content tree (the tree of results) based off events that come from the runner, e.g. module complete, project completed, etc. These actors process the state of the entity and do their thing (including updating information on that entity in the tree, e.g. timestamps). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Dymystifying Gump Code...
It is clear that for Python Gump to flourish, it's code needs to be clear & documented (to make it readable/understandable to Java programmers). It need to be transparent, and accessible. I'll do my best to help with that. Could I get some feedback on this: http://wiki.apache.org/gump/GumpCode Also, how ought we go about getting me to understand what is not understandable? Could we come up with a few real or pseudo code changes, and document/discuss what would need to be done in order to achieve them? I know Stefan has a pet task (Javadoc?), and we have MagicBuilder. Could we get a few more? With them I'll try to understand what needs to be done, and go see if the code is documented for the Python/Gump Python newbie to be able to do those changes. Also, any other input on ways to get this thing out into the open, and clear for all? Thanks in advance. regards, Adam -- Experience the Unwired Enterprise: http://www.sybase.com/unwiredenterprise Try Sybase: http://www.try.sybase.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Gump Wiki] Updated: GumpCode
Date: 2004-07-12T12:08:16 Editor: 67.235.113.203 <> Wiki: Gump Wiki Page: GumpCode URL: http://wiki.apache.org/gump/GumpCode Added more verbiage. Change Log: -- @@ -7,13 +7,21 @@ '''Main Packages:''' -See GumpInternals for how a run (the tree of context) is formed (objects from XML) and worked on. +See GumpInternals for how a run (the tree of context) is formed/loaded (objects from XML) and worked upon. - * [http://brutus.apache.org/gump/pydoc/gump.core.html Core Classes (e.g. Gump Run)] - * [http://brutus.apache.org/gump/pydoc/gump.model.html Object Model (e.g. Project/Module...)] - * [http://brutus.apache.org/gump/pydoc/gump.runner.html Running (perform a run)] - * [http://brutus.apache.org/gump/pydoc/gump.update.html Updating (CVS/SVN/etc.)] - * [http://brutus.apache.org/gump/pydoc/gump.build.html Building (Ant/Maven/etc.)] + * [http://brutus.apache.org/gump/pydoc/gump.core.html Core Classes] (e.g. [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpRunOptions GumpRunOptions], [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpSet GumpSet], [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpRun GumpRun]) + * [http://brutus.apache.org/gump/pydoc/gump.model.html Object Model] (e.g. Project/Module, etc.) + * [http://brutus.apache.org/gump/pydoc/gump.runner.html Runner] (perform a run) + * [http://brutus.apache.org/gump/pydoc/gump.update.html Updater] (CVS/SVN/etc.) + * [http://brutus.apache.org/gump/pydoc/gump.build.html Builder] (Ant/Maven/etc.) + +1) Create [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpSet GumpSet] + +The input parameters (e.g. all or * or avalon-*) are matched against projects in the loaded workspace to determine a list of projects. The dependencies for those projects are sorted to create an order project sequence. The modules for that complete sequence is stored. We now have a full GumpSet with all the details we need to perform a run. This (along with [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpRunOptions Run Options]), and the original workspace tree (of projects/modules) are stored on a [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#GumpRun GumpRun]. + +2) [http://brutus.apache.org/gump/pydoc/gump.runner.html Run] + +The [http://brutus.apache.org/gump/pydoc/gump.runner.html Runner] loops throug the build sequence and (when needed) does an [http://brutus.apache.org/gump/pydoc/gump.update.html update] on a module before doing a [http://brutus.apache.org/gump/pydoc/gump.build.html build] of the project. When done (with each) a [http://brutus.apache.org/gump/pydoc/gump.core.gumprun.html#RunEvent Run Event] is dispatched to all listening worker/actors. The workers/actors do their thing (e.g. update stats, generate documentation, etc.) '''Workers (Actors)''': - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/python/gump/runner demand.py runner.py
ajack 2004/07/12 11:24:27 Modified:python/gump/runner demand.py runner.py Log: More of the same... Revision ChangesPath 1.7 +20 -10gump/python/gump/runner/demand.py Index: demand.py === RCS file: /home/cvs/gump/python/gump/runner/demand.py,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- demand.py 12 Jul 2004 16:07:41 - 1.6 +++ demand.py 12 Jul 2004 18:24:27 - 1.7 @@ -129,25 +129,35 @@ printTopRefs(100,'Before Loop') +# The key information gumpSet=self.run.getGumpSet() - +gumpOptions=self.run.getOptions() workspace = self.run.getWorkspace() -if workspace.isMultithreading() and workspace.hasUpdaters(): -# Experimental... -self.spawnUpdateThreads(workspace.getUpdaters()) +if gumpOptions.isUpdate(): +if workspace.isMultithreading() and workspace.hasUpdaters(): +# Experimental... +self.spawnUpdateThreads(workspace.getUpdaters()) + +# The project TODO list... +if gumpOptions.isQuick(): +sequence=gumpSet.getProjects() +else: +sequence=gumpSet.getProjectSequence() # In order... -for project in gumpSet.getProjectSequence(): +for project in sequence: # Process the module, upon demand module=project.getModule() -if not module.isUpdated(): -log.debug('Update module *inlined* ' + `module` + '.') -self.performUpdate(module) +if gumpOptions.isUpdate(): +if not module.isUpdated(): +log.debug('Update module *inlined* ' + `module` + '.') +self.performUpdate(module) -# Process the project -self.performBuild(project) +if gumpOptions.isBuild(): +# Process the project +self.performBuild(project) # Seems a nice place to peek/clean-up... #printTopRefs(100,'Before Loop GC') 1.8 +1 -1 gump/python/gump/runner/runner.py Index: runner.py === RCS file: /home/cvs/gump/python/gump/runner/runner.py,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- runner.py 12 Jul 2004 18:19:05 - 1.7 +++ runner.py 12 Jul 2004 18:24:27 - 1.8 @@ -160,7 +160,7 @@ log.debug('Perform run using [' + `self` + ']') -self.performRun() +return self.performRun() def getRunner(run): from gump.runner.demand import OnDemandRunner - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/python/gump/document/xdocs documenter.py
ajack 2004/07/12 11:19:05 Modified:python/gump/runner runner.py python/gump/document/xdocs documenter.py Log: Some work on command line (human) running of Gump. Revision ChangesPath 1.7 +4 -2 gump/python/gump/runner/runner.py Index: runner.py === RCS file: /home/cvs/gump/python/gump/runner/runner.py,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- runner.py 8 Jul 2004 20:33:11 - 1.6 +++ runner.py 12 Jul 2004 18:19:05 - 1.7 @@ -112,7 +112,8 @@ self.run.registerActor(Statistician(self.run)) # Generate results -self.run.registerActor(Resulter(self.run)) +if self.run.getOptions().isResults(): +self.run.registerActor(Resulter(self.run)) # Document.. # Use XDOCS if not overridden... @@ -128,7 +129,8 @@ self.run.registerActor(documenter) # Syndicate once documented -self.run.registerActor(Syndicator(self.run)) +if self.run.getOptions().isSyndicate(): +self.run.registerActor(Syndicator(self.run)) # Notify last if self.run.getOptions().isNotify() and self.run.getWorkspace().isNotify(): 1.13 +30 -19gump/python/gump/document/xdocs/documenter.py Index: documenter.py === RCS file: /home/cvs/gump/python/gump/document/xdocs/documenter.py,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- documenter.py 8 Jul 2004 20:33:09 - 1.12 +++ documenter.py 12 Jul 2004 18:19:05 - 1.13 @@ -379,8 +379,7 @@ # Workspace Pieces # def documentRunDetails(self): - - + # # -- # @@ -396,21 +395,8 @@ definitionSection=document.createSection('Run Details') if not self.gumpSet.isFull(): -notice=definitionSection.createWarning() - -notice.createText("""This output does not represent the complete workspace, -but part of it. -Only projects, and their dependents, matching this regular expression """) -notice.createStrong(self.gumpSet.projectexpression) -notice.createBreak() -notice.createBreak() -notice.createStrong('Requested Projects: ') -notice.createBreak() -notice.createBreak() -for project in self.gumpSet.projects: -notice.createText(project.name) -notice.createText(' ') - +self.documentPartial(definitionSection) + definitionTable=definitionSection.createTable() definitionTable.createEntry('Gump Run GUID', self.run.getRunGuid()) definitionTable.createEntry('Gump Run (Hex) GUID', self.run.getRunHexGuid()) @@ -453,6 +439,22 @@ document.serialize() document=None +def documentPartial(self,node): +notice=node.createWarning() + +notice.createText("""This output does not represent the complete workspace, +but part of it. +Only projects, and their dependents, matching this regular expression """) +notice.createStrong(self.gumpSet.projectexpression) +notice.createBreak() +notice.createBreak() +notice.createStrong('Requested Projects: ') +notice.createBreak() +notice.createBreak() +for project in self.gumpSet.projects: +notice.createText(project.name) +notice.createText(' ') + def documentEverythingElse(self): self.documentRepositories() @@ -767,15 +769,24 @@ spec.getRootPath()) if realTime: + +# Work done... +modules = len(self.gumpSet.getCompletedModules()) +projects = len(self.gumpSet.getCompletedProjects()) + document.createWarning("""This Gump run is currently in progress. -It started at %s.""" -% self.workspace.getStartDateTime() ) +It started at %s. So far %s modules have been updated, and %s projects built.""" \ +% (self.workspace.getStartDateTime(), modules, projects )) + else: document.createNote("""This Gump run is
Re: brutus may be having a problem
> Adam R. B. Jack wrote: > > 2) Restore the config such that http://brutus.apache.org/gump/{flavour} goes > > to /usr/local/gump/{flavour}/results. > > done (for public, jdk15 and test, not any "flavour"). Thanks, I've restored the config to write back to these places. regards Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: cvs commit: gump/python/gump/build builder.py
> Log: > Halved the work done after a module update or project build (the events were being dispatched twice!) Let's see how fast Brutus goes now. :) Note: This isn't updating/building twice, it is documenting/notifiying/etc twice. So, the increase will not be extremely dramatic, unless we have a lot lot more optimizations to gain w/ this part. > Worked on notification (the two e-mails were a tipoff to above). I'll turn these back on shortly. regards Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: MagicBuilder
Leo Simons wrote: Stephen McConnell wrote: Leo Simons wrote: Stefan Bodewig wrote: I tend to agree with most of what has been said in this thread so far. thought I'd chime in: "what he said". I really want to learn python well enough to write more than simple shell scripts using it. Isaid that over a year ago. Here I am, still saying it. One has to wonder whether I'll still be saying it next year. In the meantime, I'm a gump junkie without the Power to Contribute. Would you like to take care of the MagicBuilder? N, not another TODO item :-D If you add it to jira, it gets pushed on the TODO list, whatever it is. What's a magic builder? (I'm behind on email again...) Unfortunately that's still no guarantee for it to get done. A magic builder is just a copy of an AntBuilder (ant.py) with some minor tweaks concerning classpath and properties that are passed to ant. Adam Jack provided a summary of the changes needed in this email: http://marc.theaimsgroup.com/?l=gump&m=108951401427698&w=2 Cheers, Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/python/gump/runner demand.py
ajack 2004/07/12 09:07:41 Modified:python/gump/runner demand.py Log: Pressed COMMIT before the unit test finished... Revision ChangesPath 1.6 +1 -1 gump/python/gump/runner/demand.py Index: demand.py === RCS file: /home/cvs/gump/python/gump/runner/demand.py,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- demand.py 12 Jul 2004 15:54:17 - 1.5 +++ demand.py 12 Jul 2004 16:07:41 - 1.6 @@ -119,7 +119,7 @@ self.run.generateEvent(project) # Mark completed -gumpSet.setCompletedProject(project) +self.run.getGumpSet().setCompletedProject(project) ### - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: gump/python/gump/core config.py
ajack 2004/07/12 08:54:17 Modified:python/gump/runner demand.py python/gump/notify notifier.py python/gump/core config.py Log: Code cleanup. Updated version to 0002 (so can see when sites have been updated). Revision ChangesPath 1.5 +17 -4 gump/python/gump/runner/demand.py Index: demand.py === RCS file: /home/cvs/gump/python/gump/runner/demand.py,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- demand.py 8 Jul 2004 20:33:11 - 1.4 +++ demand.py 12 Jul 2004 15:54:17 - 1.5 @@ -106,6 +106,20 @@ module.setUpdated(True) finally: lock.release() + +def performBuild(self,project): +""" +Perform a project build +""" + +# Perform the build action +self.builder.buildProject(project) + +# Generate the build event +self.run.generateEvent(project) + +# Mark completed +gumpSet.setCompletedProject(project) ### @@ -132,10 +146,8 @@ log.debug('Update module *inlined* ' + `module` + '.') self.performUpdate(module) -# Process -self.builder.buildProject(project) -self.run.generateEvent(project) -gumpSet.setCompletedProject(project) +# Process the project +self.performBuild(project) # Seems a nice place to peek/clean-up... #printTopRefs(100,'Before Loop GC') @@ -144,6 +156,7 @@ #invokeGarbageCollection(self.__class__.__name__) #printTopRefs(100,'After GC') +# Kinda pointless given above if workspace.isMultithreading() and workspace.hasUpdaters(): self.waitForThreads() 1.8 +7 -6 gump/python/gump/notify/notifier.py Index: notifier.py === RCS file: /home/cvs/gump/python/gump/notify/notifier.py,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- notifier.py 12 Jul 2004 15:18:04 - 1.7 +++ notifier.py 12 Jul 2004 15:54:17 - 1.8 @@ -166,6 +166,10 @@ self.unsentSubjects += subject + '\n' self.unsents += 1 +def getNextIdentifier(self): +self.id += 1 +return self.id + def getUnwantedContent(self): return self.getBatchContent(self.unwanteds,self.unwantedSubjects,self.unwanted) @@ -209,8 +213,7 @@ def notifyWorkspace(self,notification): """ Notify for the workspace """ -content=notification.resolveContent(self.resolver, self.id) -self.id+=1 +content=notification.resolveContent(self.resolver, self.getNextIdentifier()) subject=self.workspace.prefix+': Gump Workspace ' + self.workspace.getName() @@ -222,8 +225,7 @@ """ Notify to a specific module's
cvs commit: gump/python/gump/build builder.py
ajack 2004/07/12 08:18:04 Modified:python/gump/model project.py python/gump/notify logic.py notifier.py python/gump/core commandLine.py gumprun.py python/gump/update updater.py python/gump/build builder.py Log: Halved the work done after a module update or project build (the events were being dispatched twice!) Worked on notification (the two e-mails were a tipoff to above). Revision ChangesPath 1.87 +1 -2 gump/python/gump/model/project.py Index: project.py === RCS file: /home/cvs/gump/python/gump/model/project.py,v retrieving revision 1.86 retrieving revision 1.87 diff -u -r1.86 -r1.87 --- project.py8 Jul 2004 20:33:07 - 1.86 +++ project.py12 Jul 2004 15:18:04 - 1.87 @@ -434,10 +434,9 @@ fromaddr=getDomAttributeValue(notifyEntry,'from',workspace.email) self.notifys.append( AddressPair( -getStringFromUnicode(toaddr),\ +getStringFromUnicode(toaddr), getStringFromUnicode(fromaddr))) - # Build Dependencies Map [including depends from 1: notification=PositiveNotification(self.run,entity) -else: -if self.run.getOptions().isOfficial() \ -and entity.containsNasties(): -notification=NegativeNotification(self.run,entity,'Contains warning/error annotations.') +# :TODO: +# 1) Too verbose +# 2) Need a warning type w/o the 'outstanding ...' +# else: +#if self.run.getOptions().isOfficial() \ +#and entity.containsNasties(): +#notification=NegativeNotification(self.run,entity,' contains warning/error annotations') #elif entity.isPrereqFailed(): #if (stats.sequenceInState == 1): 1.7 +5 -5 gump/python/gump/notify/notifier.py Index: notifier.py === RCS file: /home/cvs/gump/python/gump/notify/notifier.py,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- notifier.py 8 Jul 2004 20:33:06 - 1.6 +++ notifier.py 12 Jul 2004 15:18:04 - 1.7 @@ -206,11 +206,11 @@ if self.unsent: return 1 return 0 - def notifyWorkspace(self,notification): """ Notify for the workspace """ content=notification.resolveContent(self.resolver, self.id) +self.id+=1 subject=self.workspace.prefix+': Gump Workspace ' + self.workspace.getName() @@ -223,6 +223,7 @@ # Form the content... content=notification.resolveContent(self.resolver, self.id) +self.id+=1 # Form the subject subject=self.workspace.prefix+ \ @@ -240,6 +241,7 @@ # Form the content... # content=notification.resolveContent(self.resolver, self.id) +self.id+=1 # Form the subject subject=self.workspace.prefix+': ' \ @@ -295,10 +297,8 @@ sent=False try: -log.info('Send Notify e-mail (#' + `self.id` + ') :\n To: ' + str(toaddr) + \ -'\n From: ' + str(fromaddr) + \ -'\n Subject: ' + str(subject)) -self.id+=1 +log.info('Send Notify To: ' + str(toaddr) + +' From: ' + str(fromaddr) + ' Subject: ' + str(subject)) # Form the user visable part ... email=EmailMessage( toaddrs, 1.11 +13 -14gump/python/gump/core/commandLine.py Index: commandLine.py === RCS file: /home/cvs/gump/python/gump/core/commandLine.py,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- commandLine.py8 Jul 2004 20:33:09 - 1.10 +++ commandLine.py12 Jul 2004 15:18:04 - 1.11 @@ -85,42 +85,42 @@ if arg in ['-d','--debug']: removers.append(arg) log.info('Setting log level to DEBUG') -self.options.setVerbose(1) # Sub-set of debug -self.options.setDebug(1) +self.options.setVerbose(True) # Sub-set of debug +self.options.setDebug(True) log.setLevel(logging.DEBUG) elif arg in ['-v','--verbose']: removers.
MagicBuilder (was: Re: [RT] Was python a good idea?)
Stephen McConnell wrote: Leo Simons wrote: Stefan Bodewig wrote: I tend to agree with most of what has been said in this thread so far. thought I'd chime in: "what he said". I really want to learn python well enough to write more than simple shell scripts using it. Isaid that over a year ago. Here I am, still saying it. One has to wonder whether I'll still be saying it next year. In the meantime, I'm a gump junkie without the Power to Contribute. Would you like to take care of the MagicBuilder? N, not another TODO item :-D If you add it to jira, it gets pushed on the TODO list, whatever it is. What's a magic builder? (I'm behind on email again...) Unfortunately that's still no guarantee for it to get done. - LSD - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [RT] Was python a good idea?
Leo Simons wrote: Stefan Bodewig wrote: I tend to agree with most of what has been said in this thread so far. thought I'd chime in: "what he said". I really want to learn python well enough to write more than simple shell scripts using it. I said that over a year ago. Here I am, still saying it. One has to wonder whether I'll still be saying it next year. In the meantime, I'm a gump junkie without the Power to Contribute. Would you like to take care of the MagicBuilder? Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [RT] Was python a good idea?
Stefan Bodewig wrote: I tend to agree with most of what has been said in this thread so far. thought I'd chime in: "what he said". I really want to learn python well enough to write more than simple shell scripts using it. I said that over a year ago. Here I am, still saying it. One has to wonder whether I'll still be saying it next year. In the meantime, I'm a gump junkie without the Power to Contribute. - LSD - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: build.sysclasspath management
Stephen McConnell wrote: Stephen McConnell wrote: If you overload the property, you should use one of the supported values. "last" or even "none" seems to be what you want for Magic. I haven't located docs on this. Is there a url you can point me to? Don't worry - I've found it. Actually - no. The ant docs (1.6.1) say Property| Values | build.sysclasspath | "only", something else Is this an Ant 1.6.2 thing? Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: build.sysclasspath management
Stephen McConnell wrote: If you overload the property, you should use one of the supported values. "last" or even "none" seems to be what you want for Magic. I haven't located docs on this. Is there a url you can point me to? Don't worry - I've found it. Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: build.sysclasspath management
Stefan Bodewig wrote: On Fri, 09 Jul 2004, Stephen McConnell <[EMAIL PROTECTED]> wrote: Ant provides support for a system property "build.sysclasspath" which if set to "none" nitpick, "only" - not "none". ensures that the bootstrap classpath is used throughout the execution of an ant session. Clearly - the assumptions behind the "project == classpath" notion become an issue when dealing with a build system which provides artifact resolution. In this scenario the build system needs information about artifact locations. In effect it's my opinion that gump should be delegating the responsibility to the builder for classpath and classloader management. I'm not sure I follow you here. We'd also want to use the very latest of every plugin, so Gumo needs to build the plugins as well and as a consequence will know its location. Placing them all on a single classloader may not be nice, but will ensure the plugins can deal with the same set of libraries. I agree with you objective (and magic is supporting this). The issue comes down to the conflict of interest between the two following scenarios: (a) I stack the initial classloader with everything that is needed (plugins, lib, directories, etc.) in which case the system should work (b) I simulate the real runtime scenario by building classloader hierarchies and through integration testing validate not only the build integrity but also the integrity of runtime descriptors An example of the difference is that in scenario (b) I'm going to discover that a particular class has not been included in a deployment classloader because it was not referenced as a runtime dependency in whatever it is that is describing the deployment solution. But to discover this issue I need to be able to create the classloaders that simulate the deployment scenario. IMO - the real solution is to enable ant with repository based logic and instead of inhibiting ant classloader logic - focus instead on liberating ant such that classloaders can be created providing the jar references are uris to repository artifacts. Then link the repository handling within ant runtime with gump and your back in control. Add to this an ant -offline switch (backed with updates to ant's get task) and things are looking good. b) add a MagicBuilder which disables "build.sysclasspath" I prefer that. In the Maven context, build.sysclasspath is ignored as well and we rely on jar overrides to work. The biggest problems I see: * how to deal with plugins properly. Can I trust the plugins will do what I want? With custom tasks in Ant and the build sysclasspath setting I can ensure that no plugin ever gets a chance to use classes from any source that Gump doesn't control. A simple example was included in my earlier email. Magic makes a distinction between a "plugin" and a something like a ant . A plugin to Magic is a project with build, test and runtime dependencies that exports a definition of itself. The definition includes the declaration of the classloader in terms of artifact uris. A project that uses a plugin simply declares the plugin dependency and magic takes care of the construction of the classloader for the plugin by resolving artifact uris relative to its local repository. Its here that we intercept things and map the artifact to a gump generated jar file. * how do you deal with Magic build files that use snippets of "plain Ant"? No special handling. Just as maven users use jelly to supplement a build, magic uses ant. The main Magic benefit is the provision of a centralized version and dependency management framework within which there is more value to play within the rules than outside. Outside of the these two I have the feeling I'm getting into workarounds (things like overloading the property is not nice - and forking another java process seems like cludge). If you overload the property, you should use one of the supported values. "last" or even "none" seems to be what you want for Magic. I haven't located docs on this. Is there a url you can point me to? Cheers, Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: heresy - a controversial or unorthodox opinion or doctrine
Stefan Bodewig wrote: On Sat, 10 Jul 2004, Adam R. B. Jack <[EMAIL PROTECTED]> wrote: Nothing slightly heretic (unless you are talking about Ant religion not Gump religion). 8-) In my experience then Ant crew isn't as dogmatic as it gets colored sometimes, we tend to embrace heretics. Humor asside, the main issue I see is thar Magic uses Ant under the covers. Anybody using Magic in essence uses Ant. AFAIU I can mix the magic antlib with other Ant tasks freely. If I do so without setting build.sysclasspath "properly", those other tasks may end up using "bad" classpaths. But maybe I'm not understanding Magic completely. Your assumptions are correct. Magic is an antlib and anyone can customize build behavior by using pure ant directives. On the other-hand, the only reason someone will be using magic is to control over version management. So basically I agree - Magic is exposing a potential for abuse but at the same time it is very questionable why someone would invest time into setup and usage of magic with that in mind - ant's would be a much quicker solution. Magic users have two options when dealing with things like external tasks - they can include a reference to the jar in Magic's index.xml. The following example (taken from the Directory project) shows the usage of the antlr preprocessor as an external task: The important line in the above is: This is retrieving the location of the antlr from magic. Normally Magic will return the path relative to the centralized index (i.e. antlr/jars/antlr-2.7.2.jar). In the case of gump magic will ensure that the filename maps to the gump generated antlr. Magic also includes a "plugin" notion that allows association of multiple jars with a set of task definitions that are loaded into a separate classloader at build time. But the point remains - nothing is stopping someone from doing the following: Clearly this circumvents the benefits provided by gump and also goes against the first principals of magic. Hence our placeholder page: http://avalon.apache.org/central/tools/magic/spells/dark-arts.html Nothing there yet but this is where we will be documenting bad practices in our valiant efforts to hold back evil. Cheers, Steve. -- |---| | Magic by Merlin | | Production by Avalon | | | | http://avalon.apache.org | |---| - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: heresy - a controversial or unorthodox opinion or doctrine
Adam R. B. Jack wrote: 4) 5) Document change to the model - LSD - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: brutus may be having a problem
Adam R. B. Jack wrote: 2) Restore the config such that http://brutus.apache.org/gump/{flavour} goes to /usr/local/gump/{flavour}/results. done (for public, jdk15 and test, not any "flavour"). - LSD - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: build.sysclasspath management
On Fri, 09 Jul 2004, Stephen McConnell <[EMAIL PROTECTED]> wrote: > Ant provides support for a system property "build.sysclasspath" > which if set to "none" nitpick, "only" - not "none". > ensures that the bootstrap classpath is used throughout the > execution of an ant session. > Clearly - the assumptions behind the "project == classpath" notion > become an issue when dealing with a build system which provides > artifact resolution. In this scenario the build system needs > information about artifact locations. In effect it's my opinion > that gump should be delegating the responsibility to the builder for > classpath and classloader management. I'm not sure I follow you here. We'd also want to use the very latest of every plugin, so Gumo needs to build the plugins as well and as a consequence will know its location. Placing them all on a single classloader may not be nice, but will ensure the plugins can deal with the same set of libraries. >b) add a MagicBuilder which disables "build.sysclasspath" I prefer that. In the Maven context, build.sysclasspath is ignored as well and we rely on jar overrides to work. The biggest problems I see: * how to deal with plugins properly. Can I trust the plugins will do what I want? With custom tasks in Ant and the build sysclasspath setting I can ensure that no plugin ever gets a chance to use classes from any source that Gump doesn't control. * how do you deal with Magic build files that use snippets of "plain Ant"? > Outside of the these two I have the feeling I'm getting into > workarounds (things like overloading the property is not nice - and > forking another java process seems like cludge). If you overload the property, you should use one of the supported values. "last" or even "none" seems to be what you want for Magic. Stefan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: heresy - a controversial or unorthodox opinion or doctrine
On Sat, 10 Jul 2004, Adam R. B. Jack <[EMAIL PROTECTED]> wrote: > Nothing slightly heretic (unless you are talking about Ant religion > not Gump religion). 8-) In my experience then Ant crew isn't as dogmatic as it gets colored sometimes, we tend to embrace heretics. Humor asside, the main issue I see is thar Magic uses Ant under the covers. Anybody using Magic in essence uses Ant. AFAIU I can mix the magic antlib with other Ant tasks freely. If I do so without setting build.sysclasspath "properly", those other tasks may end up using "bad" classpaths. But maybe I'm not understanding Magic completely. Stefan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]