cht-conf icon indicating copy to clipboard operation
cht-conf copied to clipboard

fix(#537): Ensure form internalId has correct prefix

Open SinghCod3r opened this issue 3 months ago • 6 comments

This PR fixes a bug where uploaded forms were missing the required prefix (e.g., contact:) in their internalId.

  • The logic in upload-forms.js has been updated to check for and add the correct prefix based on the form type.
  • An existing unit test in upload-forms.spec.js has been updated to account for this new, correct behavior.

Resolves #537.

SinghCod3r avatar Aug 28 '25 10:08 SinghCod3r

@jkuester , i have resolved the issue. i also corrected the test file. As it was needed to be changed. i request you to review this earliest and merge this if no issue found.

SinghCod3r avatar Aug 28 '25 10:08 SinghCod3r

@jkuester It looks like the E2E test is failing with a timeout. I tried re-running it, but it failed again. It doesn't seem related to my changes. Could you please take a look?

SinghCod3r avatar Aug 28 '25 10:08 SinghCod3r

:eyes: Seems like the problem with the e2e tests is unrelated to this PR/branch. I seem to be able to reproduce it locally running the main branch. Doing more investigation now....

jkuester avatar Aug 28 '25 21:08 jkuester

Okay, tracked down the issue and raised https://github.com/medic/cht-conf/pull/743. Will just need to merge in master once that PR is completed. :+1:

jkuester avatar Aug 28 '25 22:08 jkuester

@jkuester , okay then i will wait for your review and comment.

SinghCod3r avatar Aug 29 '25 09:08 SinghCod3r

Thanks! I have ~10 PRs in the queue waiting to be reviewed :sweat_smile: so I might not get to this until next week, but I have it on my list. :+1:

jkuester avatar Aug 29 '25 15:08 jkuester