#110738CreateRecordReactionTest fails on MySQL due to JSON key order of the stored field map
Description
The nightly main pipeline 108775 failed in the functional MySQL jobs, chunk 4 of 6, on both MySQL 8.0 min and MySQL 8.4 max. The sqlite, mariadb and postgres jobs of the same pipeline passed.
Failing tests:
- TYPO3\CMS\Reactions\Tests\Functional\Reaction\CreateRecordReactionTest::reactNamesEveryFieldItSkippedWhateverTheReasonWas
- TYPO3\CMS\Reactions\Tests\Functional\Reaction\CreateRecordReactionTest::reactSkipsKeysTheFieldMapDoesNotOffer
Both compare the skippedFields part of the reaction response against an array literal with assertSame. The reported entries are the same on every DBMS, only their order differs.
Cause: the field map of a reaction is stored in sys_reaction.fields, a TCA type json column, which DefaultTcaSchema maps to a native JSON column. MySQL normalises a JSON object on write and keeps its keys ordered by key length first and bytewise second, while mariadb, sqlite and postgres preserve the order of the written document. CreateRecordReaction walks the decoded map in stored order, so the response lists the skipped fields in that order.
Verified with a temporary functional test that dumps the key order of the stored map per DBMS. For the fixture row with uid 15, MySQL returns title, fe_group, nonsense, perms_everybody, while sqlite returns title, perms_everybody, fe_group, nonsense.
The response content is correct on every DBMS. The order of the reported fields is not part of the contract, so the two assertions have to be independent of it.
Introduced together with the feature of issue #110704, which targets main only. The fix is therefore needed on main only.
Reviews 1
Related issues 1
History 34
-
Stefan Bürk changed Related to #110704 <span data-processor="relativetime" data-value="2026-09-18T03:20:14+00:00" > 09/18/26, 03:20 </span>
-
Stefan Bürk changed category assigned to Stefan Bürk <span data-processor="relativetime" data-value="2026-09-18T03:27:00+00:00" > 09/18/26, 03:27 </span>
-
Gerrit Code Review pushed patch set 1 for main to change 95907 status
NewUnder Review <span data-processor="relativetime" data-value="2026-09-18T03:34:02+00:00" > 09/18/26, 03:34 </span> -
Stefan Bürk commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2026-09-18T05:45:12+00:00" > 09/18/26, 05:45 </span>
Applied in changeset commit:2f4dc9c68d9aa1b3f20cf390dd274534342bf8ad.