View Issue Details

This issue affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
20465Bug reportsSurvey participants (Tokens)public2026-03-19 14:02
ReporterDenisChenu Assigned Toc_schmitz  
PrioritynoneSeverityblock 
Status ready for code reviewResolutionopen 
Product Version6.16.x 
Summary20465: Allowed memory size when trye to send email.
Description

When you have numerous participants, it's impossible to send email. The admin/tokens/sa/email/surveyid/surveyid show a Allowed memory size error.

Steps To Reproduce

Steps to reproduce

Set memory_limit to 1024M
Import included LSA
Set memory_limit to 256M
Go to the Participant table
Click on Invite and Remind / Send invitaion

Expected result

See the page to send an invitation (do not send it currently)

Actual result

White page (500 error) or

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 4096 bytes) in ./vendor/yiisoft/yii/framework/collections/CList.php on line 156
Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 1052672 bytes) in ./application/helpers/common_helper.php on line 3540

TagsNo tags attached.
Bug heat4
Complete LimeSurvey version number (& build)6.16.13
I will donate to the project if issue is resolvedNo
Browsernot relevant
Database type & versionmariadb
Server OS (if known)debian OR limeservice
Webserver software & version (if known)nginx OR limeservice
PHP Version8.3

Users monitoring this issue

There are no users monitoring this issue.

Activities

DenisChenu

DenisChenu

2026-03-18 16:07

developer   ~84474

Oupos :)
On limeservice : broke at 120000 participants (ticket #57650)
No real solution except to create an alternative survey.

I don't want to resurrect sendMailAjax ....

DenisChenu

DenisChenu

2026-03-18 16:07

developer   ~84475

PS: Survey archive export work with 256Mo

survey_archive_946472.lsa (1,127,855 bytes)
DenisChenu

DenisChenu

2026-03-18 16:12

developer   ~84476

Why we use short_implode here ?
With sort($array) ?

DenisChenu

DenisChenu

2026-03-19 12:13

developer   ~84485

I have Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 1052672 bytes) in ./application/helpers/common_helper.php on line 3540

line 3540 is short_implode function

Else

I think we must allow empty tokenID list : check the next XXX tokens with condition
Just a tokenId Start at

The issue is here : https://github.com/LimeSurvey/LimeSurvey/blob/32d6e4d4a5822fc60ebdcfef2329bd639e513169/application/controllers/admin/Tokens.php#L3167

We can improve a little because ‎TokenDynamic.findUninvitedIDs https://github.com/LimeSurvey/LimeSurvey/blob/32d6e4d4a5822fc60ebdcfef2329bd639e513169/application/models/TokenDynamic.php#L235 get all data to keep only ID

But it's just broke less (potentially after 300 000)

c_schmitz

c_schmitz

2026-03-19 14:02

administrator   ~84487

https://github.com/LimeSurvey/LimeSurvey/pull/4792

Issue History

Date Modified Username Field Change
2026-03-18 16:04 DenisChenu New Issue
2026-03-18 16:07 DenisChenu Note Added: 84474
2026-03-18 16:07 DenisChenu Bug heat 0 => 2
2026-03-18 16:07 DenisChenu Note Added: 84475
2026-03-18 16:07 DenisChenu File Added: survey_archive_946472.lsa
2026-03-18 16:09 DenisChenu Steps to Reproduce Updated
2026-03-18 16:10 DenisChenu Steps to Reproduce Updated
2026-03-18 16:12 DenisChenu Note Added: 84476
2026-03-19 12:01 c_schmitz Assigned To => c_schmitz
2026-03-19 12:01 c_schmitz Status new => assigned
2026-03-19 12:01 c_schmitz Bug heat 2 => 4
2026-03-19 12:02 c_schmitz Severity minor => block
2026-03-19 12:07 c_schmitz Bug heat 4 => 2
2026-03-19 12:13 DenisChenu Note Added: 84485
2026-03-19 14:02 c_schmitz Note Added: 84487
2026-03-19 14:02 c_schmitz Bug heat 2 => 4
2026-03-19 14:02 c_schmitz Status assigned => ready for code review