View Issue Details

This bug affects 2 person(s).
 20
IDProjectCategoryView StatusLast Update
19527Bug reports_ Unknownpublic2024-06-05 16:17
Reporterproveloict Assigned ToDenisChenu  
PrioritynoneSeverityblock 
Status closedResolutionfixed 
Product Version5.6.x 
Summary19527: After upgrading to 5.6.60 (240423) users cannot access surveys' list (error 500 - Invalid material template directory)
Description

Hello,

After upgrading (using ComfortUpdate) from 5.6.58 to 5.6.60, all users get this error when opening index.php?r=surveyAdministration/listsurveys:

500 : Internal Server Error
Invalid material template directory

Steps To Reproduce

Steps to reproduce

(Replace this text with detailed step-by-step instructions on how to reproduce the issue)

Expected result

(Write here what you expected to happen)

Actual result

(Write here what happened instead)

TagsNo tags attached.
Attached Files
Bug heat20
Complete LimeSurvey version number (& build)5.6.60+240423
I will donate to the project if issue is resolvedNo
BrowserAny
Database type & versionMariaDB 5.5
Server OS (if known)Ubuntu
Webserver software & version (if known)nginx
PHP Version7.4.33

Relationships

related to 19504 closedDenisChenu Potential PHP Warning when get Survey listing 

Users monitoring this issue

proveloict

Activities

FabianLucas

FabianLucas

2024-04-22 17:32

reporter   ~79965

We are also getting this error since today - however we are still on version 5.6.59 and did not actively update anything.

Kindregards

tibor.pacalat

tibor.pacalat

2024-04-22 17:38

administrator   ~79966

Last edited: 2024-04-22 17:40

@DenisChenu can you please look into this? It is caused by this commit https://github.com/LimeSurvey/LimeSurvey/pull/3786. I couldn't reproduce it on my local though, but already a couple users reported this issue.

proveloict

proveloict

2024-04-22 17:40

reporter   ~79967

Rolling back to 5.6.58 (same DB version) restored the normal behaviour.

DenisChenu

DenisChenu

2024-04-22 18:08

developer   ~79968

@proveloict : can you check with https://github.com/LimeSurvey/LimeSurvey/pull/3820

DenisChenu

DenisChenu

2024-04-22 18:12

developer   ~79969

@FabianLucas : try with replace the file models/Template.php with this one https://raw.githubusercontent.com/LimeSurvey/LimeSurvey/a413c130e65fa2ef2534c3cefd9cbdf7e6b78cd7/application/models/Template.php

proveloict

proveloict

2024-04-23 09:51

reporter   ~79977

