Skip to content

Commit

Permalink
Merge pull request #256 from dalehenrich/dev
Browse files Browse the repository at this point in the history
Minimal tODE debugger
  • Loading branch information
dalehenrich committed Apr 30, 2016
2 parents 6fefdb2 + 2712647 commit 65f887c
Show file tree
Hide file tree
Showing 233 changed files with 1,463 additions and 40 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Expand Up @@ -24,6 +24,8 @@ matrix:
- smalltalk_config: .minimal.smalltalk.ston
smalltalk: GemStone-3.3.0
env: GSCI_CLIENTS="Pharo-5.0" GSCI_DEVKIT_BRANCH="dev"
allow-failures:
- os: osx

cache:
directories:
Expand Down
Expand Up @@ -105,11 +105,13 @@ baseline: spec
spec
package: 'Tode-Minimal-Client-Core'
with: [ spec requires: #('Topez-Common-Core' 'GemStoneGCI') ];
package: 'Tode-Minimal-Client-Debugger'
with: [ spec requires: 'Tode-Minimal-Client-Core'];
package: 'Tode-Minimal-Client-Tests'
with: [ spec requires: 'Tode-Minimal-Client-Core' ];
yourself.
spec
group: 'Minimal Client' with: #('Tode-Minimal-Client-Core');
group: 'Minimal Client' with: #('Tode-Minimal-Client-Core' 'Tode-Minimal-Client-Debugger');
group: 'Minimal Tests'
with: #('Topez-Common-Tests' 'Tode-Minimal-Client-Tests');
yourself ].
Expand Down
Expand Up @@ -2,7 +2,7 @@
"class" : {
},
"instance" : {
"baseline:" : "dkh 04/20/2016 12:05",
"baseline:" : "dkh 4/23/2016 20:08",
"initializeTools" : "dkh 06/06/2013 11:59",
"pharo30InstallFullTodeClient" : "dkh 12/01/2015 11:54",
"pharo30InstallTodeClient" : "dkh 10/10/2015 16:36" } }
@@ -1 +1 @@
SystemOrganization addCategory: #'BaselineOfTode'!
SystemOrganization addCategory: #BaselineOfTode!
2 changes: 1 addition & 1 deletion repository/BaselineOfTode.package/monticello.meta/version

Large diffs are not rendered by default.

@@ -0,0 +1,5 @@
*Tode-Minimal-Client-Core
asOopType: anOop
"Compatbility with old version of Gci API"

^ GsGciOopType fromInteger: anOop
@@ -0,0 +1,5 @@
{
"class" : {
},
"instance" : {
"asOopType:" : "dkh 4/20/2016 19:45" } }
@@ -0,0 +1,2 @@
{
"name" : "GsGciSession" }
Empty file.
@@ -0,0 +1,3 @@
private
gemStoneErrorNumber
^ 2318
@@ -0,0 +1,12 @@
initialization
initialize
"self initialize"

GsGci32xErrSType errorToExceptionMap
at: 6002 put: self;
"Breakpoint"
at: 6005 put: self;
"Code Breakpoint"
at: 6006 put: self;
"Stack Breakpoint"
yourself
@@ -0,0 +1,6 @@
{
"class" : {
"gemStoneErrorNumber" : "dkh 4/27/2016 16:23",
"initialize" : "dkh 4/27/2016 16:25" },
"instance" : {
} }
@@ -0,0 +1,14 @@
{
"category" : "Tode-Minimal-Client-Core",
"classinstvars" : [
],
"classvars" : [
],
"commentStamp" : "",
"instvars" : [
],
"name" : "TDBreakpointNotification",
"pools" : [
],
"super" : "TDRuntimeNotification",
"type" : "normal" }
@@ -1,3 +1,3 @@
private
gemStoneErrorNumber
^ 2318
^ 2709
@@ -1,6 +1,6 @@
{
"class" : {
"gemStoneErrorNumber" : "dkh 4/19/2016 15:17",
"gemStoneErrorNumber" : "dkh 4/27/2016 16:26",
"initialize" : "dkh 4/19/2016 15:16" },
"instance" : {
} }
Expand Up @@ -13,4 +13,7 @@ clientApiVersion

"1.2.1 - add authorId instance variable to TDSessionDescription --- not used on the server so far"

^ '1.2.1' asMetacelloVersionNumber
"1.3.0 - debugger uses #closeWith: callback when dbContinue runs off the end,
server-side effectiveApiVersion"

