You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
finfo detects TrueType fonts as application/octet-stream since libmagic 5.48 #25051
Resulted in this output on PHP 8.6.0-dev (PHP-8.6 branch, libmagic 5.48):
string(24) "application/octet-stream"
But I expected this output instead (PHP 8.5.12, libmagic 5.46):
string(9) "font/sfnt"
This is an upstream regression from the FontKit rule added in file 5.48. It was fixed upstream in file/file@ba72caa54b ("TrueType fonts lose their MIME type since the FontKit change"). Loading the upstream magic from master with libmagic 5.48 gives font/ttf for the same file. Upstream changed the TrueType MIME type from font/sfnt to font/ttf earlier, in file/file@6481672a8e.
OTF, WOFF and WOFF2 are detected as before. The font I used is tests/phpunit/data/fonts/OpenSans-Regular.ttf from wordpress-develop. WordPress font uploads of TTF files fail on 8.6 because of this.
PHP Version
PHP 8.6.0-dev (cli) (built: Oct 24 2026 22:20:09) (NTS)
Okay I will check through the upstream repo to see if there are other regressions. I plan to do it before GA cuz I am really busy recently.
Let's first fix this #25063
7. Okay I will check through the upstream repo to see if there are other regressions. I plan to do it before GA cuz I am really busy recently.
Let's first fix this #25063
Note that this should be done before 8.6.0 is branched, which happens at the last RC, i.e. is expected on Tuesday, November 3rd. After that the 8.6 branch is for 8.6.1 and you would need one of the 8.6 release managers to cherry pick the fix to the release branch
Activity
DanielEScherzer commentedon Oct 30, 2026
@LamentXU123 is this something we can fix before the next 8.6 RC to avoid a regression? And/or should we consider reverting the upgrade?
LamentXU123 commentedon Oct 30, 2026
@DanielEScherzer Hmm, seems like all we need to do is just to backport file/file@ba72caa54b ?
DanielEScherzer commentedon Oct 30, 2026
No idea if there are also other parts that need to be updated, figured you would know and wanted to draw your attention to this
LamentXU123 commentedon Oct 30, 2026
Okay I will check through the upstream repo to see if there are other regressions. I plan to do it before GA cuz I am really busy recently.
Let's first fix this #25063
DanielEScherzer commentedon Oct 30, 2026
Note that this should be done before 8.6.0 is branched, which happens at the last RC, i.e. is expected on Tuesday, November 3rd. After that the 8.6 branch is for 8.6.1 and you would need one of the 8.6 release managers to cherry pick the fix to the release branch