php / php/php-src

Test failures with musl libc

Open
#22,413 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Bug Category: Tests Status: Verified
Dominant language
C
Stars
40.4k
Forks
8.1k
Avg merge
2d 13h
Merged PRs (30d)
96

Description

Description

Follow-up to https://github.com/php/php-src/issues/13696. Musl is partially tested on the CI, but the Alpine job installs gnu-libiconv-dev which hides the following errors. With the latest php-8.5.7 release:

=====================================================================
FAILED TEST SUMMARY
---------------------------------------------------------------------
Bug #48147 (iconv with //IGNORE cuts the string) [ext/iconv/tests/bug48147.phpt]
Bug #52211 (iconv() returns part of string on error) [ext/iconv/tests/bug52211.phpt]
Bug #76249 (stream filter convert.iconv leads to infinite loop on invalid sequence) [ext/iconv/tests/bug76249.phpt]
EUC-JP to ISO-2022-JP [ext/iconv/tests/eucjp2iso2022jp.phpt]
iconv_mime_encode() [ext/iconv/tests/iconv_mime_encode.phpt]

I have an old PR at https://github.com/php/php-src/pull/16840 whose details I've mostly forgotten. I can start by cherry-picking the easy parts of that.

PHP Version
PHP 8.5.7
Operating System

Gentoo linux

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Alpine CI job and the failing tests in ext/iconv/tests/, especially bug48147.phpt, bug52211.phpt, bug76249.phpt, eucjp2iso2022jp.phpt, and iconv_mime_encode.phpt. Compare the job with and without gnu-libiconv-dev, then review the related work in PR 16840. Done means the listed tests pass against musl without that package masking the failures.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux, php
Domain
operating-systems, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.