NERC-CEH / fit-count-app

Fit Count App & Website
Apache License 2.0
0 stars 0 forks source link

Survey doesn't upload #61

Closed kitenetter closed 3 years ago

kitenetter commented 3 years ago

I carried out a test survey at the weekend. I was away from wifi and also had mobile data switched off.

At the end of the survey I asked the app to upload the survey, just to see what happened. It tried to upload but failed, as expected, and the survey remained in the pending list.

However, when I came back within wifi range the survey is still failing to upload. No error message is given, it just tries to upload for a few seconds, then stops, and leaves the survey in the pending list.

kazlauskis commented 3 years ago

@kitenetter try it again now.

kitenetter commented 3 years ago

Thanks @kazlauskis that has uploaded and I can see it on the test version of the new PoMS website.

kazlauskis commented 3 years ago

@johnvanbreda do you know if calling index.php/services/user_identifier/get_user_id from a Drupal website automatically attaches that user's account to the calling site in the warehouse? What has happened here is that Martin had an account in the Warehouse linked to multiple sites, upon app registration the Indicia API module has fetched the existing warehouse ID for Martin's drupal-profile but the warehouse hasn't added the drupal site to the warehouse-profile account. So when the app is uploading records to the warehouse (using JWT), the warehouse doesn't find the user account linked to the site and so the warehouse rejects the submission. It works OK for new user accounts though.

johnvanbreda commented 3 years ago

@kazlauskis yes, it should do that. If it didn't automatically link existing accounts to the website it would not be possible to link 1 account to more than 1 website. Can you create a test case?

kazlauskis commented 3 years ago

Thanks, this has only happened to Martin and David. Since they are both 'super-users' on the warehouse and also admins on the site I will leave this ticket closed for now. I will reopen the ticket and delve deeper into this if any regular users encounter this issue.

kitenetter commented 3 years ago

I've had a report of a survey not uploading from a standard user who has just downloaded the test app (iOS version), registered as a new user and tried to submit a count. He doesn't give much detail, but it sounds similar to the problem I had: "I couldn’t upload my fictitious results, but I guess that’s because it’s a test version."

kitenetter commented 3 years ago

This appears to be linked to a registration problem so is not the same problem that I was experiencing.

kazlauskis commented 3 years ago

Yes, the user has to verify the email before uploading any surveys.

DavidRoy commented 3 years ago

Is there a way to give this status within the app? This is likely to catch out others?

kitenetter commented 3 years ago

The user says he did not receive an email.

DavidRoy commented 3 years ago

I think there is a Spam filter issue? @birenrathod

kazlauskis commented 3 years ago

In the app, we ask to confirm the email after the registration as well as when trying to upload the first survey and we can rephrase the messages to make them clearer. Essentially this comes down to finding the verification email and clicking on the verification link.

DavidRoy commented 3 years ago

@kazlauskis can you make the message specific to the stage of registration, e.g. '...you still need to verify you account by clicking on the link in an email sent from xxx@ceh.ac.uk..'

kitenetter commented 3 years ago

Our test user confirms that the registration email ended up in his spam folder. If there's anything we can do to make this less likely to happen that would be good. Should we add a warning to users that they may need to check their spam folder?

DavidRoy commented 3 years ago

I'll add a separate issue about options for reducing the likelihood of getting caught up in spam filters and tracking registration status.
@kitenetter please close this issue if appropriate

BirenRathod commented 3 years ago

@DavidRoy, @kazlauskis & @kitenetter I have configured the email service, so it will no longer end up in spam.