Compliance cases

These are the 7,246 inputs a submission must answer. A conforming implementation returns true for the 2,791 valid ones and false for the 4,455 invalid ones. You can run the suite without reading it, or open any case to see its input and where its first ill-formed byte is.

Well-formed means Table 3-7 of the Unicode Standard, as RFC 3629 restates it: no overlong forms, surrogates, code points above U+10FFFF, stray continuation bytes or sequences cut short. The compliance suite combines Markus Kuhn's UTF-8 stress test, WPT's fatal TextDecoder tests, every lead byte against the edges of its allowed ranges, errors at every offset around 16-, 32- and 64-byte blocks and at the end of every length up to 130 bytes, large inputs, and seeded random text. simdutf, Python and a Table 3-7 reference agree on every answer.

Run the full compliance suite locally. Replace your-component.wasm with your compiled component. Download the suite

curl -fLo validate_utf8.comply.wasm https://calculated.world/comply/validate_utf8.wasm
npx qipok your-component.wasm --suite validate_utf8.comply.wasm

All 7,246 cases · 2,791 true · 4,455 false

Case Name Expected Note Size
006850 generated/1587 Generated true Seeded random text, mutation: none. 8 B
006851 generated/1588 Generated true Seeded random text, mutation: none. 12 B
006852 generated/1589 Generated false Seeded random text, mutation: replace byte. 61 B
006853 generated/1590 Generated false Seeded random text, mutation: truncate. 112 B
006854 generated/1591 Generated true Seeded random text, mutation: truncate. 2 B
006855 generated/1593 Generated false Seeded random text, mutation: flip bit. 3 B
006856 generated/1594 Generated true Seeded random text, mutation: none. 370 B
006857 generated/1595 Generated false Seeded random text, mutation: delete byte. 235 B
006858 generated/1596 Generated true Seeded random text, mutation: none. 149 B
006859 generated/1597 Generated true Seeded random text, mutation: none. 43 B
006860 generated/1598 Generated false Seeded random text, mutation: delete byte. 27 B
006861 generated/1599 Generated false Seeded random text, mutation: delete byte. 360 B
006862 generated/1600 Generated true Seeded random text, mutation: none. 397 B
006863 generated/1601 Generated false Seeded random text, mutation: insert byte. 11 B
006864 generated/1602 Generated true Seeded random text, mutation: none. 19 B
006865 generated/1603 Generated true Seeded random text, mutation: none. 139 B
006866 generated/1604 Generated false Seeded random text, mutation: insert byte. 70 B
006867 generated/1605 Generated true Seeded random text, mutation: none. 121 B
006868 generated/1606 Generated false Seeded random text, mutation: insert byte. 27 B
006869 generated/1607 Generated false Seeded random text, mutation: replace byte. 7 B
006870 generated/1608 Generated false Seeded random text, mutation: truncate. 2 B
006871 generated/1609 Generated true Seeded random text, mutation: none. 67 B
006872 generated/1610 Generated false Seeded random text, mutation: splice bad sequence. 31 B
006873 generated/1611 Generated true Seeded random text, mutation: truncate. 38 B
006874 generated/1612 Generated true Seeded random text, mutation: flip bit. 12 B
006875 generated/1613 Generated true Seeded random text, mutation: none. 35 B
006876 generated/1614 Generated true Seeded random text, mutation: none. 233 B
006877 generated/1615 Generated false Seeded random text, mutation: delete byte. 12 B
006878 generated/1616 Generated false Seeded random text, mutation: flip bit. 9 B
006879 generated/1617 Generated true Seeded random text, mutation: none. 58 B
006880 generated/1619 Generated false Seeded random text, mutation: insert byte. 363 B
006881 generated/1620 Generated false Seeded random text, mutation: replace byte. 71 B
006882 generated/1621 Generated true Seeded random text, mutation: none. 7 B
006883 generated/1623 Generated true Seeded random text, mutation: replace byte. 191 B
006884 generated/1624 Generated true Seeded random text, mutation: none. 4 B
006885 generated/1625 Generated true Seeded random text, mutation: none. 56 B
006886 generated/1626 Generated true Seeded random text, mutation: replace byte. 61 B
006887 generated/1627 Generated false Seeded random text, mutation: insert byte. 44 B
006888 generated/1628 Generated true Seeded random text, mutation: truncate. 63 B
006889 generated/1629 Generated false Seeded random text, mutation: splice bad sequence. 77 B
006890 generated/1630 Generated false Seeded random text, mutation: splice bad sequence. 74 B
006891 generated/1631 Generated false Seeded random text, mutation: insert byte. 3 B
006892 generated/1632 Generated true Seeded random text, mutation: none. 66 B
006893 generated/1633 Generated true Seeded random text, mutation: none. 39 B
006894 generated/1634 Generated true Seeded random text, mutation: none. 227 B
006895 generated/1635 Generated true Seeded random text, mutation: none. 17 B
006896 generated/1636 Generated false Seeded random text, mutation: splice bad sequence. 182 B
006897 generated/1637 Generated false Seeded random text, mutation: splice bad sequence. 383 B
006898 generated/1638 Generated false Seeded random text, mutation: replace byte. 171 B
006899 generated/1639 Generated true Seeded random text, mutation: none. 297 B

Where these rules come from

Well-formed UTF-8 is defined by Table 3-7 of the Unicode Standard, chapter 3 , which RFC 3629 restates as ABNF. Every answer is agreed by simdutf 9.4.0, Python’s strict codec and a direct reading of the table; the suite’s own tests add Node.js’s buffer.isUtf8 and a fatal TextDecoder.