[Bug] RuntimePackager error with Aragon.Widgets

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[Bug] RuntimePackager error with Aragon.Widgets

Christian Haider
Nachricht
Hi,
 
with 7.4 the Runtime Packager runs into an error with Aragon Widgets when it tries to remove unreferenced Globals. This did not happen in 7.3.1.
 
This is what happens:
Aragon.Widgets adds Shared Variables for its widget spec classes to the namespace Smalltalk (which rational I do not really understand...). In my case the TreeViewSpec is not used and the packager adds the shared variable to the unreferenced globals to be removed.
When stripping, it first deletes unused classes. Among it the class AragonSpecsInstaller which in turn removes the shadowing shared variables for the widget specs from namespace Smalltalk in its #obsolete method.
Then, the packager wants to remove the unreferenced globals and gives an error on Smalltalk.TreeViewSpec, since it is already removed.
 
Possible solutions:
personally I would like to get rid of the load/unload behavior of Aragon.Widgets of shadowing the widget specs. Unfortunately, I dont understand why it was put in there in the first place, so this might break things... Also this would require users of the package to change their code to correctly reference Aragon.<widget>Spec instead of UI.<widget>Spec or just <widget>Spec.
 
The other solution would be to make the packager more robust against the removal of globals outside the scope of the packager. The method SystemUtils class>>removeName:from: throws an exception (unfortunately just a general Error) when a namespace does not include the name to be removed. This is the error stopping the packager. This could be gracefully handled in RuntimeManagerStripper class>>discardUnreferencedMethodsClassesAndGlobals:.
 
cheers,
    Christian
Reply | Threaded
Open this post in threaded view
|

Re: [Bug] RuntimePackager error with Aragon.Widgets

Alan Knight-2
Thanks. I've created AR 50470 for this.

At 02:07 PM 3/5/2006, Christian Haider wrote:
Hi,
 
with 7.4 the Runtime Packager runs into an error with Aragon Widgets when it tries to remove unreferenced Globals. This did not happen in 7.3.1.
 
This is what happens:
Aragon.Widgets adds Shared Variables for its widget spec classes to the namespace Smalltalk (which rational I do not really understand...). In my case the TreeViewSpec is not used and the packager adds the shared variable to the unreferenced globals to be removed.
When stripping, it first deletes unused classes. Among it the class AragonSpecsInstaller which in turn removes the shadowing shared variables for the widget specs from namespace Smalltalk in its #obsolete method.
Then, the packager wants to remove the unreferenced globals and gives an error on Smalltalk.TreeViewSpec, since it is already removed.
 
Possible solutions:
personally I would like to get rid of the load/unload behavior of Aragon.Widgets of shadowing the widget specs. Unfortunately, I dont understand why it was put in there in the first place, so this might break things... Also this would require users of the package to change their code to correctly reference Aragon.<widget>Spec instead of UI.<widget>Spec or just <widget>Spec.
 
The other solution would be to make the packager more robust against the removal of globals outside the scope of the packager. The method SystemUtils class>>removeName:from: throws an exception (unfortunately just a general Error) when a namespace does not include the name to be removed. This is the error stopping the packager. This could be gracefully handled in RuntimeManagerStripper class>>discardUnreferencedMethodsClassesAndGlobals:.
 
cheers,
    Christian

--
Alan Knight [|], Cincom Smalltalk Development

"The Static Typing Philosophy: Make it fast. Make it right. Make it run." - Niall Ross