[bug] Infinite re-cursion on VisualGST inspector

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

[bug] Infinite re-cursion on VisualGST inspector

Holger Hans Peter Freyther-3
Issue status update for
http://smalltalk.gnu.org/node/722
Post a follow up:
http://smalltalk.gnu.org/project/comments/add/722

 Project:      GNU Smalltalk
 Version:      <none>
 Component:    VisualGST
 Category:     bug reports
 Priority:     normal
 Assigned to:  Unassigned
 Reported by:  zecke
 Updated by:   zecke
 Status:       active

I'm loading some code (OsmoMGCP) with the STClassLoader and then using
VisualGST to inspect the code. I end up with an infinite crash
re-cursion like this:


(ip 10)ProxyNamespace>>#printOn:
(ip 20)ProxyNamespace(Object)>>#printString
(ip 44)UnhandledException>>#defaultAction
(ip 4)[] in Exception>>#resignalAsUnhandled:
(ip 42)MethodContext(ContextPart)>>#scanBacktraceFor:do:
(ip 36)MessageNotUnderstood(Exception)>>#resignalAsUnhandled:
(ip 8)MessageNotUnderstood(Exception)>>#defaultAction
(ip 2)[] in Exception>>#instantiateDefaultHandler
(ip 16)MessageNotUnderstood(Exception)>>#activateHandler:
(ip 24)MessageNotUnderstood(Exception)>>#signal
(ip 20)ProxyNamespace(Object)>>#doesNotUnderstand:
(ip 18)ProxyNamespace(BindingDictionary)>>#doesNotUnderstand:
(ip 10)ProxyNamespace>>#printOn:
(ip 20)ProxyNamespace(Object)>>#printString
(ip 44)UnhandledException>>#defaultAction
(ip 4)[] in UnhandledException>>#instantiateDefaultHandler
(ip 16)UnhandledException(Exception)>>#activateHandler:
(ip 24)MessageNotUnderstood(Exception)>>#resignalAs:
(ip 40)MessageNotUnderstood(Exception)>>#resignalAsUnhandled:
(ip 8)MessageNotUnderstood(Exception)>>#defaultAction
(ip 2)[] in Exception>>#instantiateDefaultHandler
(ip 16)MessageNotUnderstood(Exception)>>#activateHandler:
(ip 24)MessageNotUnderstood(Exception)>>#signal
(ip 20)ProxyNamespace(Object)>>#doesNotUnderstand:
(ip 18)ProxyNamespace(BindingDictionary)>>#doesNotUnderstand:
(ip 10)ProxyNamespace>>#printOn:
(ip 8)WriteStream(Stream)>>#print:
(ip 16)[] in Dictionary>>#printOn:
(ip 32)IdentityDictionary(LookupTable)>>#keysAndValuesDo:
(ip 26)IdentityDictionary(Dictionary)>>#printOn:
(ip 8)IdentityDictionary(Object)>>#displayOn:
(ip 18)IdentityDictionary(Object)>>#displayString
(ip 20)GtkInspectorWidget>>#onVariableChanged
(ip 0)




_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk
Reply | Threaded
Open this post in threaded view
|

Re: [bug] Infinite re-cursion on VisualGST inspector

Holger Hans Peter Freyther-3
Issue status update for
http://smalltalk.gnu.org/project/issue/722
Post a follow up:
http://smalltalk.gnu.org/project/comments/add/722

 Project:      GNU Smalltalk
 Version:      <none>
 Component:    VisualGST
 Category:     bug reports
 Priority:     normal
 Assigned to:  Unassigned
 Reported by:  zecke
 Updated by:   zecke
 Status:       active


PackageLoader fileInPackage: #Parser.
p := STInST.STClassLoaderObjects.ProxyNamespace on: Smalltalk for:
STInST.STClassLoader new


is reproducing the issue. Changing the classNameString to class
storeString is fixing the specific issue but it will end up with a
infinite recursion.

1.) Should VisualGSTs inspector use [] on: do: [:e | widget text:
'<Error..>'] for getting the displayString?

2.) During development it would be nice if VisualGST could limit the
stack depth of a process...

3.) With making VisualGST more async one could use some kind of a future
that would fork for the displayString request and come back once there
is the result. This would not block the mainUI.

4.) How to fix the actual error here? The ProxyNamespace is initialized
to contain itself.. so printing it will list itself... which will print
itself.. which will print itself..



_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk
Reply | Threaded
Open this post in threaded view
|

Re: [bug] Infinite re-cursion on VisualGST inspector

Holger Hans Peter Freyther-3
In reply to this post by Holger Hans Peter Freyther-3
Issue status update for
http://smalltalk.gnu.org/project/issue/722
Post a follow up:
http://smalltalk.gnu.org/project/comments/add/722

 Project:      GNU Smalltalk
 Version:      <none>
 Component:    VisualGST
 Category:     bug reports
 Priority:     normal
 Assigned to:  Unassigned
 Reported by:  zecke
 Updated by:   zecke
 Status:       active


printOn: aStream
   "Print a representation of the receiver on aStream"
   aStream nextPutAll: self class storeString , '[', proxy name, '] (' ;
nl.
   self myKeysAndValuesDo:
       [ :key :value | aStream tab;
                  print: key;
                  nextPutAll: '->';
                  print: value;
                  nl ].  
   aStream nextPut: $)
!



is the fixed but still broken code. I addded a self == value ifFalse:
[].. but this results in having nothing printed at all. I am not sure if
that is the correct output.



_______________________________________________
help-smalltalk mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-smalltalk