Skip to content

806/807: remove code/tests for settings instance_id and omit_instanceID - #878

Merged
lindsay-stevens merged 4 commits into
XLSForm:masterfrom
lindsay-stevens:pyxform-807
Oct 19, 2026
Merged

lindsay-stevens merged 4 commits into
XLSForm:masterfrom
lindsay-stevens:pyxform-807

Conversation

@lindsay-stevens

Copy link
Copy Markdown
Contributor

Closes #806
Closes #807

Why is this the best possible solution? Were any other approaches considered?

Grouped these into one PR since the code is very close or overlaps. As discussed in the tickets, these settings allowed modifying instanceID behaviour in ways that are not supported or are at least not typical.

What are the regression risks?

Forms or clients that relied on these settings/behaviour would not work.

Does this change require updates to documentation? If so, please file an issue here and include the link below.

No, these settings were not documented on xlsform.org or ODK docs.

Before submitting this PR, please make sure you have:

  • included test cases for core behavior and edge cases in tests
  • run python -m unittest and verified all tests pass
  • run ruff format pyxform tests and ruff check pyxform tests to lint code
  • verified that any code or assets from external sources are properly credited in comments

- appears to be deprecated or undefined behaviour, possibly added
  as backwards compatibility for clients without a uuid() function, but
  generally ODK tools expect instanceID to be a "uuid: <uuid>" string.
- the setting value would be passed into `@jr:preload` for the binding
  on the primary instance meta instanceID element. In the javarosa
  library the QuestionPreloader seems to handle uid, date, property, and
  timestamp (per the ODK XForms spec), and otherwise raises an error:
  "Do not know how to handle preloader".
  https://github.com/getodk/javarosa/blob/v6.0.0/src/main/java/org
  /javarosa/core/model/utils/QuestionPreloader.java#L40
- see pyxform/XLSForm#807 for further research notes.
- appears to be deprecated or undefined behaviour, possibly added
  as backwards compatibility for clients without a uuid() function, but
  generally ODK tools expect instanceID to be a "uuid: <uuid>" string.
- see pyxform/XLSForm#806 for further research notes.
- apply other constants to definition block in xls2json.py

@lognaturel lognaturel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels so light! 🧹

Comment thread pyxform/xls2json.py Resolved
- replace narrative comments with descriptions from ODK spec, since that
  seems the most useful info about what/why those elements are added.
@lindsay-stevens
lindsay-stevens merged commit 70b9469 into XLSForm:master Oct 19, 2026
14 checks passed
@lindsay-stevens
lindsay-stevens deleted the pyxform-807 branch October 19, 2026 06:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

remove code for undocumented setting instance_id remove code for undocumented setting omit_instanceID

2 participants