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
007100 generated/1844 Generated true Seeded random text, mutation: none. 231 B
007101 generated/1845 Generated true Seeded random text, mutation: none. 317 B
007102 generated/1846 Generated false Seeded random text, mutation: delete byte. 341 B
007103 generated/1847 Generated false Seeded random text, mutation: insert byte. 11 B
007104 generated/1848 Generated false Seeded random text, mutation: replace byte. 22 B
007105 generated/1849 Generated true Seeded random text, mutation: none. 112 B
007106 generated/1850 Generated false Seeded random text, mutation: splice bad sequence. 28 B
007107 generated/1851 Generated false Seeded random text, mutation: insert byte. 5 B
007108 generated/1852 Generated true Seeded random text, mutation: none. 48 B
007109 generated/1853 Generated false Seeded random text, mutation: splice bad sequence. 196 B
007110 generated/1854 Generated false Seeded random text, mutation: splice bad sequence. 105 B
007111 generated/1855 Generated false Seeded random text, mutation: delete byte. 3 B
007112 generated/1856 Generated true Seeded random text, mutation: flip bit. 15 B
007113 generated/1857 Generated true Seeded random text, mutation: none. 351 B
007114 generated/1858 Generated false Seeded random text, mutation: replace byte. 356 B
007115 generated/1859 Generated false Seeded random text, mutation: truncate. 33 B
007116 generated/1860 Generated false Seeded random text, mutation: replace byte. 388 B
007117 generated/1861 Generated true Seeded random text, mutation: flip bit. 162 B
007118 generated/1862 Generated false Seeded random text, mutation: replace byte. 149 B
007119 generated/1863 Generated true Seeded random text, mutation: none. 89 B
007120 generated/1864 Generated false Seeded random text, mutation: truncate. 58 B
007121 generated/1865 Generated false Seeded random text, mutation: insert byte. 3 B
007122 generated/1866 Generated false Seeded random text, mutation: delete byte. 56 B
007123 generated/1867 Generated true Seeded random text, mutation: none. 10 B
007124 generated/1868 Generated false Seeded random text, mutation: splice bad sequence. 53 B
007125 generated/1869 Generated true Seeded random text, mutation: none. 54 B
007126 generated/1870 Generated false Seeded random text, mutation: splice bad sequence. 41 B
007127 generated/1871 Generated false Seeded random text, mutation: splice bad sequence. 119 B
007128 generated/1873 Generated false Seeded random text, mutation: flip bit. 65 B
007129 generated/1874 Generated true Seeded random text, mutation: none. 40 B
007130 generated/1875 Generated true Seeded random text, mutation: none. 50 B
007131 generated/1876 Generated false Seeded random text, mutation: truncate. 60 B
007132 generated/1877 Generated false Seeded random text, mutation: insert byte. 392 B
007133 generated/1878 Generated true Seeded random text, mutation: none. 10 B
007134 generated/1879 Generated true Seeded random text, mutation: none. 9 B
007135 generated/1880 Generated false Seeded random text, mutation: insert byte. 29 B
007136 generated/1881 Generated true Seeded random text, mutation: none. 4 B
007137 generated/1882 Generated true Seeded random text, mutation: none. 229 B
007138 generated/1883 Generated true Seeded random text, mutation: none. 5 B
007139 generated/1884 Generated false Seeded random text, mutation: truncate. 37 B
007140 generated/1885 Generated false Seeded random text, mutation: splice bad sequence. 229 B
007141 generated/1886 Generated false Seeded random text, mutation: truncate. 50 B
007142 generated/1887 Generated false Seeded random text, mutation: splice bad sequence. 154 B
007143 generated/1889 Generated true Seeded random text, mutation: none. 362 B
007144 generated/1890 Generated true Seeded random text, mutation: none. 33 B
007145 generated/1891 Generated true Seeded random text, mutation: none. 12 B
007146 generated/1892 Generated true Seeded random text, mutation: none. 5 B
007147 generated/1894 Generated true Seeded random text, mutation: none. 189 B
007148 generated/1895 Generated true Seeded random text, mutation: none. 46 B
007149 generated/1896 Generated false Seeded random text, mutation: delete byte. 344 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.