Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

bug ? answers not recorded in DB but notification email is sent

  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 2 weeks ago - 4 years 2 weeks ago #195223 by bebs
Hello.

Using LS 3.19.1+191009 on PHP 7.3 @OVH, I experience a troublesome bug for a running survey. Any help in fixing it is urgently welcome.

After the users gets his token sent by email, answers all questions (multiple pages) with no issue and gets the last "thank you" page displayed, his answers are sometimes not recorded at all in the LS DB.

The related token entry is updated (completion time is set, uses left is decreased,...) but NO ANSWER entry is created for this user.

Moreover :

.The user gets "his" confirmation email with a few (questions-related) shortcodes rightfully replaced by correct values,
. The "full" notification email (default template) sent to administrator is faulty in that
the {EDITRESPONSEURL} does not contain the answer ID
the {ANSWERTABLE} contains no answers (only the questions text and codes), even the "metadata" of the entry is completely missing:

Cliquez sur le lien suivant pour voir cette réponse :
emfro.vunderatert.lu/index.php/admin/res...w/surveyid/612987/id << MISSING ANSWER ID

Cliquez sur le lien suivant pour éditer cette réponse individuelle :
emfro.vunderatert.lu/index.php/admin/dat...t/surveyid/612987/id

Visualisez les statistiques en cliquant ici :
emfro.vunderatert.lu/index.php/admin/sta...ndex/surveyid/612987


Les réponses suivantes ont été données par le participant :
ID de la réponse << MISSING METADATA
Date de soumission
Dernière page
Langue de départ
Tête de série
Code
Date de lancement
Date de la dernière action
Renseignements personnels
civilité << MISSING ANSWER
civilité [Autre]
Vos coordonnées
Vos coordonnées [Prénom]



The user has no "error" feedback while completing the survey. The web console only shows 2 warning on the last ("thank you") page for missing assets maps:
DevTools failed to parse SourceMap: emfro.vunderatert.lu/tmp/assets/301146f9/pjax.js.map
DevTools failed to parse SourceMap: emfro.vunderatert.lu/tmp/assets/d6560812/bootstrap.min.css.map
... but the related assets (stripping .map at the end) are available at the generated URL.


LSS is provided for your inspection, along with theme customisations (VdA.zip) that is used to compute a few answers (simple dynamic sum and products in array-like answers) in JS.



Strangest thing is that in the meantime some other users' answers are recorded correctly, and I see no pattern in those that work or fail (since I don't have any detail on the ones failing). Web server logs don't show any error.

Any idea how to look to debug the problem ?
Thanks in advance,
Berteh.
Last edit: 4 years 2 weeks ago by bebs. Reason: clarification
The topic has been locked.
More
4 years 2 weeks ago #195225 by jelo
The LS3 build you use is lacking some updates. I recommend to update to a higher build of LS3. There where issues with lost answers when accessing the first page. Are you using a shared webhosting account or something else from OVH?

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The following user(s) said Thank You: bebs
The topic has been locked.
  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 2 weeks ago #195226 by bebs
yes, shared hosting indeed. So far I'm happy with their "perso2014" offer, and LS used to work fine thereon.

Will try to update, thanks for the recommandation.
The topic has been locked.
  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 2 weeks ago #195227 by bebs
would 3.22.8+200309 do, or is there a more recent LS3 update that I didn't find ?

I looked for documentation on upgrading in the manual... but nothing relates to LS3, is it as simple as backup - overwrite files & test, or is there some DB updates to run too ?
The topic has been locked.
More
4 years 2 weeks ago #195228 by jelo
I wouldn't recommend doing an manual upgrade on a running system without precaution.
manual.limesurvey.org/Upgrading_from_a_previous_version

The fixes applied to LS3 can be seen in the changelog and in GITHUB.
github.com/LimeSurvey/LimeSurvey/commits/3.x-LTS

The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The following user(s) said Thank You: bebs
The topic has been locked.
  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 1 week ago #195461 by bebs
Hello.
I updated my system to 3.22.8+200309 and the problem still happens:

1) Some people register to get a token, answer via the provided link, submit their answer get the automated confirmation email (with expressions being well replaced by the given answers, but the answer ID is not subsituted in the URL to review answer)
2) the answer is NOT recorded in LS DB, whereas the token table is updated (count left set to 0 and date of submission is recorded)

any idea how to debug this ?
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 1 week ago #195463 by holch
If the data is NOT recorded in the database, how can expressions use the answers? There seems to be more going on. In my opinion, for the expressions to be able to use the previous answers, the data must be recorded in the database at some point.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Away
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 1 week ago #195471 by tpartner

There seems to be more going on. In my opinion, for the expressions to be able to use the previous answers, the data must be recorded in the database at some point.

Not necessarily - Expression Manager works in inactive surveys where no data is recorded.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 1 week ago #195472 by holch

Not necessarily - Expression Manager works in inactive surveys where no data is recorded.

Good point! So does it draw from the session files?

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 1 week ago - 4 years 1 week ago #195571 by bebs
I'm still looking as to where this issue may come from... but to no avail for now:



When run in debug mode a few warning are printed on top of each question page:
Code:
Notice: Undefined index: anonymized in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6031
 
Notice: Undefined index: deletenonvalues in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6979
 
Notice: Undefined index: deletenonvalues in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6979
 
Notice: Undefined index: active in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 5438

and on the top of thirs question the following show up too:
Code:
Notice: Undefined index: radix in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 8844
 
Notice: Undefined index: anonymized in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6031
 
Notice: Undefined index: deletenonvalues in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6979

and on the last, automatic "thank you" page I get this new notice:
Code:
Notice: Undefined index: srid in /home/vunderatdm/limesurvey/application/helpers/frontend_helper.php on line 586

I confirm I can reproduce the problem. I got valid answers that fail each time to be recorded in the DB, even though they don't look suspicious: it's just a few select drop downs, integers and free text in german.

Strangely enough, selecting french language and answering in french doesn't seem to ever fail, for the same survey with 2 active languages (FR is main. DE is translation).

Don't know if that helps though.
B.
Last edit: 4 years 1 week ago by bebs. Reason: precision
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 1 week ago #195576 by DenisChenu

Using LS 3.19.1+191009 on PHP 7.3 @OVH, I experience a troublesome bug for a running survey. Any help in fixing it is urgently welcome.

Before anything else : update to last LTS version : www.limesurvey.org/lts-releases-download

Notice: Undefined index: anonymized in /home/vunderatdm/limesurvey/application/helpers/expressions/em_manager_helper.php on line 6031

There are really a big issue here ...
No plugin ? No Ajax mode ? Use included theme ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
  • bebs
  • bebs's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
4 years 3 days ago #195801 by bebs
Hello Denis.
I use some homemade JS to compute autonamted numeral value, in the answers structure in the attached LSS file.

But the EM error mentionned happens before that, on the first survey page after registration:
The registration link is a static redirection to the "right" questionnaire ID: [url] zaitgemeis.vunderatert.lu [/url] > emfro.vunderatert.lu/index.php/612987 ... and things seem to go wrong if the user registers there in FR, and then changes the language in the first page of the questionnaire to DE. That first page is about privacy policy, displayed using LS normal mechanism for in-page display of these terms.

Attached is also the custom theme (VdA), but no JS there. I did try to add the localized survey introduction message in the welcome page, but that did not work... would that be the culprit ?

How can I further debug this ?
Thanks for your help !
Berteh.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose