Open pbowen-oc opened 1 year ago
failing (with autoquery)
curl --user enketorules: -d "server_url=http://localhost:3000&form_id=Headless.failure&ecid=a&instance_id=b&instance=<data xmlns:oc=\"http://openclinica.org/xforms\" xmlns:enk=\"http://enketo.org/xforms\" ><int1>100</int1><observation_id>test</observation_id><meta><instanceID>uuid:1234</instanceID><instanceID_comment/></meta><int1_comment>{\"queries\":[],\"logs\":[{\"type\":\"audit\",\"message\":\"Value changed from \\\"\\\" to \\\"100\\\"\",\"user\":\"root\",\"date_time\":\"2023-04-19 17:18:59.068 Z\"}]}</int1_comment><observation_id_comment/></data>" http://localhost:8005/oc/api/v1/instance/headless
not failing (no autoquery):
curl --user enketorules: -d "server_url=http://localhost:3000&form_id=Headless.failure&ecid=a&instance_id=b&instance=<data xmlns:oc=\"http://openclinica.org/xforms\" xmlns:enk=\"http://enketo.org/xforms\" ><int1>151</int1><observation_id>test</observation_id><meta><instanceID>uuid:1234</instanceID><instanceID_comment/></meta><int1_comment>{\"queries\":[],\"logs\":[{\"type\":\"audit\",\"message\":\"Value changed from \\\"\\\" to \\\"100\\\"\",\"user\":\"root\",\"date_time\":\"2023-04-19 17:18:59.068 Z\"}]}</int1_comment><observation_id_comment/></data>" http://localhost:8005/oc/api/v1/instance/headless
headless URL: http://localhost:8005/edit/fs/headless/154315abe283fcd7be162a203c8b701e?ecid=a&instance_id=b
failing with rfc:
curl --user enketorules: -d "server_url=http://localhost:3000&form_id=Headless.failure&ecid=a&instance_id=b&instance=<data xmlns:oc=\"http://openclinica.org/xforms\" xmlns:enk=\"http://enketo.org/xforms\" oc:complete=\"true\"><int1>100</int1><observation_id>test</observation_id><meta><instanceID>uuid:1234</instanceID><instanceID_comment/></meta><int1_comment>{\"queries\":[],\"logs\":[{\"type\":\"audit\",\"message\":\"Value changed from \\\"\\\" to \\\"100\\\"\",\"user\":\"root\",\"date_time\":\"2023-04-19 17:18:59.068 Z\"}]}</int1_comment><observation_id_comment/></data>" http://localhost:8005/oc/api/v1/instance/headless/rfc
headless RFC URL: http://localhost:8005/edit/fs/rfc/headless/154315abe283fcd7be162a203c8b701e?ecid=a&instance_id=b
Can we verify this is also working properly on the master branch as part of validation.
6.0.0.oc-5
Headless mode is able to open forms and save data (if a calculation calls for it), but it is not able to save autoqueries. This occurs for forms opened with POST /instance/headless or POST /instance/headless/rfc
Steps:
Expected: The form adds an autoquery to the data item that violates the constraint and the call completes without error.
Actual: No autoquery is added. The call returns an error code after 5 minutes (which is our current headless timeout).