@DenisChenu : I get the same error after upgrading again and applying the patch (https://github.com/LimeSurvey/LimeSurvey/pull/3820/files) manually.
(I downgraded again to keep the instance online).
Let me know if there is anything else I can do to help.

DenisChenu

DenisChenu

2024-04-23 10:22

developer   ~79978

@proveloict : can you show a SQL result ?

SELECT template_name, lime_templates.folder FROM lime_template_configuration LEFT JOIN lime_templates ON lime_template_configuration.template_name = lime_templates.name WHERE sid IS NULL and gsid is NULL; ?

proveloict

proveloict

2024-04-23 10:30

reporter   ~79982

@DenisChenu

I had to adapt the command because I don't have a prefix on the tables. So i ran
SELECT template_name, templates.folder FROM template_configuration LEFT JOIN templates ON template_configuration.template_name =templates.name WHERE sid IS NULL and gsid is NULL;

And the result was this:

+-------------------------+-------------------------+
| template_name           | folder                  |
+-------------------------+-------------------------+
| bootswatch              | bootswatch              |
| fruity                  | fruity                  |
| vanilla                 | vanilla                 |
| Pro_Velo_extends_fruity | Pro_Velo_extends_fruity |
| material                | material                |
| vanilla_pro_velo        | vanilla_pro_velo        |
| theBP                   | theBP                   |
+-------------------------+-------------------------+
7 rows in set (0.000 sec)
DenisChenu

DenisChenu

2024-04-23 10:33

developer   ~79983

And no material directory in ./theme/ right ?

DenisChenu

DenisChenu

2024-04-23 10:37

developer   ~79984

The issue came from getTemplateListWithPreviews … i didn't update this (broken function)

DenisChenu

DenisChenu

2024-04-23 12:33

developer   ~79986

I create the 2 lines … no way to reproduice …
I create a PR, but unsure if it work

proveloict

proveloict

2024-04-23 12:34

reporter   ~79987

@DenisChenu: indeed, no material direction in ./theme/

DenisChenu

DenisChenu

2024-04-23 13:03

developer   ~79988

PR for 5.X : https://github.com/LimeSurvey/LimeSurvey/pull/3829
Based on https://github.com/LimeSurvey/LimeSurvey/pull/3820 (need both)

Please try with : https://github.com/LimeSurvey/LimeSurvey/blob/1795f45d732d81d5065f0bf59d42f132f2ea618b/application/models/Template.php

tibor.pacalat

tibor.pacalat

2024-04-25 17:26

administrator   ~80006

I have merged both PRs into 5.x branch.
@DenisChenu is there anything else to be done regarding this ticket?

DenisChenu

DenisChenu

2024-04-25 17:28

developer   ~80007

Fix committed to 5.x branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36299

DenisChenu

DenisChenu

2024-04-25 17:28

developer   ~80008

Fix committed to 5.x branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36298

DenisChenu

DenisChenu

2024-04-25 17:35

developer   ~80010

Do the last one for 6/master
I do it now or tomorrow morning

DenisChenu

DenisChenu

2024-04-25 18:59

developer   ~80014

master : https://github.com/LimeSurvey/LimeSurvey/pull/3833

DenisChenu

DenisChenu

2024-04-26 08:45

developer   ~80016

For master : https://github.com/LimeSurvey/LimeSurvey/pull/3833

DenisChenu

DenisChenu

2024-04-26 16:06

developer   ~80021

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36311

DenisChenu

DenisChenu

2024-04-26 16:06

developer   ~80022

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36312

LimeBot

LimeBot

2024-04-29 16:36

administrator   ~80041

Fixed in Release 6.5.5+240429

Mazi

Mazi

2024-05-28 11:36

updater   ~80163

@DenisChenu, I get the exact same "Invalid material template directory" error with Version 5.6.65+240522 when calling the theme editor at /index.php/themeOptions/index. I already saw that at 2 customer systems, one self hosted, one hosted at limequery.com.
Is that a known issue @tibor.pacalat?

tibor.pacalat

tibor.pacalat

2024-05-28 14:13

administrator   ~80164

Last edited: 2024-05-28 14:14

@Mazi they should upgrade to 6.x. Support for 5.x ends: June 1st, 2024

Mazi

Mazi

2024-05-28 15:11

updater   ~80165

@tibor.pacalat: That can not be the solution. I see quite a lot of people upgrading new. But there are many larger companies or univesrities which usually update pretty late e.g. because of using many custom themes (which have to be re-build).
People still need to be able to access the theme editor any time. We can't force them to update by adding such a bug ;-)

tibor.pacalat

tibor.pacalat

2024-05-28 15:56

administrator   ~80166

@DenisChenu can you please take a look?

DenisChenu

DenisChenu

2024-05-28 18:55

developer   ~80167

Arg , i found the issue for Survey listing … but not found for Theme listing …

Let me check

Mazi

Mazi

2024-05-29 14:05

updater   ~80169

This issue may only show up for customers having updated from an older version at which the Material theme was available.

DenisChenu

DenisChenu

2024-05-29 14:46

developer   ~80170

Oh, i got it … it's new surely related to https://github.com/LimeSurvey/LimeSurvey/commit/82501703b34969c6601bffff507150ec2fccaf6c
and some other PR after :)

DenisChenu

DenisChenu

2024-05-29 15:21

developer   ~80171

5.X : https://github.com/LimeSurvey/LimeSurvey/pull/3858
master : https://github.com/LimeSurvey/LimeSurvey/pull/3859

Mazi

Mazi

2024-06-04 10:14

updater   ~80201

@tibor.pacalat: Can we integrate this important fix at the next 5.x release? We are no seeing this issue at multiple customer systems after having upgraded to 5.6.65.

tibor.pacalat

tibor.pacalat

2024-06-04 10:18

administrator   ~80202

@Mazi yes it will be a part of the next release.

DenisChenu

DenisChenu

2024-06-04 13:01

developer   ~80203

Fix committed to 5.x branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36382

DenisChenu

DenisChenu

2024-06-04 13:01

developer   ~80204

Fix committed to 5.x branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36381

LimeBot

LimeBot

2024-06-05 15:51

administrator   ~80215

