David T. Lewis uploaded a new version of ReleaseBuilder to project The Inbox:
http://source.squeak.org/inbox/ReleaseBuilder-dtl.198.mcz ==================== Summary ==================== Name: ReleaseBuilder-dtl.198 Author: dtl Time: 18 September 2019, 10:37:49.461592 pm UUID: 93409652-4167-4790-a02a-ec5e54f2c036 Ancestors: ReleaseBuilder-mt.197 When preparing a new release image, arrange for the home Morphic project to have a parent MVC project. The MVC project supports emergency debugging in the event of unrecoverable Morphic problems, and will fall back on the traditional emergency evaluator if MVC debugging fails. =============== Diff against ReleaseBuilder-mt.197 =============== Item was added: + ----- Method: ReleaseBuilder class>>addMVCParentProject (in category 'scripts - support') ----- + addMVCParentProject + "The home project is a single Morphic project. Let the home project have a + parent MVC project as the root of the project tree. The MVC project supports + emergency debugging in the event of unrecoverable Morphic problems, and + will fall back on the traditional emergency evaluator if MVC debugging fails. + If MVC is not installed in the image, then do nothing." + + (Smalltalk hasClassNamed:#MVCProject) ifTrue: [ | cls | + cls := Smalltalk classNamed: #MVCProject. + ((Project topProject) perform: #isMVC) + ifFalse: [(cls new name: 'The root project') beTopProject ] ]. + ! Item was changed: ----- Method: ReleaseBuilder class>>checkCurrentProjects (in category 'scripts - support') ----- checkCurrentProjects Project current isMorphic ifFalse: [ Warning signal: 'The current project is not Morphic. Please create a new Morphic project, enter it, and restart the release building process.']. + Project allProjects size + caseOf: { + [ 1 ] -> [ self addMVCParentProject ] . + [ 2 ] -> [ ((Project current parent) perform: #isMVC) ifFalse: [ Warning signal: 'Parent of the home project should be an MVC project.' ] ] } + otherwise: [ Warning signal: 'There should be one home Morphic project with a parent MVC project for fallback debugging.' ] . - Project allProjects size = 1 ifFalse: [ - Warning signal: 'There should only be one project.']. "Avoid strange drawing issues." Project current world allMorphsDo: [:m | m removeProperty: #errorOnDraw].! |
The idea here is to let an MVC project be the parent of the active Morphic
project like this: Project topProject isMVC ifFalse: [ (MVCProject new name: 'The root project') beTopProject ] Thus an unrecoverable error in Morphic will first drop into an MVC debugger before giving up and falling back on the emergency evaluator. Dave On Thu, Sep 19, 2019 at 02:37:50AM +0000, [hidden email] wrote: > David T. Lewis uploaded a new version of ReleaseBuilder to project The Inbox: > http://source.squeak.org/inbox/ReleaseBuilder-dtl.198.mcz > > ==================== Summary ==================== > > Name: ReleaseBuilder-dtl.198 > Author: dtl > Time: 18 September 2019, 10:37:49.461592 pm > UUID: 93409652-4167-4790-a02a-ec5e54f2c036 > Ancestors: ReleaseBuilder-mt.197 > > When preparing a new release image, arrange for the home Morphic project to have a parent MVC project. The MVC project supports emergency debugging in the event of unrecoverable Morphic problems, and will fall back on the traditional emergency evaluator if MVC debugging fails. > > =============== Diff against ReleaseBuilder-mt.197 =============== > > Item was added: > + ----- Method: ReleaseBuilder class>>addMVCParentProject (in category 'scripts - support') ----- > + addMVCParentProject > + "The home project is a single Morphic project. Let the home project have a > + parent MVC project as the root of the project tree. The MVC project supports > + emergency debugging in the event of unrecoverable Morphic problems, and > + will fall back on the traditional emergency evaluator if MVC debugging fails. > + If MVC is not installed in the image, then do nothing." > + > + (Smalltalk hasClassNamed:#MVCProject) ifTrue: [ | cls | > + cls := Smalltalk classNamed: #MVCProject. > + ((Project topProject) perform: #isMVC) > + ifFalse: [(cls new name: 'The root project') beTopProject ] ]. > + ! > > Item was changed: > ----- Method: ReleaseBuilder class>>checkCurrentProjects (in category 'scripts - support') ----- > checkCurrentProjects > > Project current isMorphic ifFalse: [ > Warning signal: 'The current project is not Morphic. Please create a new Morphic project, enter it, and restart the release building process.']. > > + Project allProjects size > + caseOf: { > + [ 1 ] -> [ self addMVCParentProject ] . > + [ 2 ] -> [ ((Project current parent) perform: #isMVC) ifFalse: [ Warning signal: 'Parent of the home project should be an MVC project.' ] ] } > + otherwise: [ Warning signal: 'There should be one home Morphic project with a parent MVC project for fallback debugging.' ] . > - Project allProjects size = 1 ifFalse: [ > - Warning signal: 'There should only be one project.']. > > "Avoid strange drawing issues." > Project current world allMorphsDo: [:m | m removeProperty: #errorOnDraw].! > > |
That's a good idea. I still have to figure out, why some debuggers tend to not appear correctly in MVC in this situation. Best, Marcel
|
Free forum by Nabble | Edit this page |