-
Notifications
You must be signed in to change notification settings - Fork 3
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
Calculate fields with relevance conditions fail to evaluate #133
Comments
This reproduces on cht-core 3.10.5. I believe this is a cht-core issue not a parity issue in the harness. |
This isn't a bug in cht-core. The root cause was linked to having a relevance condition to calculate expression. This thread and this were quite informative.
What was weird was that the nodes called out in the error were always in an irrelevant block. @Marina-Kenf To fix your form, you'd need to delete any relevance expressions on calculate fields and reuse them in the calculation expression. I'll give an example: Under To fix this, you'd delete the relevance expression and reuse it in the calculation as follows: |
Investigate parity issue with #78 |
@derickl In your opinion, should the harness (or pyxform) error/fail tests when there is a relevant condition on a calculate field? Should form authors be completing avoiding that data combination? |
|
@derickl I've opened medic/cht-conf#436. Do you think that would be the correct fix for this? Are there other things the harness could do before closing this issue as duplicate of medic/cht-conf#436? |
Similar class of error #143. 'Note fields marked as required, will not advance in harness' |
To Reproduce
Form
supervision_with_chw_iccm
in https://github.com/medic/config-muso/pull/418/checks?check_run_id=3463026173#step:6:1297What happened?
AssertionError: expected 'Exception in form-host fillAppForm: FormLogicError: Could not evaluate: /model/instance[1]/supervision_with_chw_iccm/s_patient_evaluation_group/s_patient_evaluation_list/s_taking_other_parameters/has_counted_resp_rate = \'yes\', message: Cannot read property \'ownerDocument\' of undefined' to be empty
What did you expect?
Can complete form.
The text was updated successfully, but these errors were encountered: