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
007000 generated/1743 Generated false Seeded random text, mutation: delete byte. 89 B
007001 generated/1744 Generated true Seeded random text, mutation: none. 6 B
007002 generated/1745 Generated true Seeded random text, mutation: none. 12 B
007003 generated/1746 Generated false Seeded random text, mutation: truncate. 66 B
007004 generated/1747 Generated true Seeded random text, mutation: none. 12 B
007005 generated/1748 Generated true Seeded random text, mutation: none. 388 B
007006 generated/1749 Generated true Seeded random text, mutation: none. 9 B
007007 generated/1750 Generated false Seeded random text, mutation: insert byte. 76 B
007008 generated/1751 Generated true Seeded random text, mutation: truncate. 11 B
007009 generated/1752 Generated false Seeded random text, mutation: splice bad sequence. 54 B
007010 generated/1753 Generated true Seeded random text, mutation: none. 11 B
007011 generated/1754 Generated true Seeded random text, mutation: none. 3 B
007012 generated/1755 Generated false Seeded random text, mutation: splice bad sequence. 75 B
007013 generated/1756 Generated true Seeded random text, mutation: none. 58 B
007014 generated/1757 Generated true Seeded random text, mutation: none. 167 B
007015 generated/1758 Generated false Seeded random text, mutation: truncate. 7 B
007016 generated/1759 Generated false Seeded random text, mutation: delete byte. 14 B
007017 generated/1760 Generated true Seeded random text, mutation: flip bit. 176 B
007018 generated/1761 Generated false Seeded random text, mutation: insert byte. 219 B
007019 generated/1762 Generated true Seeded random text, mutation: none. 168 B
007020 generated/1763 Generated true Seeded random text, mutation: none. 9 B
007021 generated/1764 Generated false Seeded random text, mutation: insert byte. 12 B
007022 generated/1765 Generated true Seeded random text, mutation: none. 7 B
007023 generated/1766 Generated true Seeded random text, mutation: truncate. 14 B
007024 generated/1767 Generated false Seeded random text, mutation: replace byte. 17 B
007025 generated/1768 Generated false Seeded random text, mutation: flip bit. 56 B
007026 generated/1769 Generated true Seeded random text, mutation: none. 19 B
007027 generated/1770 Generated true Seeded random text, mutation: none. 58 B
007028 generated/1771 Generated true Seeded random text, mutation: delete byte. 15 B
007029 generated/1772 Generated false Seeded random text, mutation: replace byte. 52 B
007030 generated/1773 Generated false Seeded random text, mutation: truncate. 15 B
007031 generated/1774 Generated false Seeded random text, mutation: insert byte. 192 B
007032 generated/1776 Generated true Seeded random text, mutation: replace byte. 11 B
007033 generated/1777 Generated true Seeded random text, mutation: replace byte. 227 B
007034 generated/1778 Generated true Seeded random text, mutation: none. 6 B
007035 generated/1779 Generated true Seeded random text, mutation: flip bit. 13 B
007036 generated/1780 Generated true Seeded random text, mutation: none. 8 B
007037 generated/1781 Generated false Seeded random text, mutation: splice bad sequence. 34 B
007038 generated/1782 Generated false Seeded random text, mutation: splice bad sequence. 14 B
007039 generated/1783 Generated false Seeded random text, mutation: replace byte. 222 B
007040 generated/1784 Generated false Seeded random text, mutation: splice bad sequence. 170 B
007041 generated/1785 Generated false Seeded random text, mutation: truncate. 42 B
007042 generated/1786 Generated false Seeded random text, mutation: delete byte. 22 B
007043 generated/1787 Generated true Seeded random text, mutation: none. 65 B
007044 generated/1788 Generated false Seeded random text, mutation: replace byte. 63 B
007045 generated/1789 Generated true Seeded random text, mutation: none. 216 B
007046 generated/1790 Generated true Seeded random text, mutation: none. 140 B
007047 generated/1791 Generated true Seeded random text, mutation: none. 346 B
007048 generated/1792 Generated true Seeded random text, mutation: none. 298 B
007049 generated/1793 Generated false Seeded random text, mutation: splice bad sequence. 35 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.