Can't use debugger with VS code Objectscript extension error: <COMMAND>zDebugStub+40^%Debugger.System.1
Every class on the server throws this same error when trying to run the debugger. I've already made sure I don't have the %SecureBreak role assigned which seems to typically fix this issue. Any advice on how to troubleshoot this would be greatly appreciated!
Error is : <COMMAND>zDebugStub+40^%Debugger.System.1
Comments
@Daniel Raderstrong
How are you running the debugger? What version of the vscode-objectscript extension do you have and what's the $ZV of your server?
Hi thanks for the quick reply! The extension appears to be V 3.6.0 and I'm clicking the debug hyperlink devspaces adds above each method.
$ZV:
IRIS for UNIX (Red Hat Enterprise Linux 8 for x86-64) 2022.1 (Build 209_0_22062U
) Fri Dec 9 2022 10:20:46 EST
Thanks for the information @Daniel.Raderstrong. Can you please run the troubleshooting steps found in the docs and post the contents of the trace global here? That will help me identify the cause of your issue.
Thanks! Does this help?
CHY0153D>ZW ^IRIS.Temp.Atelier
^IRIS.Temp.Atelier("debug")=1
^IRIS.Temp.Atelier("debug",2890455)=1
^IRIS.Temp.Atelier("debug",2890455,1,0)=50
^IRIS.Temp.Atelier("debug",2890455,1,1)="Event:init|<init appid=""AtelierDebugge
r"" idekey=""Atelier"" session=""2890455"" thread=""1"" pare
nt=""IRIS for UNIX (Red Hat Enterprise Linux 8 for x86-64) 2022.1 (Build 209_0_2
2062U) Fri Dec 9 2022 10:20:46 EST"" language=""COS"" protocol_version
=""1.0"" fileuri=""file://""> <engine version=""1.0"">%Atelier.XDebugAge
nt</engine> <company>InterSystems Corporation</company> <license>Copyright
2015 InterSystems Corporation</license> <url>http://www.intersystems.com</ur
l> <copyright>Copyright 2015 InterSystems Corporation</copyright></init>"
^IRIS.Temp.Atelier("debug",2890455,1,2)="Received:feature_set -i 1 -n max_data -
v 8192"
^IRIS.Temp.Atelier("debug",2890455,1,3)="Calling state feature_set"
^IRIS.Temp.Atelier("debug",2890455,1,4)="Event:feature_set|<response command='fe
ature_set' feature='max_data' success='1' transaction_id='1'/>"
^IRIS.Temp.Atelier("debug",2890455,1,5)="Received:feature_set -i 2 -n max_childr
en -v 32"
^IRIS.Temp.Atelier("debug",2890455,1,6)="Calling state feature_set"
^IRIS.Temp.Atelier("debug",2890455,1,7)="Event:feature_set|<response command='fe
ature_set' feature='max_children' success='1' transaction_id='2'/>"
^IRIS.Temp.Atelier("debug",2890455,1,8)="Received:feature_set -i 3 -n max_depth
-v 2"
^IRIS.Temp.Atelier("debug",2890455,1,9)="Calling state feature_set"
^IRIS.Temp.Atelier("debug",2890455,1,10)="Event:feature_set|<response command='f
eature_set' feature='max_depth' success='1' transaction_id='3'/>"
^IRIS.Temp.Atelier("debug",2890455,1,11)="Received:feature_set -i 4 -n notify_ok
-v 1"
^IRIS.Temp.Atelier("debug",2890455,1,12)="Calling state feature_set"
^IRIS.Temp.Atelier("debug",2890455,1,13)="Event:feature_set|<response command='f
eature_set' feature='notify_ok' success='1' transaction_id='4'/>"
^IRIS.Temp.Atelier("debug",2890455,1,14)="Received:feature_set -i 5 -n debug_tar
get -v_base64 Q0hZMDE1M0Q6IyNjbGFzcyhwcm9zdGhldGljLlByb3N0aGV0aWNSZXNvdXJjZVRlc3
QpLlJ1blRlc3RzKCk="
^IRIS.Temp.Atelier("debug",2890455,1,15)="Calling state feature_set"
^IRIS.Temp.Atelier("debug",2890455,1,16)="Launching: ##class(prosthetic.Prosthet
icResourceTest).RunTests()"
^IRIS.Temp.Atelier("debug",2890455,1,17)="PID 3245847"
^IRIS.Temp.Atelier("debug",2890455,1,18)="Debug Device Name:|TCP|41203"
^IRIS.Temp.Atelier("debug",2890455,1,19)="Event:feature_set|<response command='f
eature_set' feature='debug_target' success='1' transaction_id='5'/>"
^IRIS.Temp.Atelier("debug",2890455,1,20)="Received:breakpoint_list -i 6"
^IRIS.Temp.Atelier("debug",2890455,1,21)="Calling state breakpoint_list"
^IRIS.Temp.Atelier("debug",2890455,1,22)="Event:breakpoint_list|<response comman
d='breakpoint_list' transaction_id='6'></response>"
^IRIS.Temp.Atelier("debug",2890455,1,23)="Received:breakpoint_list -i 7"
^IRIS.Temp.Atelier("debug",2890455,1,24)="Calling state breakpoint_list"
^IRIS.Temp.Atelier("debug",2890455,1,25)="Event:breakpoint_list|<response comman
d='breakpoint_list' transaction_id='7'></response>"
^IRIS.Temp.Atelier("debug",2890455,1,26)="Received:breakpoint_set -i 8 -t line -
s enabled -f dbgp://|CHY0153D|prosthetic.service.llservice.validator.GetProsthet
icRequestsValidatorTest.cls -m ValidatePendingEyeglass -n 3"
^IRIS.Temp.Atelier("debug",2890455,1,27)="Calling state breakpoint_set"
^IRIS.Temp.Atelier("debug",2890455,1,28)="mapping: CHY0153D:prosthetic.service.l
lservice.validator.GetProstheticRequestsValidatorTest.cls:ValidatePendingEyeglas
s:3 -> prosthetic.service.llservice.validator.GetProstheticRequestsValidatorTest
.1:53"
^IRIS.Temp.Atelier("debug",2890455,1,29)="Setting BP"
^IRIS.Temp.Atelier("debug",2890455,1,30)="IsStopped"
^IRIS.Temp.Atelier("debug",2890455,1,31)="Location zDebugStub+37:%Debugger.Syste
m.1:0:0:0:0:6:0:0:0:0:0:CHY0153D"
^IRIS.Temp.Atelier("debug",2890455,1,32)="Stack 3^zDebugStub+37^%Debugger.System
.1"
^IRIS.Temp.Atelier("debug",2890455,1,33)="BP enabled:prosthetic.service.llservic
e.validator.GetProstheticRequestsValidatorTest.1(53)::0"
^IRIS.Temp.Atelier("debug",2890455,1,34)="Event:breakpoint_set|<response command
='breakpoint_set' transaction_id='8' state='enabled' id='1'/>"
^IRIS.Temp.Atelier("debug",2890455,1,35)="Received:run -i 9"
^IRIS.Temp.Atelier("debug",2890455,1,36)="Calling state run"
^IRIS.Temp.Atelier("debug",2890455,1,37)="output:"_$c(10)
^IRIS.Temp.Atelier("debug",2890455,1,38)="Event:stdout|<?xml version='1.0' encod
ing='UTF-8'?><stream type='stdout'>Cg==</stream>"
^IRIS.Temp.Atelier("debug",2890455,1,39)="output:"_$c(10)
^IRIS.Temp.Atelier("debug",2890455,1,40)="Event:stdout|<?xml version='1.0' encod
ing='UTF-8'?><stream type='stdout'>Cg==</stream>"
^IRIS.Temp.Atelier("debug",2890455,1,41)="output:<COMMAND>zDebugStub+40^%Debugge
r.System.1"_$c(10)
^IRIS.Temp.Atelier("debug",2890455,1,42)="Event:stdout|<?xml version='1.0' encod
ing='UTF-8'?><stream type='stdout'>PENPTU1BTkQ+ekRlYnVnU3R1Yis0MF4lRGVidWdnZXIuU
3lzdGVtLjEK</stream>"
^IRIS.Temp.Atelier("debug",2890455,1,43)="output:"_$c(10)
^IRIS.Temp.Atelier("debug",2890455,1,44)="Event:stdout|<?xml version='1.0' encod
ing='UTF-8'?><stream type='stdout'>Cg==</stream>"
^IRIS.Temp.Atelier("debug",2890455,1,45)="DbgIO <READ> $Id: //adhocs-iris/2022.1
.0.209.0/DEPARTMENT_OF_VETERANS_AFFAIRS_001/kernel/common/src/tpio.c#1 $ 2701 92
"
^IRIS.Temp.Atelier("debug",2890455,1,46)="IsStopped"
^IRIS.Temp.Atelier("debug",2890455,1,47)="Event:stop|<response command='run' sta
tus='stopped' reason='ok' transaction_id='9'/>"
^IRIS.Temp.Atelier("debug",2890455,1,48)="TidyUp: 1"
^IRIS.Temp.Atelier("debug",2890455,1,49)="Exiting"
^IRIS.Temp.Atelier("debug",2890455,1,50)="OnClose"
Yes, that is very helpful. The <COMMAND> error is coming from a line that calls "Do <debug_target>", which in this case is "##class(prosthetic.ProstheticResourceTest).RunTests()". Does running "Set a = "##class(prosthetic.ProstheticResourceTest).RunTests()" Do @a" work from the terminal in that namespace or do you see the same <COMMAND>?
It looks like that issue doesn't occur when running from terminal:
CHY0153D>Set a = "##class(prosthetic.ProstheticResourceTest).RunTests()"
CHY0153D>do @a
ProstheticResourceTest Successful
CHY0153D>
I tried to reproduce your issue with your exact server version and I couldn't get the error to occur. Do you remember when this started happening? Does debugging work when you connect to other instances?
Yes this has been working on other environments. I just double checked and code from a different server debugs successfully. It appears you're an Intersystems employee - if it'd be helpful I'm happy to hop on a call next week. Thanks for all the help this far!
Since this issue can't be reproduced by you on another server, or by me with a fresh install of your adhoc, I think it's highly unlikely that there's a product defect. I think this is an issue with that specific instance only. The WRC should be able to help you investigate this further.
Ok thank you I'll open a ticket with WRC. Appreciate the help!