Relationship Graph
View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
19111 | Bug reports | Statistics | public | 2023-09-25 16:28 | 2024-02-22 11:32 |
Reporter | babiel | Assigned To | mfavetti | ||
Priority | none | Severity | partial_block | ||
Status | closed | Resolution | no change required | ||
Product Version | 6.2.x | ||||
Summary | 19111: Statistics export partially bricked | ||||
Description | Hello there, we're experiencing some issues during statistics export after several updates that were performed using comfort updater. Precisely PDF export including statistics graphics doesn't work for us and export to excel at all. Export to HTML and to PDF, when statistics graphics are not included, seem to be working. We patched from 5.4.8 to 6.2.6 and then to 6.2.7. On 6.2.7 the issues have been reported by out customer. I patched to 6.2.9, but the issues still persist. The major update was performed manually, for the updates to 6.2.7 and 6.2.9 the comfort updates was used. During the major upgrade https://manual.limesurvey.org/Installation_security_hints/de#Setzen_von_Berechtigungen_auf_einem_selbstverwalteten_Linux-System has been considered. But this had blocked the comfort updates as it issued, that several files were not writeable. So I had to set the following file permissions additionally:
This way the comfort updater is happy, but I don't know if this bricked the statistics export utility. Unfortunately no error is logged in vhost error or PHP logfile. | ||||
Steps To Reproduce | Steps to reproduceGo to https://umfrage.bmz.de/index.php/admin/statistics/sa/index/surveyid/171834 ( just pick a survey ) and export to pdf, including statistics graphics, and to excel. Expected resultexport works Actual resultboth times popup developer console show http 500 error on /index.php/admin/statistics/sa/index/surveyid/171834 | ||||
Tags | No tags attached. | ||||
Bug heat | 16 | ||||
Complete LimeSurvey version number (& build) | LimeSurvey Community Edition Version 6.2.9+230925 | ||||
I will donate to the project if issue is resolved | Yes | ||||
Browser | Vivaldi, Chrome, Firefox | ||||
Database type & version | MySQL 8.0.34 | ||||
Server OS (if known) | Debian 11 | ||||
Webserver software & version (if known) | Apache 2.4.56 | ||||
PHP Version | 7.4.33 | ||||
has duplicate | 19137 | closed | DenisChenu | Statistics export partially bricked |
Please Close this as I reopened this Issue public https://bugs.limesurvey.org/view.php?id=19137 I coudn't find an edit button or something like that. |
|
Should 19137 be closed? or 19111? |
|
Does nobody have a clue? |
|
i made this one public, your public duplicate was closed by mistake I think |
|
ok from my testing 8.2 php 8.1 php 8.0 AND 7.4 YES = works as expected |
|
testing on latest master branch 590c1ac76e2da298d01c34ac4e9fe7f9138e343d I can see 4 different exports here first three from selector near the top and the last is a button on each html chart 1/2/3 see above @babiel |
|
@mfavetti We're running on PHP7.4: Is there anything else I can provide? |
|
I take by age , didn't ee public VS private ;) But more clean to update status like you do. It work always with debuig=0 according to @mfavetti It's not the case for you @babiel ? |
|
You can add more error log via LimeSurvey : https://manual.limesurvey.org/Optional_settings/en#Logging_settings (maybe) |
|
So PDF didn't work on 6.2.9 but it worked on 6.3.1 ?
|
|
debug 1/2 on 8.1/8.2, pdf warning/error is: PHP error /usr/share/nginx/html/master/application/libraries/admin/pdf.php(607) 595 return ($width / $count); debug 2 on 8.2, excel warning/error is: /usr/share/nginx/html/master/vendor/pear/spreadsheet_excel_writer/Spreadsheet/Excel/Writer/Parser.php(196) 184 $this->_ext_sheets = array(); I cannot reproduce any error on 8.0/7.4 under any debug level |
|
Can you tell me how to generate statistics exports using debug=0, or debug=1 or debug=2 ? Specifically, how to set debug=0 etc.? Do I do this using https://manual.limesurvey.org/Optional_settings/en#Logging_settings ? I tried this, but no error is logged there. Thanks for your help! |
|
same page you linked, search debug |
|
So I edited application/config/config.php , restarted PHP FPM, but nothing is logged to tmp/runtime/application.log . I do think this works, but there is nothing to log... |
|
if you're still getting the error, go to statistics page, open the browser devtools, then click view statistics, then click ok on js alert then go to network in devtools, find the red one with 500 error and paste here the error under response tab |
|
Thank you! Using debug=1 the following error has been logged 2023/11/03 11:09:46 [error] [php] require_once(Console/Getopt.php): failed to open stream: No such file or directory (/opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/System.php:20) Please find the browser devtools output attached in LimeSurvey_excel_export_error.html LimeSurvey_excel_export_error.html (36,482 bytes)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>PHP warning</title> <style type="text/css"> /*<![CDATA[*/ html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td { border: 0; outline: 0; font-size: 100%; vertical-align: baseline; background: transparent; margin: 0; padding: 0; } body { line-height: 1; } ol, ul { list-style: none; } blockquote, q { quotes: none; } blockquote:before, blockquote:after, q:before, q:after { content: none; } :focus { outline: 0; } ins { text-decoration: none; } del { text-decoration: line-through; } table { border-collapse: collapse; border-spacing: 0; } body { font: normal 9pt "Verdana"; color: #000; background: #fff; } h1 { font: normal 18pt "Verdana"; color: #f00; margin-bottom: .5em; } h2 { font: normal 14pt "Verdana"; color: #800000; margin-bottom: .5em; } h3 { font: bold 11pt "Verdana"; } pre { font: normal 11pt Menlo, Consolas, "Lucida Console", Monospace; } pre span.error { display: block; background: #fce3e3; } pre span.ln { color: #999; padding-right: 0.5em; border-right: 1px solid #ccc; } pre span.error-ln { font-weight: bold; } .container { margin: 1em 4em; } .version { color: gray; font-size: 8pt; border-top: 1px solid #aaa; padding-top: 1em; margin-bottom: 1em; } .message { color: #000; padding: 1em; font-size: 11pt; background: #f3f3f3; -webkit-border-radius: 10px; -moz-border-radius: 10px; border-radius: 10px; margin-bottom: 1em; line-height: 160%; } .source { margin-bottom: 1em; } .code pre { background-color: #ffe; margin: 0.5em 0; padding: 0.5em; line-height: 125%; border: 1px solid #eee; } .source .file { margin-bottom: 1em; font-weight: bold; } .traces { margin: 2em 0; } .trace { margin: 0.5em 0; padding: 0.5em; } .trace.app { border: 1px dashed #c00; } .trace .number { text-align: right; width: 2em; padding: 0.5em; } .trace .content { padding: 0.5em; } .trace .plus, .trace .minus { display: inline; vertical-align: middle; text-align: center; border: 1px solid #000; color: #000; font-size: 10px; line-height: 10px; margin: 0; padding: 0 1px; width: 10px; height: 10px; } .trace.collapsed .minus, .trace.expanded .plus, .trace.collapsed pre { display: none; } .trace-file { cursor: pointer; padding: 0.2em; } .trace-file:hover { background: #f0ffff; } /*]]>*/ </style> </head> <body> <div class="container"> <h1>PHP warning</h1> <p class="message"> require_once(Console/Getopt.php): failed to open stream: No such file or directory </p> <div class="source"> <p class="file">/opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/System.php(20)</p> <div class="code"> <pre><span class="ln">08</span> * @package System <span class="ln">09</span> * @author Tomas V.V.Cox <cox@idecnet.com> <span class="ln">10</span> * @copyright 1997-2009 The Authors <span class="ln">11</span> * @license http://opensource.org/licenses/bsd-license.php New BSD License <span class="ln">12</span> * @link http://pear.php.net/package/PEAR <span class="ln">13</span> * @since File available since Release 0.1 <span class="ln">14</span> */ <span class="ln">15</span> <span class="ln">16</span> /** <span class="ln">17</span> * base class <span class="ln">18</span> */ <span class="ln">19</span> require_once 'PEAR.php'; <span class="error"><span class="ln error-ln">20</span> require_once 'Console/Getopt.php'; </span><span class="ln">21</span> <span class="ln">22</span> $GLOBALS['_System_temp_files'] = array(); <span class="ln">23</span> <span class="ln">24</span> /** <span class="ln">25</span> * System offers cross platform compatible system functions <span class="ln">26</span> * <span class="ln">27</span> * Static functions for different operations. Should work under <span class="ln">28</span> * Unix and Windows. The names and usage has been taken from its respectively <span class="ln">29</span> * GNU commands. The functions will return (bool) false on error and will <span class="ln">30</span> * trigger the error with the PHP trigger_error() function (you can silence <span class="ln">31</span> * the error by prefixing a '@' sign after the function call, but this <span class="ln">32</span> * is not recommended practice. Instead use an error handler with </pre> </div> </div> <div class="traces"> <h2>Stack Trace</h2> <table style="width:100%;"> <tr class="trace app expanded"> <td class="number"> #0 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/System.php(20): <strong>require_once</strong>() </div> <div class="code"> <pre><span class="ln">15</span> <span class="ln">16</span> /** <span class="ln">17</span> * base class <span class="ln">18</span> */ <span class="ln">19</span> require_once 'PEAR.php'; <span class="error"><span class="ln error-ln">20</span> require_once 'Console/Getopt.php'; </span><span class="ln">21</span> <span class="ln">22</span> $GLOBALS['_System_temp_files'] = array(); <span class="ln">23</span> <span class="ln">24</span> /** <span class="ln">25</span> * System offers cross platform compatible system functions </pre> </div> </td> </tr> <tr class="trace app expanded"> <td class="number"> #1 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(582): <strong>include</strong>("/opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/Sy...") </div> <div class="code"> <pre><span class="ln">577</span> * <span class="ln">578</span> * @param string $file <span class="ln">579</span> * @return void <span class="ln">580</span> */ <span class="ln">581</span> self::$includeFile = \Closure::bind(static function($file) { <span class="error"><span class="ln error-ln">582</span> include $file; </span><span class="ln">583</span> }, null, null); <span class="ln">584</span> } <span class="ln">585</span> } </pre> </div> </td> </tr> <tr class="trace app expanded"> <td class="number"> #2 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(433): <strong>Composer\Autoload\{closure}</strong>("/opt/srv/www/htdocs/umfrage/vendor/composer/../pear/pear-core-mi...") </div> <div class="code"> <pre><span class="ln">428</span> */ <span class="ln">429</span> public function loadClass($class) <span class="ln">430</span> { <span class="ln">431</span> if ($file = $this->findFile($class)) { <span class="ln">432</span> $includeFile = self::$includeFile; <span class="error"><span class="ln error-ln">433</span> $includeFile($file); </span><span class="ln">434</span> <span class="ln">435</span> return true; <span class="ln">436</span> } <span class="ln">437</span> <span class="ln">438</span> return null; </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #3 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>Composer\Autoload\ClassLoader</strong>-><strong>loadClass</strong>("System") </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #4 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>spl_autoload_call</strong>("System") </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #5 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/pear/ole/OLE/PPS/Root.php(26): <strong>class_exists</strong>("System") </div> <div class="code"> <pre><span class="ln">21</span> <span class="ln">22</span> if (!class_exists('OLE_PPS')) { <span class="ln">23</span> require_once 'OLE/PPS.php'; <span class="ln">24</span> } <span class="ln">25</span> <span class="error"><span class="ln error-ln">26</span> if (!class_exists('System')) { </span><span class="ln">27</span> require_once 'System.php'; <span class="ln">28</span> } <span class="ln">29</span> <span class="ln">30</span> /** <span class="ln">31</span> * Class for creating Root PPS's for OLE containers </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #6 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(582): <strong>include</strong>("/opt/srv/www/htdocs/umfrage/vendor/pear/ole/OLE/PPS/Root.php") </div> <div class="code"> <pre><span class="ln">577</span> * <span class="ln">578</span> * @param string $file <span class="ln">579</span> * @return void <span class="ln">580</span> */ <span class="ln">581</span> self::$includeFile = \Closure::bind(static function($file) { <span class="error"><span class="ln error-ln">582</span> include $file; </span><span class="ln">583</span> }, null, null); <span class="ln">584</span> } <span class="ln">585</span> } </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #7 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(433): <strong>Composer\Autoload\{closure}</strong>("/opt/srv/www/htdocs/umfrage/vendor/composer/../pear/ole/OLE/PPS/...") </div> <div class="code"> <pre><span class="ln">428</span> */ <span class="ln">429</span> public function loadClass($class) <span class="ln">430</span> { <span class="ln">431</span> if ($file = $this->findFile($class)) { <span class="ln">432</span> $includeFile = self::$includeFile; <span class="error"><span class="ln error-ln">433</span> $includeFile($file); </span><span class="ln">434</span> <span class="ln">435</span> return true; <span class="ln">436</span> } <span class="ln">437</span> <span class="ln">438</span> return null; </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #8 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>Composer\Autoload\ClassLoader</strong>-><strong>loadClass</strong>("OLE_PPS_Root") </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #9 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>spl_autoload_call</strong>("OLE_PPS_Root") </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #10 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/pear/spreadsheet_excel_writer/Spreadsheet/Excel/Writer/Workbook.php(46): <strong>class_exists</strong>("OLE_PPS_Root") </div> <div class="code"> <pre><span class="ln">41</span> <span class="ln">42</span> if (!class_exists('OLE')) { <span class="ln">43</span> require_once 'OLE.php'; <span class="ln">44</span> } <span class="ln">45</span> <span class="error"><span class="ln error-ln">46</span> if (!class_exists('OLE_PPS_Root')) { </span><span class="ln">47</span> require_once 'OLE/PPS/Root.php'; <span class="ln">48</span> } <span class="ln">49</span> <span class="ln">50</span> if (!class_exists('OLE_PPS_File')) { <span class="ln">51</span> require_once 'OLE/PPS/File.php'; </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #11 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(582): <strong>include</strong>("/opt/srv/www/htdocs/umfrage/vendor/pear/spreadsheet_excel_writer...") </div> <div class="code"> <pre><span class="ln">577</span> * <span class="ln">578</span> * @param string $file <span class="ln">579</span> * @return void <span class="ln">580</span> */ <span class="ln">581</span> self::$includeFile = \Closure::bind(static function($file) { <span class="error"><span class="ln error-ln">582</span> include $file; </span><span class="ln">583</span> }, null, null); <span class="ln">584</span> } <span class="ln">585</span> } </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #12 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(433): <strong>Composer\Autoload\{closure}</strong>("/opt/srv/www/htdocs/umfrage/vendor/composer/../pear/spreadsheet_...") </div> <div class="code"> <pre><span class="ln">428</span> */ <span class="ln">429</span> public function loadClass($class) <span class="ln">430</span> { <span class="ln">431</span> if ($file = $this->findFile($class)) { <span class="ln">432</span> $includeFile = self::$includeFile; <span class="error"><span class="ln error-ln">433</span> $includeFile($file); </span><span class="ln">434</span> <span class="ln">435</span> return true; <span class="ln">436</span> } <span class="ln">437</span> <span class="ln">438</span> return null; </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #13 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>Composer\Autoload\ClassLoader</strong>-><strong>loadClass</strong>("Spreadsheet_Excel_Writer_Workbook") </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #14 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>spl_autoload_call</strong>("Spreadsheet_Excel_Writer_Workbook") </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #15 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/pear/spreadsheet_excel_writer/Spreadsheet/Excel/Writer.php(34): <strong>class_exists</strong>("Spreadsheet_Excel_Writer_Workbook") </div> <div class="code"> <pre><span class="ln">29</span> * You should have received a copy of the GNU Lesser General Public <span class="ln">30</span> * License along with this library; if not, write to the Free Software <span class="ln">31</span> * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA <span class="ln">32</span> */ <span class="ln">33</span> <span class="error"><span class="ln error-ln">34</span> if (!class_exists('Spreadsheet_Excel_Writer_Workbook')) { </span><span class="ln">35</span> require_once 'Spreadsheet/Excel/Writer/Workbook.php'; <span class="ln">36</span> } <span class="ln">37</span> <span class="ln">38</span> /** <span class="ln">39</span> * Class for writing Excel Spreadsheets. This class should change COMPLETELY. </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #16 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(582): <strong>include</strong>("/opt/srv/www/htdocs/umfrage/vendor/pear/spreadsheet_excel_writer...") </div> <div class="code"> <pre><span class="ln">577</span> * <span class="ln">578</span> * @param string $file <span class="ln">579</span> * @return void <span class="ln">580</span> */ <span class="ln">581</span> self::$includeFile = \Closure::bind(static function($file) { <span class="error"><span class="ln error-ln">582</span> include $file; </span><span class="ln">583</span> }, null, null); <span class="ln">584</span> } <span class="ln">585</span> } </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #17 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/composer/ClassLoader.php(433): <strong>Composer\Autoload\{closure}</strong>("/opt/srv/www/htdocs/umfrage/vendor/composer/../pear/spreadsheet_...") </div> <div class="code"> <pre><span class="ln">428</span> */ <span class="ln">429</span> public function loadClass($class) <span class="ln">430</span> { <span class="ln">431</span> if ($file = $this->findFile($class)) { <span class="ln">432</span> $includeFile = self::$includeFile; <span class="error"><span class="ln error-ln">433</span> $includeFile($file); </span><span class="ln">434</span> <span class="ln">435</span> return true; <span class="ln">436</span> } <span class="ln">437</span> <span class="ln">438</span> return null; </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #18 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>Composer\Autoload\ClassLoader</strong>-><strong>loadClass</strong>("Spreadsheet_Excel_Writer") </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #19 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/application/helpers/admin/statistics_helper.php(3835): <strong>spl_autoload_call</strong>("Spreadsheet_Excel_Writer") </div> <div class="code"> <pre><span class="ln">3830</span> */ <span class="ln">3831</span> if ($outputTarget == 'F') { <span class="ln">3832</span> $sFileName = $sTempDir . '/statistic-survey' . $surveyid . '.xls'; <span class="ln">3833</span> $this->workbook = new Spreadsheet_Excel_Writer($sFileName); <span class="ln">3834</span> } else { <span class="error"><span class="ln error-ln">3835</span> $this->workbook = new Spreadsheet_Excel_Writer(); </span><span class="ln">3836</span> } <span class="ln">3837</span> $this->workbook->setVersion(8); <span class="ln">3838</span> // Inform the module that our data will arrive as UTF-8. <span class="ln">3839</span> // Set the temporary directory to avoid PHP error messages due to open_basedir restrictions and calls to tempnam("", ...) <span class="ln">3840</span> $this->workbook->setTempDir($sTempDir); </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #20 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/application/controllers/admin/Statistics.php(475): <strong>statistics_helper</strong>-><strong>generate_statistics</strong>(838741, array("datestampE", "datestampG", "datestampL", "idG", ...), array("datestampE", "datestampG", "datestampL", "idG", ...), 1, ...) </div> <div class="code"> <pre><span class="ln">470</span> case 'pdf': <span class="ln">471</span> $helper->generate_statistics($surveyid, $summary, $summary, $usegraph, $outputType, 'D', $statlang); <span class="ln">472</span> exit; <span class="ln">473</span> break; <span class="ln">474</span> case 'xls': <span class="error"><span class="ln error-ln">475</span> $helper->generate_statistics($surveyid, $summary, $summary, $usegraph, $outputType, 'DD', $statlang); </span><span class="ln">476</span> exit; <span class="ln">477</span> break; <span class="ln">478</span> default: <span class="ln">479</span> break; <span class="ln">480</span> } </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #21 </td> <td class="content"> <div class="trace-file"> unknown(0): <strong>Statistics</strong>-><strong>run</strong>(838741, null) </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #22 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/actions/CAction.php(115): <strong>ReflectionMethod</strong>-><strong>invokeArgs</strong>(Statistics, array("838741", null)) </div> <div class="code"> <pre><span class="ln">110</span> elseif($param->isDefaultValueAvailable()) <span class="ln">111</span> $ps[]=$param->getDefaultValue(); <span class="ln">112</span> else <span class="ln">113</span> return false; <span class="ln">114</span> } <span class="error"><span class="ln error-ln">115</span> $method->invokeArgs($object,$ps); </span><span class="ln">116</span> return true; <span class="ln">117</span> } <span class="ln">118</span> } </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #23 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/application/core/SurveyCommonAction.php(83): <strong>CAction</strong>-><strong>runWithParamsInternal</strong>(Statistics, ReflectionMethod, array("surveyid" => "838741", "sa" => "index", "iSurveyId" => "838741", "iSurveyID" => "838741", ...)) </div> <div class="code"> <pre><span class="ln">78</span> $oMethod = new ReflectionMethod($this, $sDefault); <span class="ln">79</span> } <span class="ln">80</span> <span class="ln">81</span> // We're all good to go, let's execute it <span class="ln">82</span> // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params <span class="error"><span class="ln error-ln">83</span> return parent::runWithParamsInternal($this, $oMethod, $params); </span><span class="ln">84</span> } <span class="ln">85</span> <span class="ln">86</span> /** <span class="ln">87</span> * Some functions have different parameters, which are just an alias of the <span class="ln">88</span> * usual parameters we're getting in the url. This function just populates </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #24 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/CController.php(308): <strong>SurveyCommonAction</strong>-><strong>runWithParams</strong>(array("surveyid" => "838741", "sa" => "index", "iSurveyId" => "838741", "iSurveyID" => "838741", ...)) </div> <div class="code"> <pre><span class="ln">303</span> { <span class="ln">304</span> $priorAction=$this->_action; <span class="ln">305</span> $this->_action=$action; <span class="ln">306</span> if($this->beforeAction($action)) <span class="ln">307</span> { <span class="error"><span class="ln error-ln">308</span> if($action->runWithParams($this->getActionParams())===false) </span><span class="ln">309</span> $this->invalidActionParams($action); <span class="ln">310</span> else <span class="ln">311</span> $this->afterAction($action); <span class="ln">312</span> } <span class="ln">313</span> $this->_action=$priorAction; </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #25 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/CController.php(286): <strong>CController</strong>-><strong>runAction</strong>(Statistics) </div> <div class="code"> <pre><span class="ln">281</span> * @see runAction <span class="ln">282</span> */ <span class="ln">283</span> public function runActionWithFilters($action,$filters) <span class="ln">284</span> { <span class="ln">285</span> if(empty($filters)) <span class="error"><span class="ln error-ln">286</span> $this->runAction($action); </span><span class="ln">287</span> else <span class="ln">288</span> { <span class="ln">289</span> $priorAction=$this->_action; <span class="ln">290</span> $this->_action=$action; <span class="ln">291</span> CFilterChain::create($this,$action,$filters)->run(); </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #26 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/CController.php(265): <strong>CController</strong>-><strong>runActionWithFilters</strong>(Statistics, array()) </div> <div class="code"> <pre><span class="ln">260</span> { <span class="ln">261</span> if(($parent=$this->getModule())===null) <span class="ln">262</span> $parent=Yii::app(); <span class="ln">263</span> if($parent->beforeControllerAction($this,$action)) <span class="ln">264</span> { <span class="error"><span class="ln error-ln">265</span> $this->runActionWithFilters($action,$this->filters()); </span><span class="ln">266</span> $parent->afterControllerAction($this,$action); <span class="ln">267</span> } <span class="ln">268</span> } <span class="ln">269</span> else <span class="ln">270</span> $this->missingAction($actionID); </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #27 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/application/controllers/AdminController.php(202): <strong>CController</strong>-><strong>run</strong>("statistics") </div> <div class="code"> <pre><span class="ln">197</span> } <span class="ln">198</span> <span class="ln">199</span> $this->runModuleController($action); <span class="ln">200</span> <span class="ln">201</span> <span class="error"><span class="ln error-ln">202</span> return parent::run($action); </span><span class="ln">203</span> } <span class="ln">204</span> <span class="ln">205</span> /** <span class="ln">206</span> * Starting with LS4, 3rd party developer can extends any of the LimeSurve controllers. <span class="ln">207</span> * </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #28 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/CWebApplication.php(282): <strong>AdminController</strong>-><strong>run</strong>("statistics") </div> <div class="code"> <pre><span class="ln">277</span> { <span class="ln">278</span> list($controller,$actionID)=$ca; <span class="ln">279</span> $oldController=$this->_controller; <span class="ln">280</span> $this->_controller=$controller; <span class="ln">281</span> $controller->init(); <span class="error"><span class="ln error-ln">282</span> $controller->run($actionID); </span><span class="ln">283</span> $this->_controller=$oldController; <span class="ln">284</span> } <span class="ln">285</span> else <span class="ln">286</span> throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', <span class="ln">287</span> array('{route}'=>$route===''?$this->defaultController:$route))); </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #29 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/web/CWebApplication.php(141): <strong>CWebApplication</strong>-><strong>runController</strong>("admin/statistics/sa/index") </div> <div class="code"> <pre><span class="ln">136</span> foreach(array_splice($this->catchAllRequest,1) as $name=>$value) <span class="ln">137</span> $_GET[$name]=$value; <span class="ln">138</span> } <span class="ln">139</span> else <span class="ln">140</span> $route=$this->getUrlManager()->parseUrl($this->getRequest()); <span class="error"><span class="ln error-ln">141</span> $this->runController($route); </span><span class="ln">142</span> } <span class="ln">143</span> <span class="ln">144</span> /** <span class="ln">145</span> * Registers the core application components. <span class="ln">146</span> * This method overrides the parent implementation by registering additional core components. </pre> </div> </td> </tr> <tr class="trace core collapsed"> <td class="number"> #30 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/vendor/yiisoft/yii/framework/base/CApplication.php(185): <strong>CWebApplication</strong>-><strong>processRequest</strong>() </div> <div class="code"> <pre><span class="ln">180</span> public function run() <span class="ln">181</span> { <span class="ln">182</span> if($this->hasEventHandler('onBeginRequest')) <span class="ln">183</span> $this->onBeginRequest(new CEvent($this)); <span class="ln">184</span> register_shutdown_function(array($this,'end'),0,false); <span class="error"><span class="ln error-ln">185</span> $this->processRequest(); </span><span class="ln">186</span> if($this->hasEventHandler('onEndRequest')) <span class="ln">187</span> $this->onEndRequest(new CEvent($this)); <span class="ln">188</span> } <span class="ln">189</span> <span class="ln">190</span> /** </pre> </div> </td> </tr> <tr class="trace app collapsed"> <td class="number"> #31 </td> <td class="content"> <div class="trace-file"> <div class="plus">+</div> <div class="minus">–</div> /opt/srv/www/htdocs/umfrage/index.php(161): <strong>CApplication</strong>-><strong>run</strong>() </div> <div class="code"> <pre><span class="ln">156</span> require_once APPPATH . 'core/LSYii_Application' . EXT; <span class="ln">157</span> <span class="ln">158</span> $config = require_once(APPPATH . 'config/internal' . EXT); <span class="ln">159</span> <span class="ln">160</span> Yii::$enableIncludePath = false; <span class="error"><span class="ln error-ln">161</span> Yii::createApplication('LSYii_Application', $config)->run(); </span><span class="ln">162</span> <span class="ln">163</span> /* End of file index.php */ <span class="ln">164</span> /* Location: ./index.php */ </pre> </div> </td> </tr> </table> </div> <div class="version"> 2023-11-03 11:12:25 Apache <a href="https://www.yiiframework.com/">Yii Framework</a>/1.1.28 </div> </div> <script type="text/javascript"> /*<![CDATA[*/ var traceReg = new RegExp("(^|\\s)trace-file(\\s|$)"); var collapsedReg = new RegExp("(^|\\s)collapsed(\\s|$)"); var e = document.getElementsByTagName("div"); for (var j = 0, len = e.length; j < len; j++) { if (traceReg.test(e[j].className)) { e[j].onclick = function () { var trace = this.parentNode.parentNode; if (collapsedReg.test(trace.className)) trace.className = trace.className.replace("collapsed", "expanded"); else trace.className = trace.className.replace("expanded", "collapsed"); } } } /*]]>*/ </script> </body> </html> |
|
@mfavetti Please be aware PHP 8.2 is not officially supported. @babiel Could it be that the installation is missing files or got corrupted after the upgrade? |
|
your installation seems to be missing this file: vendor/pear/console_getopt/Console/Getopt.php can you try with a clean install? |
|
@mfavetti /opt/srv/www/htdocs/umfrage# ls -alh vendor/pear/console_getopt/Console/Getopt.php Therefore I attached strace to the fpm pool worker processes and logged what happened, when exporting to excel: strace.log The FPM pool currently has the following settings in effect: php_admin_value[allow_url_fopen] = off Several errors are logged because of missing files, but Getopt.php is not a part of it. |
|
That permission doesn't look good... |
|
www-data have read permission : not an issue here. Permission seems OK (except if vendor/pear/console_getopt/Console/ don't have execute permission for www-data) Esle : i can produce statistics on a simple survey with PHP8.2 |
|
Every folder has 0750 permission and is owned by www-data ls -alh /opt/srv/www/htdocs/umfrage/vendor/pear/console_getopt/ |
|
I've cut off the ls output by accident ls -alh /opt/srv/www/htdocs/umfrage/vendor/pear/console_getopt/ |
|
Seems OK for me … no idea :( |
|
@babiel I am not a keen on FPM, but I believe it just picks the main file, not includes. Are we sure the PHP process has access to the file? On the other side, can you try if there is any specific excel export which works? |
|
from my testing, permissions problem give "failed to open stream: Permission denied in", reported error is "failed to open stream: No such file or directory in" I've only been able to reproduce the issue by deleting the file. @babiel can you put your phpinfo? please also make test files in your limesurvey root with the following contents, open the location in browser, and report back on the output first test file: ini_set('display_errors', 1); require_once './vendor/autoload.php'; $test = new Spreadsheet_Excel_Writer(); and second test file: ini_set('display_errors', 1); var_dump(lstat('./vendor/pear/console_getopt/Console/Getopt.php')); |
|
You're right, my opinion : it's more an issue in autoload, maybe a deactivated function or something like this ? |
|
Did you guys see my last response? I've created it private, because it might contain some sensible informations. In the meantime I continued testing. I upgraded to PHP 8.1 but it didn't help. I then tested further and found, that Console/Getopt.php is shipped with PEAR and that my PEAR directory is /ush/share/php pear config-show | grep "PEAR directory" Getopt.php is installed in the system ls -alh /usr/share/php ls -alh /usr/share/php/Console/ But still the Excel export reports, that the file is missing. I then simply copied Getopt.php to /opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/ ls -alh /opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/ and now a new error is reported <h1>PHP warning</h1> so, now Getopt.php does not find PEAR.php, which exists. I then copied PEAR.php into /opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src/Console/ which gives me a new error <br /> It seems that the "missing" files are only searched locally and the globally available files are not used. Do you have any idea what's causing this? |
|
I have a new update. Our customer told me, that there is another way for exporting survey data. When I go to index.php/admin/export/sa/exportresults/surveyid/838741 and select "Microsoft Excel" as export type, I first get an error page, because /tmp has to be allowed in open_basedir settings. So I changed php_admin_value[sys_temp_dir] and now this works. Using this way, we can export to excel without issues. Is there a difference how the data is exported? Can the way of the statistics export be changed to the answer export? |
|
This seems to be a DevOps issue. Sorry to say, but this doens't seem to be a bug. |
|
After a lots of try and error I made it work. I don't know why, but I had to specifically set the needed pear directories of LimeSurvey inside the php-fpm pool for https://www.php.net/manual/en/ini.core.php#ini.include-path php_admin_value[include_path] = ".:/opt/srv/www/htdocs/umfrage/vendor/pear/console_getopt:/opt/srv/www/htdocs/umfrage/vendor/pear/pear-core-minimal/src" # umfrage is our LimeSurvey Root directory Maybe it is about how fpm "shields" the pool from global environment variables. However, if it didn't, it still wouldn't work, because when I set the PHP default <br /> Maybe you can document this as a possible issue when using php fpm in https://manual.limesurvey.org/Installation_FAQ ? In addition: |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2023-09-25 16:28 | babiel | New Issue | |
2023-09-29 09:18 | babiel | Note Added: 77434 | |
2023-09-29 09:18 | babiel | Bug heat | 6 => 8 |
2023-09-30 16:01 | DenisChenu | Relationship added | has duplicate 19137 |
2023-09-30 16:01 | DenisChenu | Bug heat | 8 => 14 |
2023-10-09 18:53 | gabrieljenik | Note Added: 77589 | |
2023-10-09 18:53 | gabrieljenik | Bug heat | 14 => 16 |
2023-10-16 10:55 | babiel | Note Added: 77729 | |
2023-10-26 11:07 | mfavetti | View Status | private => public |
2023-10-26 11:07 | mfavetti | Bug heat | 16 => 10 |
2023-10-26 11:07 | mfavetti | Note View State: 77434: public | |
2023-10-26 11:08 | mfavetti | Note View State: 77729: public | |
2023-10-26 11:08 | mfavetti | Note View State: 77589: public | |
2023-10-26 11:08 | mfavetti | Note Added: 78034 | |
2023-10-26 11:08 | mfavetti | Bug heat | 10 => 12 |
2023-10-27 09:53 | mfavetti | Note Added: 78074 | |
2023-10-27 09:54 | mfavetti | Note Added: 78075 | |
2023-10-27 09:58 | mfavetti | Note Edited: 78074 | |
2023-10-27 09:59 | mfavetti | Note Edited: 78075 | |
2023-10-27 12:13 | babiel | Note Added: 78086 | |
2023-10-28 22:52 | mfavetti | Issue Monitored: mfavetti | |
2023-10-28 22:52 | mfavetti | Bug heat | 12 => 14 |
2023-10-30 08:43 | DenisChenu | Note Added: 78115 | |
2023-10-30 08:43 | DenisChenu | Bug heat | 14 => 16 |
2023-10-30 08:45 | DenisChenu | Note Added: 78116 | |
2023-10-30 19:39 | gabrieljenik | Note Added: 78155 | |
2023-11-03 09:43 | mfavetti | Note Added: 78232 | |
2023-11-03 10:51 | babiel | Note Added: 78239 | |
2023-11-03 10:53 | mfavetti | Note Added: 78240 | |
2023-11-03 10:54 | babiel | Note Added: 78241 | |
2023-11-03 10:59 | mfavetti | Note Added: 78242 | |
2023-11-03 11:15 | babiel | Note Added: 78243 | |
2023-11-03 11:15 | babiel | File Added: LimeSurvey_excel_export_error.html | |
2023-11-03 12:48 | gabrieljenik | Note Added: 78244 | |
2023-11-03 12:48 | gabrieljenik | Status | new => acknowledged |
2023-11-03 20:03 | mfavetti | Note Added: 78264 | |
2023-11-06 11:05 | babiel | Note Added: 78278 | |
2023-11-06 11:05 | babiel | File Added: strace.log | |
2023-11-06 15:52 | gabrieljenik | Note Added: 78291 | |
2023-11-06 16:21 | DenisChenu | Note Added: 78292 | |
2023-11-06 16:25 | DenisChenu | Note Edited: 78292 | |
2023-11-06 16:27 | babiel | Note Added: 78293 | |
2023-11-06 16:29 | babiel | Note Added: 78294 | |
2023-11-06 17:25 | DenisChenu | Note Added: 78296 | |
2023-11-07 13:40 | gabrieljenik | Note Added: 78312 | |
2023-11-07 22:57 | mfavetti | Note Added: 78329 | |
2023-11-08 08:04 | DenisChenu | Note Added: 78330 | |
2023-11-20 16:06 | babiel | Note Added: 78544 | |
2023-11-27 14:03 | babiel | Note Added: 78734 | |
2023-11-27 14:03 | babiel | File Added: Bildschirmfoto vom 2023-11-27 13-13-46.png | |
2023-11-27 18:32 | gabrieljenik | Note Added: 78749 | |
2024-01-03 12:04 | babiel | Note Added: 79089 | |
2024-02-22 11:32 | mfavetti | Assigned To | => mfavetti |
2024-02-22 11:32 | mfavetti | Status | acknowledged => closed |
2024-02-22 11:32 | mfavetti | Resolution | open => no change required |