View Issue Details

IDProjectCategoryView StatusLast Update
0023549mantisbtdb mysqlpublic2017-12-01 20:29
Reporterc_schmitzAssigned Toatrol 
PrioritynormalSeveritycrashReproducibilityalways
Status feedbackResolutionreopened 
Product Version2.7.0 
Target VersionFixed in Version 
Summary0023549: Entering Emojis in comments with a user mention crashes with an error
Description

When entering an emoji in a comment field along with a mention of a username Mantis crashes with error message

APPLICATION ERROR 0000401

Database query failed. Error received from database was 0001366: Incorrect string value: '\xF0\x9F\x98\xB1' for column 'body' at row 1 for the query: INSERT INTO mantis_email_table
( email, subject, body, submitted, metadata)
VALUES
(?,?,?,?,?).
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.

Steps To Reproduce

Added a comment to a existing bug like:

"hey @someuser , that is so bad <some_emoji>"

After posting the above crash message appears.

TagsNo tags attached.

Relationships

related to 0020431 assigneddregad Use utf8mb4 charset for new MySQL installations 
related to 0021101 closeddregad Issues with emoji's are truncated before getting saved 

Activities

c_schmitz

c_schmitz

2017-10-26 06:30

reporter   ~0058061

Related to 0021101

atrol

atrol

2017-10-26 07:07

developer   ~0058062

Last edited: 2017-10-26 07:08

View 2 revisions

I am too old to understand the importance of this emoji stuff https://www.mantisbt.org/forums/viewtopic.php?f=2&t=24787

atrol

atrol

2017-10-26 07:38

developer   ~0058064

c_schmitz, I was not able to reproduce your problem with a fresh install of 2.7.0

Please provide detailed step-by-step instructions to reproduce the issue; the following additional information may also be useful:

  • Do you get any errors/or warnings (especially related to utf-8) when runing admin/check/index.php ?
  • Exact version of PHP, Database, Web server and Operating System
  • Relevant customizations (e.g. changes in config_inc.php, etc)
  • Installed plugins or custom functions ?
  • Was the MantisBT source code modified in any way ?
c_schmitz

c_schmitz

2017-10-26 08:38

reporter   ~0058065

@atrol Let me try here: �

atrol

atrol

2017-10-26 08:42

developer   ~0058066

Setting again to waiting for more feedback

atrol

atrol

2017-10-26 10:38

developer   ~0058069

I am wondering that your config_inc.php does not contain any setting for $g_db_type
It must not be set in config_inc.php as there is a default for it in config_defaults_inc.php, but it's quite typical to set it.
Can I be sure that you did not change config_defaults_inc.php, so that $g_db_type is set to 'mysqli' ?

Can you confirm that column body of table mantis_email_table is of type longtext, character set is utf8 and collation is utf8_general_ci ?

atrol

atrol

2017-11-05 07:54

developer   ~0058135

c_schmitz,

You did not provide feedback; I am therefore resolving this issue as "no change required".

Feel free to reopen the issue at a later time and provide the requested information.

c_schmitz

c_schmitz

2017-11-16 11:35

reporter   ~0058212

Can I be sure that you did not change config_defaults_inc.php, so that $g_db_type is set to 'mysqli' ?

config_defaults is unmodified and the factory one.

Can you confirm that column body of table mantis_email_table is of type longtext, character set is utf8 and collation is utf8_general_ci ?

I can confirm that.

atrol

atrol

2017-12-01 20:29

developer   ~0058298

I am still not able to reproduce the issue using the given information.
I tried on different test systems, of course they are not exactly the same than yours.
I use other PHP versions (newer ones and older ones) and Apache as web server.
Maybe you can try newer PHP versions.

Did you check for errors or warnings in Web server, PHP or Database log ?

Issue History

Date Modified Username Field Change
2017-10-26 06:29 c_schmitz New Issue
2017-10-26 06:30 c_schmitz Note Added: 0058061
2017-10-26 07:04 atrol Relationship added related to 0020431
2017-10-26 07:04 atrol Relationship added related to 0021101
2017-10-26 07:07 atrol Note Added: 0058062
2017-10-26 07:08 atrol Note Edited: 0058062 View Revisions
2017-10-26 07:38 atrol Status new => feedback
2017-10-26 07:38 atrol Note Added: 0058064
2017-10-26 08:38 c_schmitz Note Added: 0058065
2017-10-26 08:38 c_schmitz Status feedback => new
2017-10-26 08:42 atrol Status new => feedback
2017-10-26 08:42 atrol Note Added: 0058066
2017-10-26 08:44 atrol Priority high => normal
2017-10-26 08:52 c_schmitz Status feedback => new
2017-10-26 10:38 atrol Status new => feedback
2017-10-26 10:38 atrol Note Added: 0058069
2017-11-05 07:54 atrol Assigned To => atrol
2017-11-05 07:54 atrol Status feedback => resolved
2017-11-05 07:54 atrol Resolution open => no change required
2017-11-05 07:54 atrol Note Added: 0058135
2017-11-16 11:13 atrol Status resolved => closed
2017-11-16 11:35 c_schmitz Status closed => feedback
2017-11-16 11:35 c_schmitz Resolution no change required => reopened
2017-11-16 11:35 c_schmitz Note Added: 0058212
2017-12-01 20:29 atrol Note Added: 0058298