-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
"Form does not specify an instanceID" after second submission in an encrypted project #5644
Comments
I've been trying to boil this down to a minimal form reproduction and ended up with this: <h:html xmlns:h="http://www.w3.org/1999/xhtml" xmlns:jr="http://openrosa.org/javarosa"
xmlns:orx="http://openrosa.org/xforms" xmlns="http://www.w3.org/2002/xforms">
<h:head>
<h:title>Missing instance ID</h:title>
<model>
<instance>
<data id="missing_instance_id" version="1">
<orx:meta>
<instanceID />
</orx:meta>
<text1 />
</data>
</instance>
<bind calculate="concat('uuid:', uuid())" nodeset="/data/orx:meta/instanceID" readonly="true()" type="string" />
<bind nodeset="/data/text1" type="string" />
</model>
</h:head>
<h:body>
<input ref="/data/text1">
<label>Question 1</label>
</input>
</h:body>
</h:html> Basically if I finalize this form twice, the second instance with have a blank instance ID. There's two changes I can make to the form to fix the problem:
After about it with @lognaturel, we realised that rather than it working for the first "instance", it actually only works for the first form session - if you open the form, discard it and start again you'll also end up with a blank instance ID for the first instance. This would suggest that the problem is related to form def caching. As far as I can see, there's nothing incorrect with the form, so I'm pretty sure this is a bug rather than a form design problem. |
@seadowg and I briefly discussed. It's an issue with namespaced references (e.g. I think we should update the test form and that's it. |
Marking this as "won't fix". @dbemke you should be able to run the test form back through XLSForm Online or pyxform to fix the problem. |
ODK Collect version
the store version 2023.1.2, the beta version 2023.2 Beta 3
Android version
10, 13
Device used
Redmi 9T, Pixel 6a
Problem description
After sending a second submission of the form AuditTest to an encrypted project on Central there is the error saying that the "form does not specify an instanceID”. It only happens after sending the second submission, the first submission is sent to Central without any errors.
The error also contains "saved as finalized" referring to the previous design.
Steps to reproduce the problem
https://test.getodk.cloud/#/projects/469/app-users
Expected behavior
I don’t know the cause of the issue so I don’t know if the error should appear after the first submission or the form is broken or maybe it’s something related to encryption.
Other information
I uploaded the form to other project in Central and there were no warning or errors connected with the form while uploading.
The text was updated successfully, but these errors were encountered: