View Issue Details

IDProjectCategoryView StatusLast Update
0002319XdebugUncategorizedpublic2026-01-08 17:44
Reporterskateprokim Assigned Toderick  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version3.3.2 
Target Version3.4devFixed in Version3.4.2 
Summary0002319: emoji character become diamond question marks
Description

PHP 8.3.2.

Without Xdebug:
It shows the emoji character.

With Xdebug:
It shows diamon question marks instead of the emoji character, which is unexpected.

Steps To Reproduce

Script:
<?php
$str = 'hello X'; //replace X with an emoji
var_dump(
$str
);
?>

Additional Information

I am unable to images, as I keep getting errors.

Tagsvar_dump
Attached Files
emoji-var_dump-nativephp.png (1,456 bytes)   
emoji-var_dump-nativephp.png (1,456 bytes)   
emoji-var_dump-xdebug.png (1,708 bytes)   
emoji-var_dump-xdebug.png (1,708 bytes)   
Operating System
PHP Version8.3.5-8.3.9

Relationships

has duplicate 0002320 resolvedderick var_dump does not output 16 characters in Windows-1251 
related to 0002313 closedderick var_dump does not output some Russian characters 

Activities

skateprokim

2025-02-13 12:07

reporter   ~0007176

Adding the actual emoji character gives tracker error and "\xEF\xBF\xBD\x0D\x0AA" is being shown.

skateprokim

2025-02-13 12:10

reporter   ~0007177

PHP version range is wrong. I must have forgot to repick, as I had to try multiple times to create this issue.
8.3.2 is correct.

derick

2025-02-18 11:44

administrator   ~0007178

Yeah, the issue tracker still uses the old MySQL character set that doesn't use emojis.

I can't reproduce this on the command line, but curiously, I can in the browser.

For some reason, Xdebug drops the first byte of the emoji (\xf0):

Correct:

0000   73 74 72 69 6e 67 28 31 30 29 20 22 68 65 6c 6c   string(10) "hell
0010   6f 20 f0 9f 91 8d 22 0a                           o ....".

Incorrect:

0000   3c 73 6d 61 6c 6c 3e 2f 74 6d 70 2f 32 33 31 39   <small>/tmp/2319
0010   2e 70 68 70 3a 33 3a 3c 2f 73 6d 61 6c 6c 3e 3c   .php:3:</small><
0020   73 6d 61 6c 6c 3e 73 74 72 69 6e 67 3c 2f 73 6d   small>string</sm
0030   61 6c 6c 3e 20 3c 66 6f 6e 74 20 63 6f 6c 6f 72   all> <font color
0040   3d 27 23 63 63 30 30 30 30 27 3e 27 68 65 6c 6c   ='#cc0000'>'hell
0050   6f 20 9f 91 8d 27 3c 2f 66 6f 6e 74 3e 20 3c 69   o ...'</font> <i
0060   3e 28 6c 65 6e 67 74 68 3d 31 30 29 3c 2f 69 3e   >(length=10)</i>
0070   0a                                                .

derick

2025-02-18 12:39

administrator   ~0007180

https://github.com/xdebug/xdebug/pull/997

derick

2025-02-19 07:48

administrator   ~0007183

https://github.com/xdebug/xdebug/actions/runs/13402799357#artifacts

derick

2025-02-21 14:20

administrator   ~0007186

Fixed for 3.4.2

Issue History

Date Modified Username Field Change
2025-02-13 12:03 skateprokim New Issue
2025-02-13 12:03 skateprokim Tag Attached: var_dump
2025-02-13 12:03 skateprokim File Added: emoji-var_dump-nativephp.png
2025-02-13 12:03 skateprokim File Added: emoji-var_dump-xdebug.png
2025-02-13 12:07 skateprokim Note Added: 0007176
2025-02-13 12:10 skateprokim Note Added: 0007177
2025-02-18 11:44 derick Note Added: 0007178
2025-02-18 11:44 derick Assigned To => derick
2025-02-18 11:44 derick Status new => assigned
2025-02-18 11:44 derick Target Version => 3.4dev
2025-02-18 12:39 derick Note Added: 0007180
2025-02-19 07:48 derick Note Added: 0007183
2025-02-21 14:20 derick Status assigned => closed
2025-02-21 14:20 derick Resolution open => fixed
2025-02-21 14:20 derick Fixed in Version => 3.4dev
2025-02-21 14:20 derick Note Added: 0007186
2025-03-09 16:01 derick Relationship added related to 0002313
2025-03-09 16:08 derick Fixed in Version 3.4dev => 3.4.2
2025-04-04 10:43 derick Relationship added has duplicate 0002320
2026-01-08 17:44 derick View Status private => public