kobotoolbox / enketo-express

We've moved! Please use the new repository 🠊 https://github.com/enketo/enketo-express
Apache License 2.0
102 stars 90 forks source link

A Form pulling from an External CSV does not open as Offline Enketo Form. #1086

Closed dkwamboka closed 6 years ago

dkwamboka commented 6 years ago

Hi Martijn,

An error is thrown when opening an offline Enketo Form that is pulling data from an external CSV.

Server: Ona Sample Form External CSV Webform Link

The Below Error message is displayed: Chrome:

chrome

Firefox:

firefox

Explorer:

explorer

The form however opens fine as a live form.

MartijnR commented 6 years ago

Thanks a lot! I was able to reproduce and confirmed it is related to failing to store the external document in indexedDb.

MartijnR commented 6 years ago

http://localhost:8005/x/#54dAJPDf

MartijnR commented 6 years ago

probably regression caused by https://github.com/kobotoolbox/enketo-express/commit/5bf20758ca2b13244041969a4944115e6fb1ac33#diff-fc82a39d32fe16f88fc6848922ae0aa3 (directly creating XMLDoc instead of XML string)

MartijnR commented 6 years ago

Working on this. Quite a pain to solve without too many string <--> XML transformations

I wonder if adoptNode in Enketo Core empties the XML Document!

MartijnR commented 6 years ago
MartijnR commented 6 years ago

fixed in 1.69.1. Thanks a lot @dkwamboka, this revealed another even more serious issue as well!

dkwamboka commented 6 years ago

@MartijnR Glad I could be of help!