Page 1 of 1

Error on TEST server but not on PROD, any suggestions?

Posted: 03 May 2022, 16:10
by mushu
Windows Server 2012R2
Mantis 2.25.2
PHP 7.4.26

Any thoughts on what could be wrong? I've copied the entire EmailReporting directory in Plugins from PROD to TEST. I also copied the updated core\template_api.php file from PROD to TEST (and the templates). PROD is working perfectly and tests fine on the production mailbox. We've set up a different mailbox to try to get Azure cloud email working, and did the mailbox "Test" function, but get this result:

Code: Select all

SYSTEM WARNING

'"continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?' in 'C:\MantisBT2252\plugins\EmailReporting\core\Mail\Markdownify\Converter.php' line 349

Please use the "Back" button in your web browser to return to the previous page. There you can correct whatever problems were identified in this error or select another action. You can also click an option from the menu bar to go directly to a new section.
Detailed error information
Full path: C:\MantisBT2252\plugins\EmailReporting\core\Mail\Markdownify\Converter.php
Line number: 349
Stack trace
#	Filename	Line	Class	Type	Function	Args
0	C:\MantisBT2252\core\plugin_api.php	907	-	-	require_once	-
1	C:\MantisBT2252\plugins\EmailReporting\core\Mail\Parser.php	6	-	-	plugin_require_api	<string>'core/Mail/Markdownify/Converter.php'
2	C:\MantisBT2252\core\plugin_api.php	907	-	-	require_once	<string>'C:\\MantisBT2252\\plugins\\EmailReporting\\core\\Mail\\Parser.php'
3	C:\MantisBT2252\plugins\EmailReporting\core\mail_api.php	24	-	-	plugin_require_api	<string>'core/Mail/Parser.php'
4	C:\MantisBT2252\core\plugin_api.php	907	-	-	require_once	<string>'C:\\MantisBT2252\\plugins\\EmailReporting\\core\\mail_api.php'
5	C:\MantisBT2252\plugins\EmailReporting\pages\manage_mailbox_edit.php	65	-	-	plugin_require_api	<string>'core/mail_api.php'
6	C:\MantisBT2252\plugin.php	74	-	-	include	<string>'C:\\MantisBT2252\\plugins\\EmailReporting\\pages\\manage_mailbox_edit.php'

Re: Error on TEST server but not on PROD, any suggestions?

Posted: 04 May 2022, 06:33
by cas
I suggest to start first to get emailreporting running on the clean install :!: . Once that is working, start activating the mailtemplate part :mrgreen:

Re: Error on TEST server but not on PROD, any suggestions?

Posted: 04 May 2022, 14:54
by SL-Gundam
This has to do with the PHP version.
I suspect that's different between the 2 environments. Or maybe just the error reporting ini configuration options.
It seems Markdownify has fixed this in the version currently included with the DEV version of EmailReporting.
Please try the latest DEV version: https://github.com/mantisbt-plugins/EmailReporting

Re: Error on TEST server but not on PROD, any suggestions?

Posted: 04 May 2022, 15:06
by mushu
It was working fine on TEST before I copied over the entire EmailReporting directory from PROD, plus the template files, plus ensured the directories were correct in the main config file. If I copy the old EmailReporting directory back in it would work like before.

That server is running PHP Version 7.4.26 the same as on PROD.

EDIT: the question is, why would it be working on one server but then not working when the entire directory was copied onto the other server?

EDIT2: I am running the latest plugin version, per the plugins window in Mantis:

Code: Select all

Email Reporting 0.10.1	Offers the functionality to add issues and notes by email.
Author: Indy and various people after him.
Website: http://www.mantisbt.org/wiki/doku.php/mantisbt:plugins:emailreporting	MantisBT Core 1.3.0, <2.99.99	
3

Re: Error on TEST server but not on PROD, any suggestions?

Posted: 04 May 2022, 16:36
by mushu
So it appears that the version of EmailReporting wasn't changed when the last edits were made, so my installed version says it is the latest 0.10.1 but the code itself is not the same as what's up on git. Ugh.

Re: Error on TEST server but not on PROD, any suggestions?

Posted: 23 May 2022, 13:09
by SL-Gundam
0.10.1 is a stable release version.
The code on git is version 0.11.0-DEV

You can try upgrading to that version and see if it works better.