View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 19894 | Bug reports | Other | public | 2024-12-16 17:15 | 2025-09-08 16:22 |
| Reporter | tassoman | Assigned To | tibor.pacalat | ||
| Priority | none | Severity | minor | ||
| Status | closed | Resolution | fixed | ||
| Product Version | 6.6.x | ||||
| Summary | 19894: Calling "__tostring" method on a "SimpleXMLElement" object is not allowed | ||||
| Description | While editing new theme by hands, I tried to dump(aSurveyInfo) variable. Version is 6.8.2+241203 (missing product version in bug tracker) Twig\Sandbox\SecurityNotAllowedMethodError Calling "tostring" method on a "SimpleXMLElement" object is not allowed in "string_template__b85a9d86339e4b676595fbe968ac295f" at line 234. | ||||
| Steps To Reproduce | Steps to reproduce
Expected resultI wanted to dump survey data Actual resulterror stacktrace, see attached image | ||||
| Tags | debug, survey, template, theme, twig | ||||
| Attached Files | |||||
| Bug heat | 10 | ||||
| Complete LimeSurvey version number (& build) | 6.8.2+241203 | ||||
| I will donate to the project if issue is resolved | No | ||||
| Browser | Any | ||||
| Database type & version | Mysql 5.7.x | ||||
| Server OS (if known) | |||||
| Webserver software & version (if known) | |||||
| PHP Version | 8.2.26 | ||||
| related to | 19952 | closed | DenisChenu | Unable to use {{ dump(aSurveyInfo) }} in |
|
Found this on PHP Manual (about PHP 8.x) |
|
|
By removing force_xmlsettings_for_survey_rendering configuration, I got a similar error. That's because confinguration is an object.
To debug like this, i usually do |
|
|
|
|
|
https://github.com/LimeSurvey/LimeSurvey/pull/4369 I'm not sure if this is a bug or not, because I don't think Lime uses the twig "dump" function anywhere. |
|
I already use it a lot ! |
|
|
Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=39007 |
|
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2024-12-16 17:15 | tassoman | New Issue | |
| 2024-12-16 17:15 | tassoman | File Added: Screenshot 2024-12-16 at 17-08-45 Twig_Sandbox_SecurityNotAllowedMethodError.png | |
| 2024-12-16 17:17 | tassoman | Tag Attached: twig | |
| 2024-12-16 17:17 | tassoman | Tag Attached: theme | |
| 2024-12-18 17:13 | tassoman | Note Added: 81659 | |
| 2024-12-18 17:13 | tassoman | Bug heat | 0 => 2 |
| 2024-12-18 17:51 | tassoman | Note Added: 81660 | |
| 2025-02-04 08:46 | DenisChenu | Relationship added | related to 19952 |
| 2025-02-18 17:21 | tassoman | Issue Monitored: tassoman | |
| 2025-02-18 17:21 | tassoman | Bug heat | 2 => 4 |
| 2025-02-18 17:23 | tassoman | Tag Attached: template | |
| 2025-02-18 17:23 | tassoman | Tag Attached: survey | |
| 2025-02-18 17:23 | tassoman | Tag Attached: debug | |
| 2025-06-18 11:33 | tassoman | Note Added: 82899 | |
| 2025-07-16 13:23 | tibor.pacalat | Assigned To | => gabrieljenik |
| 2025-07-16 13:23 | tibor.pacalat | Status | new => assigned |
| 2025-07-19 00:10 | gabrieljenik | Assigned To | gabrieljenik => DenisChenu |
| 2025-07-19 00:10 | gabrieljenik | Status | assigned => ready for code review |
| 2025-07-19 00:10 | gabrieljenik | Note Added: 83111 | |
| 2025-07-19 00:10 | gabrieljenik | Bug heat | 4 => 6 |
| 2025-07-21 09:02 | DenisChenu | Note Added: 83113 | |
| 2025-07-21 09:02 | DenisChenu | Bug heat | 6 => 8 |
| 2025-07-22 11:18 | DenisChenu | Assigned To | DenisChenu => tibor.pacalat |
| 2025-07-22 11:18 | DenisChenu | Status | ready for code review => ready for testing |
| 2025-07-22 16:09 | Changeset attached | => LimeSurvey master 282ef6fb | |
| 2025-07-22 16:09 | guest | Note Added: 83129 | |
| 2025-07-22 16:09 | guest | Bug heat | 8 => 10 |
| 2025-07-22 16:09 | tibor.pacalat | Status | ready for testing => resolved |
| 2025-07-22 16:09 | tibor.pacalat | Resolution | open => fixed |
| 2025-09-08 16:22 | c_schmitz | Status | resolved => closed |