Skip to content
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

Collect app not syncing new form-media without new form version #746

Open
joshuaberetta opened this issue Jul 14, 2021 · 0 comments
Open

Comments

@joshuaberetta
Copy link
Member

joshuaberetta commented Jul 14, 2021

Steps to reproduce

  1. Create a form with a note question referencing an image

survey

type name label media::image
note an_image an interesting image image.jpg
  1. Upload image in KPI (SETTINGS>Media)

  2. Deploy form

xform

<xform>
    <formID>a4US7ASdRBkm3rqusLMnVQ</formID>
    <name>note with images</name>
    <majorMinorVersion>3 (2021-07-14 21:42:58)</majorMinorVersion>
    <version>3 (2021-07-14 21:42:58)</version>
    <hash>md5:76c2de90d5cffa5f51620bd242597dff</hash>
    <descriptionText>two images without spaces</descriptionText>
    <downloadUrl>
        https://kc.master.kbtdev.org/joshuaberetta/forms/592317/form.xml
    </downloadUrl>
    <manifestUrl>
        https://kc.master.kbtdev.org/joshuaberetta/xformsManifest/592317
    </manifestUrl>
</xform>

manifest

<manifest>
    <mediaFile>
        <filename>image.jpg</filename>
        <hash>md5:33151381ac3a44a56f302aa96b0154c2</hash>
        <downloadUrl>
            https://kc.master.kbtdev.org/joshuaberetta/xformsMedia/592317/1301683.jpg
        </downloadUrl>
    </mediaFile>
</manifest>
  1. Download form in KoBoCollect

  2. Fill blank form

  3. See image displayed

image

  1. In KPI (SETTINGS>Media), delete the image and upload new one with the same name

  2. Redeploy form

xform

<xform>
    <formID>a4US7ASdRBkm3rqusLMnVQ</formID>
    <name>note with images</name>
    <majorMinorVersion>3 (2021-07-14 21:42:58)</majorMinorVersion>
    <version>3 (2021-07-14 21:42:58)</version>
    <hash>md5:76c2de90d5cffa5f51620bd242597dff</hash>
    <descriptionText>two images without spaces</descriptionText>
    <downloadUrl>
        https://kc.master.kbtdev.org/joshuaberetta/forms/592317/form.xml
    </downloadUrl>
    <manifestUrl>
        https://kc.master.kbtdev.org/joshuaberetta/xformsManifest/592317
    </manifestUrl>
</xform>

manifest

<manifest>
    <mediaFile>
        <filename>image.jpg</filename>
        <hash>md5:bb278efbcf75c149ef8c9f270ea7a395</hash>
        <downloadUrl>
            https://kc.master.kbtdev.org/joshuaberetta/xformsMedia/592317/1301684.jpg
        </downloadUrl>
    </mediaFile>
</manifest>

(hash and id update)

  1. Fetch updated form in KoBoCollect

image
(App sees a change)

image

image

  1. Fill blank form

  2. See old image still displayed

image

  1. See new image successfully downloaded to device storage

image

  1. In KPI, make a change that will trigger a new version (changing the title)

  2. Redeploy

form

<xform>
    <formID>a4US7ASdRBkm3rqusLMnVQ</formID>
    <name>note with image</name>
    <majorMinorVersion>4 (2021-07-14 22:18:27)</majorMinorVersion>
    <version>4 (2021-07-14 22:18:27)</version>
    <hash>md5:b0ad94d901024c499481240a9973d20a</hash>
    <descriptionText>two images without spaces</descriptionText>
    <downloadUrl>
        https://kc.master.kbtdev.org/joshuaberetta/forms/592317/form.xml
    </downloadUrl>
    <manifestUrl>
        https://kc.master.kbtdev.org/joshuaberetta/xformsManifest/592317
    </manifestUrl>
</xform>

(hash and version updates)

  1. Fetch updated form in KoBoCollect

image

  1. Fill blank form

image

  1. See new image

image

Note

  1. When a CSV is used with a select_*_from_file type question and the same steps are followed, the updated choices are displayed as expected (no testing done yet with other question types)
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

No branches or pull requests

1 participant