Skip to content
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

Shorten ODK Validate error output #84

Open
prabhasp opened this issue Mar 22, 2013 · 1 comment
Open

Shorten ODK Validate error output #84

prabhasp opened this issue Mar 22, 2013 · 1 comment

Comments

@prabhasp
Copy link
Contributor

from something like:

ODK Validate Errors: Invalid XPath expression [if((/GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF700_2 != -9990) and?(/GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF701_2 != -9990), /GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF701_2 + /GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF700_2, -9990)]! java.lang.NullPointerException java.lang.NullPointerException at org.javarosa.core.model.FormDef.addTriggerable(FormDef.java:524) at org.javarosa.xform.parse.XFormParser.processStandardBindAttributes(XFormParser.java:1501) at org.javarosa.xform.parse.XFormParser.parseBind(XFormParser.java:1521) at org.javarosa.xform.parse.XFormParser.parseModel(XFormParser.java:460) at org.javarosa.xform.parse.XFormParser.access$200(XFormParser.java:78) at org.javarosa.xform.parse.XFormParser$3.handle(XFormParser.java:153) at org.javarosa.xform.parse.XFormParser.parseElement(XFormParser.java:375) at org.javarosa.xform.parse.XFormParser.parseElement(XFormParser.java:386) at org.javarosa.xform.parse.XFormParser.parseElement(XFormParser.java:386) at org.javarosa.xform.parse.XFormParser.parseDoc(XFormParser.java:321) at org.javarosa.xform.parse.XFormParser.parse(XFormParser.java:272) at org.javarosa.xform.util.XFormUtils.getFormFromInputStream(XFormUtils.java:72) at org.odk.validate.FormValidator.validate(FormValidator.java:322) at org.odk.validate.FormValidator.(FormValidator.java:95) at org.odk.validate.FormValidator.main(FormValidator.java:82) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader.main(JarRsrcLoader.java:58) >> Something broke the parser. See above for a hint. Result: Invalid

to something like:

ODK Validate Errors: Invalid XPath expression [if((/GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF700_2 != -9990) and?(/GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF701_2 != -9990), /GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF701_2 + /GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF700_2, -9990)]! >> Something broke the parser. See above for a hint. Result: Invalid

Does anyone disagree?

@prabhasp
Copy link
Contributor Author

(Would be even better for users if we back-translated /GS_OM_HEALTH_FACILITY_XFORM_2013_03_20/HF700_2 to ${HF700_2} . If this isn't always going to be correct, outputting both could be an option worth considering.

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

No branches or pull requests

1 participant