^ '1.3.0' asMetacelloVersionNumber
@@ -1,4 +1,6 @@
exception handling
debuggerRequested: returnValue
self session send: #openDebugger to: self todeServerOopType.
^ returnValue
[ self session send: #openDebugger to: self todeServerOopType.
^ returnValue ]
on: TDMinimalDebuggerContinueFromDebuggerNotification
do: [ :ex | ^ ex returnValue ]
@@ -0,0 +1,27 @@
debugging
handleDebugExceptionsDuring: aBlock
"if you make changes here (like adding new return values), see TDDebugTool>>debugExceptionSymbols"

| result |
[ result := aBlock value ]
on: TDBreakpointNotification , TDHaltNotification , TDErrorNotification
do: [ :ex |
| errorNumber |
(ex isKindOf: TDErrorNotification)
ifTrue: [ ^ #error ].
"error occurred during execution"
errorNumber := ex errorNumber.
errorNumber = 6002
ifTrue: [ ^ #singleStep ].
"single step breakpoint ... as expected"
errorNumber = 6005
ifTrue: [ ^ #breakpoint ].
"method breakpoint"
errorNumber = 2709
ifTrue: [ ^ #halt ].
"halt occurred during execution"
errorNumber = 6006
ifTrue: [ ^ #blockOrMethodReturn ].
"return from method or block breakpoint ... as expected"
self error: 'another breakpoint error number?' ].
^ result
Expand Up @@ -37,4 +37,9 @@ loginWith: aSessionDescription
authorId := self sessionDescription authorId.
authorId isEmpty
ifTrue: [ authorId := Author fullName ].
self session send: #authorInitials: to: todeServerOopType withArgs: {authorId}
self session send: #authorInitials: to: todeServerOopType withArgs: {authorId}.
self effectiveApiVersion >= '1.3.0' asMetacelloVersionNumber
ifTrue: [ self session
send: #effectiveApiVersion:
to: todeServerOopType
withArgs: {self effectiveApiVersion asString} ]
Expand Up @@ -4,24 +4,25 @@
"debugMode:" : "dkh 4/19/2016 06:39",
"loginWith:" : "dkh 4/15/2016 21:00" },
"instance" : {
"clientApiVersion" : "dkh 4/16/2016 19:41",
"clientApiVersion" : "dkh 4/29/2016 20:03",
"debugMode" : "dkh 4/19/2016 06:38",
"debugMode:" : "dkh 4/19/2016 06:39",
"debuggerRequested:" : "dkh 4/19/2016 15:59",
"debuggerRequested:" : "dkh 4/30/2016 07:58",
"defaultSessionDescription" : "dkh 4/16/2016 19:48",
"doesNotUnderstand:" : "dkh 4/19/2016 11:18",
"effectiveApiVersion" : "dkh 4/16/2016 19:42",
"effectiveApiVersion:" : "dkh 4/16/2016 19:43",
"evaluate:" : "dkh 4/19/2016 09:20",
"evaluateCommand:" : "dkh 4/19/2016 10:07",
"evaluateCommand:" : "dkh 4/29/2016 18:33",
"evaluateFrom:" : "dkh 4/19/2016 06:36",
"exception:context:" : "dkh 4/19/2016 15:46",
"executeRestoreFromBackupFromClient:" : "dkh 4/19/2016 11:57",
"getSessionDescription" : "dkh 4/19/2016 05:59",
"handleDebugExceptionsDuring:" : "dkh 4/28/2016 11:44",
"interactive" : "dkh 4/19/2016 20:06",
"interactive:" : "dkh 4/19/2016 20:04",
"logStackRequested:" : "dkh 4/19/2016 15:59",
"loginWith:" : "dkh 4/19/2016 15:41",
"loginWith:" : "dkh 4/29/2016 20:08",
"logout" : "dkh 4/19/2016 09:45",
"objectSerializer" : "dkh 4/16/2016 19:26",
"objectSerializer:" : "dkh 4/16/2016 19:39",
Expand Down
@@ -0,0 +1,3 @@
accessing
errorNumber
^ self gci32xErrSType number
Expand Up @@ -7,6 +7,7 @@
"convertTDEvaluateTokenResponseToText:" : "dkh 4/19/2016 17:05",
"defaultAction" : "dkh 4/19/2016 20:07",
"description" : "dkh 4/19/2016 15:28",
"errorNumber" : "dkh 4/27/2016 16:31",
"exceptionOopType" : "dkh 4/19/2016 15:43",
"gci32xErrSType" : "dkh 4/19/2016 15:22",
"gci32xErrSType:" : "dkh 4/19/2016 15:22",
Expand Down
@@ -1 +1 @@
(name 'Tode-Minimal-Client-Core-dkh.10' message '#253 add interactive attribute to minimal client default value answers whether or not the vm is headless, but it can be switched for testing ... modify tests to use interactive ... logStack, halt, and proceed tested now ...' id '512ddbc0-4fe5-47a6-a270-dd9dd18dbcf6' date '19 April 2016' time '8:54:40.76107 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.9' message '#253 gearing up for testing the code paths used for debugging ... more test coverage needed for #logStack and address failing test' id '2902180b-7c2d-4770-9ed5-25b81640375a' date '19 April 2016' time '5:19:21.999055 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.8' message '#253 defer some of the call back tests for later ' id 'be8f8e9a-8e1c-43f6-bcd3-a94b279d7161' date '19 April 2016' time '3:02:23.760295 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.7' message 'implement GsInteraction tests' id '137c6d90-c6ee-421c-8deb-1f6fbe42cb98' date '19 April 2016' time '2:49:10.986355 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.6' message '#253 implement services registry (for server callbacks) in minimal client' id 'e0c3c402-a9c1-4d7b-894e-baf1f655ada8' date '19 April 2016' time '11:33:35.066967 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.5' message '#253 tode command line execution is functional' id '22b068ae-b4b9-4cdd-928f-983733b3d00f' date '19 April 2016' time '10:16:53.881356 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.4' message '#253 implementing TDMinimalClient>>evaluate: which takes a tODE command and executes it ...' id '465a0c1c-f91f-49ee-88cf-da95c3eadf1f' date '19 April 2016' time '6:57:42.543698 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.3' message 'minimal tode client login functional!' id '72ddd092-155e-4988-b8c5-4879fed2b963' date '19 April 2016' time '6:00:35.970673 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.2' message '#253 TDMinimalClient>>loginWith: is working up until the clientForwarder send ... which is pretty good' id 'fb43446c-66d5-4e33-8f32-2fe1f61294b7' date '16 April 2016' time '8:14:01.400538 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.1' message '#253 start work on minimal client implementation ... dependent upong GsDevKit/GsDevKit_home#103 as well' id '04a9011f-075f-4a0c-9874-a9e2cf894f58' date '16 April 2016' time '11:40:28.303675 am' author 'dkh' ancestors () stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())
(name 'Tode-Minimal-Client-Core-dkh.21' message '#253 fix up behavior when debugger opened ..' id 'f81be88b-d832-4981-a808-78327374fa77' date '30 April 2016' time '8:02:21.419927 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.20' message '#253 tweak logic using effectiveApiVersion' id '657dd889-c069-4859-8765-2714b314289e' date '29 April 2016' time '8:11:44.836743 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.19' message '#253 update clientApiVersion comment' id '28b8048b-642a-4fb2-8218-be003b0c5a06' date '29 April 2016' time '8:04:25.10926 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.18' message '#253 communicate effectiveApi version to server during login' id 'fc779657-47c6-41ea-9de4-c2f9742cc867' date '29 April 2016' time '7:51:08.108213 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.17' message '#253 bump clientVersion to 1.3.0 indicating support for #closeWith: callback' id '9679a191-dddb-4527-adb7-1d442ba875ce' date '29 April 2016' time '7:29:52.09735 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.16' message '#253 bump clientVersion to 1.3.0 indicating support for #closeWith: callback' id '284fcb0a-63ed-448a-ba36-e0bf7eab4b5f' date '29 April 2016' time '7:28:00.417351 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.15' message '#253 bump clientVersion to 1.2.2 indicating support for #closeWith: callback' id '7bace0fc-9015-43d6-ab18-e1f2aa8355a3' date '29 April 2016' time '7:24:00.978572 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.14' message '#253 resume from within debugger will return control to original client process at point that debugger was opened with appropriate result from server ...' id '46212a20-6a71-453a-a56d-17edfb68d2cd' date '29 April 2016' time '6:38:33.871247 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.13' message '#253 step over is functional, but the gui update is not ..' id '49fcebd9-0b30-4124-86c9-dac9d617a72b' date '28 April 2016' time '12:52:24.85588 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.12' message '#253 working on getting the step menu item to work' id '134b6b3e-41a7-4ebb-8853-800406556c69' date '27 April 2016' time '5:43:33.699018 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.11' message '#253 create testClientListElementMenus to illustrate menu handling ... add #asOopType: for backward compatibility with old GCI api' id '9f2f57a4-ec49-47fb-a084-5e27c44a0d40' date '20 April 2016' time '8:36:01.938484 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.10' message '#253 add interactive attribute to minimal client default value answers whether or not the vm is headless, but it can be switched for testing ... modify tests to use interactive ... logStack, halt, and proceed tested now ...' id '512ddbc0-4fe5-47a6-a270-dd9dd18dbcf6' date '19 April 2016' time '8:54:40.76107 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.9' message '#253 gearing up for testing the code paths used for debugging ... more test coverage needed for #logStack and address failing test' id '2902180b-7c2d-4770-9ed5-25b81640375a' date '19 April 2016' time '5:19:21.999055 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.8' message '#253 defer some of the call back tests for later ' id 'be8f8e9a-8e1c-43f6-bcd3-a94b279d7161' date '19 April 2016' time '3:02:23.760295 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.7' message 'implement GsInteraction tests' id '137c6d90-c6ee-421c-8deb-1f6fbe42cb98' date '19 April 2016' time '2:49:10.986355 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.6' message '#253 implement services registry (for server callbacks) in minimal client' id 'e0c3c402-a9c1-4d7b-894e-baf1f655ada8' date '19 April 2016' time '11:33:35.066967 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.5' message '#253 tode command line execution is functional' id '22b068ae-b4b9-4cdd-928f-983733b3d00f' date '19 April 2016' time '10:16:53.881356 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.4' message '#253 implementing TDMinimalClient>>evaluate: which takes a tODE command and executes it ...' id '465a0c1c-f91f-49ee-88cf-da95c3eadf1f' date '19 April 2016' time '6:57:42.543698 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.3' message 'minimal tode client login functional!' id '72ddd092-155e-4988-b8c5-4879fed2b963' date '19 April 2016' time '6:00:35.970673 am' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.2' message '#253 TDMinimalClient>>loginWith: is working up until the clientForwarder send ... which is pretty good' id 'fb43446c-66d5-4e33-8f32-2fe1f61294b7' date '16 April 2016' time '8:14:01.400538 pm' author 'dkh' ancestors ((name 'Tode-Minimal-Client-Core-dkh.1' message '#253 start work on minimal client implementation ... dependent upong GsDevKit/GsDevKit_home#103 as well' id '04a9011f-075f-4a0c-9874-a9e2cf894f58' date '16 April 2016' time '11:40:28.303675 am' author 'dkh' ancestors () stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())) stepChildren ())
4 changes: 4 additions & 0 deletions repository/Tode-Minimal-Client-Debugger.package/.filetree
@@ -0,0 +1,4 @@
{
"noMethodMetaData" : true,
"separateMethodMetaAndSource" : false,
"useCypressPropertiesFile" : true }
@@ -0,0 +1,3 @@
*Tode-Minimal-Client-Debugger
minimalTodeMethod
^ self custom: TDMinimalTodeMethodPresentation new
@@ -0,0 +1,5 @@
{
"class" : {
},
"instance" : {
"minimalTodeMethod" : "dkh 4/25/2016 15:33" } }
@@ -0,0 +1,2 @@
{
"name" : "GLMCompositePresentation" }
@@ -0,0 +1,3 @@
*Tode-Minimal-Client-Debugger
renderMinimalTodeMethodPresentation: aSmalltalkMethodPresentation
^ TDMorphicMinimalTodeMethodRenderer render: aSmalltalkMethodPresentation from: self
@@ -0,0 +1,5 @@
{
"class" : {
},
"instance" : {
"renderMinimalTodeMethodPresentation:" : "dkh 4/29/2016 10:29" } }
@@ -0,0 +1,2 @@
{
"name" : "GLMMorphicRenderer" }
@@ -0,0 +1,3 @@
*Tode-Minimal-Client-Debugger
gtConstructMinimalTodeDebuggerInspectorIn: composite for: aDebugger
^ self gtConstructDebuggerInspectorIn: composite for: aDebugger
@@ -0,0 +1,5 @@
{
"class" : {
},
"instance" : {
"gtConstructMinimalTodeDebuggerInspectorIn:for:" : "dkh 4/24/2016 18:24" } }
@@ -0,0 +1,2 @@
{
"name" : "Object" }
Empty file.

0 comments on commit 65f887c

Please sign in to comment.