Fixed in Release 6.5.11+240605

DenisChenu

DenisChenu

2024-06-05 16:17

developer   ~80217

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=36386

Related Changesets

LimeSurvey: 5.x 82501703

2024-04-25 19:19

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: surveys list throw error 500 with invalid template (#3829) Affected Issues
19527
mod - application/extensions/admin/survey/ListSurveysWidget/views/massive_actions/_select_survey_theme.php Diff File
mod - application/models/Template.php Diff File
mod - application/views/admin/survey/subview/_survey_quickaction.php Diff File
mod - application/views/admin/survey/subview/accordion/_generaloptions_panel.php Diff File
mod - application/views/admin/survey/surveySummary_view.php Diff File
mod - application/views/surveyAdministration/surveySummary_view.php Diff File

LimeSurvey: 5.x 82501703

2024-04-25 19:19

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: surveys list throw error 500 with invalid template (#3829) Affected Issues
19527
mod - application/extensions/admin/survey/ListSurveysWidget/views/massive_actions/_select_survey_theme.php Diff File
mod - application/models/Template.php Diff File
mod - application/views/admin/survey/subview/_survey_quickaction.php Diff File
mod - application/views/admin/survey/subview/accordion/_generaloptions_panel.php Diff File
mod - application/views/admin/survey/surveySummary_view.php Diff File
mod - application/views/surveyAdministration/surveySummary_view.php Diff File

LimeSurvey: master 597bdc1d

2024-04-26 17:59

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: Potential 500 error in survey list (03833) Affected Issues
19527
mod - application/extensions/admin/survey/ListSurveysWidget/views/massive_actions/_select_survey_theme.php Diff File
mod - application/models/Template.php Diff File
mod - application/views/admin/survey/subview/accordion/_generaloptions_panel.php Diff File
mod - application/views/surveyAdministration/surveySummary_view.php Diff File

LimeSurvey: master 597bdc1d

2024-04-26 17:59

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: Potential 500 error in survey list (03833) Affected Issues
19527
mod - application/extensions/admin/survey/ListSurveysWidget/views/massive_actions/_select_survey_theme.php Diff File
mod - application/models/Template.php Diff File
mod - application/views/admin/survey/subview/accordion/_generaloptions_panel.php Diff File
mod - application/views/surveyAdministration/surveySummary_view.php Diff File

LimeSurvey: 5.x 4f9c2f63

2024-06-04 14:49

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: Theme listing broke with invalid template (#3858) Affected Issues
19527
mod - application/models/TemplateConfiguration.php Diff File

LimeSurvey: 5.x 4f9c2f63

2024-06-04 14:49

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: Theme listing broke with invalid template (#3858) Affected Issues
19527
mod - application/models/TemplateConfiguration.php Diff File

LimeSurvey: master 47685a84

2024-06-05 17:17

DenisChenu

Committer: GitHub


Details Diff
Fixed issue 19527: Theme listing broke with invalid template (03859) Affected Issues
19527
mod - application/models/TemplateConfiguration.php Diff File

Issue History

Date Modified Username Field Change
2024-04-22 17:00 proveloict New Issue
2024-04-22 17:00 proveloict File Added: Screenshot 2024-04-22 at 16-59-32 CException.png
2024-04-22 17:32 FabianLucas Note Added: 79965
2024-04-22 17:32 FabianLucas Bug heat 0 => 2
2024-04-22 17:32 guest Bug heat 2 => 8
2024-04-22 17:37 proveloict Issue Monitored: proveloict
2024-04-22 17:37 proveloict Bug heat 8 => 10
2024-04-22 17:38 tibor.pacalat Assigned To => DenisChenu
2024-04-22 17:38 tibor.pacalat Status new => assigned
2024-04-22 17:38 tibor.pacalat Note Added: 79966
2024-04-22 17:38 tibor.pacalat Bug heat 10 => 12
2024-04-22 17:40 proveloict Note Added: 79967
2024-04-22 17:40 proveloict Bug heat 12 => 14
2024-04-22 17:40 tibor.pacalat Note Edited: 79966
2024-04-22 18:08 DenisChenu Note Added: 79968
2024-04-22 18:08 DenisChenu Bug heat 14 => 16
2024-04-22 18:09 DenisChenu Relationship added related to 19504
2024-04-22 18:09 DenisChenu Status assigned => feedback
2024-04-22 18:12 DenisChenu Note Added: 79969
2024-04-23 09:51 proveloict Note Added: 79977
2024-04-23 09:51 proveloict Status feedback => assigned
2024-04-23 10:22 DenisChenu Note Added: 79978
2024-04-23 10:30 proveloict Note Added: 79982
2024-04-23 10:33 DenisChenu Note Added: 79983
2024-04-23 10:37 DenisChenu Note Added: 79984
2024-04-23 12:33 DenisChenu Note Added: 79986
2024-04-23 12:34 proveloict Note Added: 79987
2024-04-23 13:03 DenisChenu Note Added: 79988
2024-04-25 17:26 tibor.pacalat Note Added: 80006
2024-04-25 17:28 DenisChenu Changeset attached => LimeSurvey 5.x 82501703
2024-04-25 17:28 DenisChenu Changeset attached => LimeSurvey 5.x 82501703
2024-04-25 17:28 DenisChenu Note Added: 80007
2024-04-25 17:28 DenisChenu Note Added: 80008
2024-04-25 17:28 DenisChenu Resolution open => fixed
2024-04-25 17:28 DenisChenu Resolution open => fixed
2024-04-25 17:35 DenisChenu Note Added: 80010
2024-04-25 18:59 DenisChenu Note Added: 80014
2024-04-26 08:45 DenisChenu Status assigned => ready for code review
2024-04-26 08:45 DenisChenu Note Added: 80016
2024-04-26 13:06 DenisChenu Assigned To DenisChenu => lajosarpad
2024-04-26 16:00 tibor.pacalat Status ready for code review => resolved
2024-04-26 16:06 DenisChenu Changeset attached => LimeSurvey master 597bdc1d
2024-04-26 16:06 DenisChenu Changeset attached => LimeSurvey master 597bdc1d
2024-04-26 16:06 DenisChenu Note Added: 80021
2024-04-26 16:06 DenisChenu Note Added: 80022
2024-04-26 16:06 DenisChenu Assigned To lajosarpad => DenisChenu
2024-04-26 16:06 DenisChenu Assigned To lajosarpad => DenisChenu
2024-04-29 16:36 LimeBot Note Added: 80041
2024-04-29 16:36 LimeBot Status resolved => closed
2024-04-29 16:36 LimeBot Bug heat 16 => 18
2024-05-28 11:36 Mazi Note Added: 80163
2024-05-28 11:36 Mazi Bug heat 18 => 20
2024-05-28 14:13 tibor.pacalat Note Added: 80164
2024-05-28 14:14 tibor.pacalat Note Edited: 80164
2024-05-28 15:11 Mazi Note Added: 80165
2024-05-28 15:56 tibor.pacalat Note Added: 80166
2024-05-28 18:55 DenisChenu Status closed => feedback
2024-05-28 18:55 DenisChenu Resolution fixed => reopened
2024-05-28 18:55 DenisChenu Note Added: 80167
2024-05-29 14:05 Mazi Note Added: 80169
2024-05-29 14:46 DenisChenu Note Added: 80170
2024-05-29 15:21 DenisChenu Note Added: 80171
2024-05-29 15:22 DenisChenu Assigned To DenisChenu => tibor.pacalat
2024-05-29 15:22 DenisChenu Status feedback => ready for code review
2024-06-04 10:14 Mazi Note Added: 80201
2024-06-04 10:18 tibor.pacalat Note Added: 80202
2024-06-04 13:01 DenisChenu Changeset attached => LimeSurvey 5.x 4f9c2f63
2024-06-04 13:01 DenisChenu Changeset attached => LimeSurvey 5.x 4f9c2f63
2024-06-04 13:01 DenisChenu Note Added: 80203
2024-06-04 13:01 DenisChenu Note Added: 80204
2024-06-04 13:01 DenisChenu Assigned To tibor.pacalat => DenisChenu
2024-06-04 13:01 DenisChenu Assigned To tibor.pacalat => DenisChenu
2024-06-04 13:01 DenisChenu Resolution reopened => fixed
2024-06-04 13:01 DenisChenu Resolution reopened => fixed
2024-06-05 15:17 tibor.pacalat Status ready for code review => resolved
2024-06-05 15:51 LimeBot Note Added: 80215
2024-06-05 15:51 LimeBot Status resolved => closed
2024-06-05 16:17 DenisChenu Changeset attached => LimeSurvey master 47685a84
2024-06-05 16:17 DenisChenu Note Added: 80217