Import QR code settings error, ODK v2024.1

I'm facing a problem with the latest odk-collect v2024.1 during QR code import with error message saying "The QR code does not include valid settings", please help

Welcome to the ODK forum, @adelziadi ! We're glad you're here. When you get a chance, please introduce yourself on this forum thread. I'd also encourage you to add a picture as your avatar because it helps build community!

Is the QR code one generated by Central? Or, was it generated by the Collect app on another device?

The QR code was generated by the odk-collect mobile app, the same QR code is working on the previous version of odk-collect.

Thank you for help

It is unusual that there is a breaking change like that, but there may be a setting in your QR code that is causing the error (for example, something that was in previous versions but got removed).

Was the Collect app that generated the code v2023.3.1 or multiple versions older?

The fastest fix will likely be to setup and configure a device running the new version of Collect and then export the QR code again from that device.

Hi @adelziadi

Could you share that particular QR code in private? I would like to try to reproduce the issue and fix it if there is really something wrong.

1 Like

The QR code was generated by v2023.3.1 then by v2024.1 after updating the Collect

The fastest fix will likely be to setup and configure a device running the new version of Collect and then export the QR code again from that device. Please also share the QR code with @Grzesiek2010 in a private message, he is on the core development team and is interested in understanding what happened.

I've already received the QR code from @adelziadi. Thanks!
I can admit that there is something weird happening there and I'm on it.

2 Likes

@adelziadi Thanks for sharing the QR code. I was able to reproduce and track down the issue. It's super weird and I'm not able to reproduce it with any other QR code (I've tried at least 30 so far). Even If I take the one you have provided and change something small like one character in the password or username (that the QR code contains) and regenerate it, everything is fine.
I will fix the issue and we will try to release it soon but... I would like to cover this case with an automated test to avoid having similar problems in the future. However, as I said your QR code is the only one that reproduces the issue. It contains private data like username and password so I can't just add it to the test and make it public on github... Would you mind changing your username and password so that the ones that the QR code contains become obsolete? Thanks to that I could make your QR code public safely.

3 Likes

Changing the username and password is not possible, becuase this account is currently used by many users, with limited permissions.
Have you tried regenerating it without changing any character?
But, You have to know that, after several attempts to discover the cause (including the use of different account to generate the QR code), the same problem still ocuuring and I noticed that:

  • Generating the QR code and saving it to file and then reimport the saved QR, it work fine.

  • Importing a shared QR code via Whatsapp doesn't work even in the same device by which the QR code was generated.

  • Sharing the same QR code in a zip-compressed file, and it's imported successfully.

Is it a device dependent problem? or due to changes in some QR image properties such as jpeg instead of png format?

Thank you for your great support.

I understand. In this case, I won't publish it of course but please let me know once you stop using that project/user account. I can add tests later even if it's in a few months for example.

Yes and then I was able to reproduce the issue but when I tried to change the username and password (or at least one character) everything was fine.

It's not a device-specific issue.
We use zxing for generating and reading QR codes. It seems like the problem is in reading because even if I generate a QR code using an online tool (but with the same content as the one you have shared), then the result is the same.