changeset 6082:806fa23dffb3

Add some debugging tips
author Andre Heinecke <aheinecke@intevation.de>
date Fri, 24 May 2013 09:22:39 +0200
parents cdd9759b15b6
children a596ddb42fb3
files artifacts/doc/datacage.txt
diffstat 1 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/artifacts/doc/datacage.txt	Fri May 24 09:22:10 2013 +0200
+++ b/artifacts/doc/datacage.txt	Fri May 24 09:22:39 2013 +0200
@@ -145,4 +145,13 @@
 and invoked from another location within the document, e.g. with
 
                 <dc:call-macro name="basedata_4_heightmarks"/>
-.
+
+Debugging Tips:
+  - You can send a message to the Log (log level info) during the evaluation
+  of the datacage by using the <dc:message> element.
+  For example to activate a basic macro tracing you could do something like:
+      %s@\(<dc:macro name="\)\(.*\)\(".*>\)@\1\2\3\r<dc:message>\2</dc:message>
+  - To dump the variables that are currently on the stack you can use the
+  dc:dump-variables() fuction.
+  For example:
+    <dc:message>{dc:dump-variables()}</dc:message>

http://dive4elements.wald.intevation.org