Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Michael Reitsma Date:26 Jun 2007 09:23 AM
Hi,
I am trying to debug an xslt used with the Saxon processor.
However it doesn't step into the debugger.
The debugger itself sort-of-works: if i have a long running xslt and i have enough time i can pause the xslt and then do Step (F11).
However F5 to have it stop at a breakpoint just causes the xslt to run to the end as if there were no breakpoints set.
Also the variables window and watch is empty.
I searched for something like this in the release notes but could not find something.
I did find something similar in the SS fora dated about 2005. http://www.stylusstudio.com/SSDN/default.asp?action=9&read=3972&fid=23
The solution presented there was tested but to no avail unfortunately.
Is this a known bug ?
I have to use Saxon because i am using XPath 2.0 stuff (group-by and date)
I tested with the smallest xslt possible as well ( just hit File/new/xslt stylesheet and put something like xsl:for each select after the template match line).
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:27 Jun 2007 12:17 PM
Hi Michael,
we have recently discovered that the Watch and Variables windows can be empty if global variables are used, and we are working on that. Can you tell us more about the issues with breakpoints? If you have a testcase that always shows the problem, could you send it to us to the address stylus-field-report@progress.com?
is converted into "create a root node and clone it X times", so the breakpoint on the node creation is hit just once.
If you write something non-optimizable, like
Also, my JVM is "1.6.0_01-b06 Java HotSpot(TM) Client VM Sun Microsystems Inc."
I can place a breakpoint in the for-each line, hit F5 and when the debugger stops I can press F10 multiple times, with the cursor moving to the <root> and <value-of> lines for each node (the Variables window shows the context as /main/DATA_RECORD[1]/MODULE, then /main/DATA_RECORD[2]/MODULE and so on).
If I place the breakpoint on the <root> line and press F5 debugging stops at that line, and pressing F5 makes it continue and stop again at the same line.
Do you see the same behavior when doing the same things? If not, can you check which JVM are you using?
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Michael Reitsma Date:29 Jun 2007 04:35 AM
Hi,
i have exactly the same JVM as you and tested the same xslt.
But i can not do these things you mention.
It doesn't enter the debugger....
I tried switching of the virusscanner, since it monitors ports for http traffic and switching the winxp firewall.
Both actions did not help here.
Is there some kind of debugging mode of SS or Saxon so that i can see in some kind of of log what is communicated between Saxon and SS ?
As said before, i can halt and step manually, but it doesn't stop automatically at any breakpoint.
When you use small files or a fast machine you do not have enough time to see anything happening ofcourse .....
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:29 Jun 2007 06:21 AM
Hi Michael,
just to be on the same page, on which line(s) are you placing the breakpoint? Have you tried placing a breakpoint on every line, just to be sure that at least some work?
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Michael Reitsma Date:29 Jun 2007 06:33 AM
Hi,
Jep we are on the same page...
I tried it with every line and ofcourse with the built-in debugger.
that one works....
i have built xslt's before with SS and the debug stuff is what i like the most about it.
But now i am using the Saxon parser and that is giving me these debug problems.
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:29 Jun 2007 07:39 AM
Hi Michael,
can you trying setting the value for "XSLT Editor: PrintDebugMessages" to 1 in the key HKEY_CURRENT_USER\Software\Stylus Studio\2007 XML Enterprise Suite Release 2\Plugin Settings and tell us if the output window of Stylus reports messages like "BP: on line XX"?
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Michael Reitsma Date:29 Jun 2007 10:50 AM
Hi,
i tried it and when i have a breakpoint and just do F5 (it should stop then at the breakpoint, i have set multiple..) it just continues to the end as mentioned before and nothing appears in the output window.
But when i press the pause button fast enough and have it halt somewhere in the xslt, as mentioned before, the output window shows
"bp: on line xx " where xx is the line where the yellow arrow is at the time of pausing.
Note that this is not the linenumber with the breakpoint that was set earlier(red dot).
Subject:Re: Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:29 Jun 2007 11:11 AM
Hi Michael,
try doing the following:
- go to the text view
- set the breakpoint you need
- press Ctrl-B; it will show a dialog with all the breakpoints
defined in the project. At this point it's possible the list is empty
- dismiss the dialog
- switch to the mapper view
- switch back to text view
- press again Ctrl-B; verify that the breakpoints are now listed
- start debugging and verify if those breakpoints get hit
Subject:Re: Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:10 Oct 2007 08:45 AM
Hi Kevin,
the issue with the 'watch' and 'variable' windows has been fixed in the last update of Stylus, bl894m.
As for the Saxon debugging, can you try moving your XSLT file to a location that uses only 8.3 short names?
Subject:Re: Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Kevin Leung Date:10 Oct 2007 11:08 PM
Hi Alberto,
Thanks. Seems the breakpoint works fine with me now. But I still have problem with the watch and variable.
1. The Variables Table show MOSTLY global variables.
2. Some global variables show "<Symbol unknown>" even it is already being referenced in the XSLT. When I step through the XSLT.
3. Some local variables can be shown in the Variables Table, some cannot. I couldn't identify why. Was suspecting I need to specify the type in the XSLT but finally found it is not the case.
4. For the Watch Table, it can shows the value normally if the variable show normally in the Variable Table.
Hope this can help you to identify and fix the problem and make SS as a useful tool when I work on XSLT 2.0. Thanks.
Subject:Re: Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:(Deleted User) Date:11 Oct 2007 09:39 AM
Hi Kevin,
>1. The Variables Table show MOSTLY global variables.
>2. Some global variables show "<Symbol unknown>" even
>it is already being referenced in the XSLT. When I step
>through the XSLT.
Could you post a sample stylesheet that shows this behavior?
>3. Some local variables can be shown in the Variables Table,
>some cannot. I couldn't identify why. Was suspecting I
>need to specify the type in the XSLT but finally found it
>is not the case.
>4. For the Watch Table, it can shows the value normally if
>the variable show normally in the Variable Table.
Unfortunately Saxon optimizes away the names of some of the local variables (the ones defined at the beginning of the template are stored - unless they are unused - but the ones inside local loops like xsl:for-each are not placed in the symbol table) so we are unable to get to them.
Subject:Debugging breakpoints with Saxon doesn't work in SS 2007 Ent. R2 894i Author:Grant Focas Date:04 Mar 2008 11:41 PM
I have just downloaded Stylus Studio 2008 Enterprise Suite (Build 1050g) and I'm getting the same problem with the debugger not stopping at the breakpoints. Even if I catch the code fast enough by pressing F5 then the pause button quickly, the breakpoints do not stop the debugger).
The breakpoints all appear in the breakpoints window.
I am using Saxon 9.0.0.2