New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better/more valuable debugging output #18

Closed
ndw opened this Issue Dec 17, 2016 · 4 comments

Comments

Projects
None yet
4 participants
@ndw
Copy link
Contributor

ndw commented Dec 17, 2016

Extend the error vocabulary?

@josteinaj

This comment has been minimized.

Copy link

josteinaj commented Jan 24, 2017

For debugging, I often find it difficult, based on the logs, to figure out:

  • which step is referred to (it might indicate p:xslt, but which one?)
  • why was that step invoked (was it through the first or second p:when? etc.)

Maybe it would make sense to have some sort of "XProc stacktrace". Something like this:

Error XD0001 : It is a dynamic error if a non-XML resource is produced on a step output or arrives on a step input.
    at p:xslt (src/steps/convert.xpl:11 - /*[1]/*[5]/*[2])
    at p:group (src/steps/convert.xpl:8 - /*[1]/*[5])
    at p:declare-step (src/steps/convert.xpl:2 - /*[1])
    at my:step (src/pipeline.xpl:50 - /*[1]/*[8]/*[1]/*[3])
    at p:when (src/pipeline.xpl:30 - /*[1]/*[8]/*[1])
    at p:choose (src/pipeline.xpl:25 - /*[1]/*[8])
    at p:declare-step (src/pipeline.xpl:2 - /*[1])

And while debugging it might be useful to have a way of triggering a stacktrace. Maybe through a function like this:

<p:xslt cx:message="{p:stacktrace()}">...</p:xslt>
@ndw

This comment has been minimized.

Copy link
Contributor

ndw commented Jan 30, 2017

That is a good idea. I'll see if I can add that kind of stack trace to errors reported by XML Calabash.

@xml-project

This comment has been minimized.

Copy link
Contributor

xml-project commented Mar 26, 2017

for cx:message see also: #29

@ndw

This comment has been minimized.

Copy link
Contributor

ndw commented Jan 10, 2019

No further spec action required (consensus, 10 Jan 2019)

@ndw ndw closed this Jan 10, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment