chore: trigger CI [evergreen] #600
ci.yml
on: push
Test & Lint
23s
Playground E2E (Playwright)
1m 21s
Validate Python Examples
1m 33s
OpenEvolve benchmark
0s
Build
0s
Annotations
10 errors and 3 warnings
|
error: expect(received).toContain(expected):
tests/stats/format_table.test.ts#L68
Expected to contain: ":---:"
Received: "| | a |\n| --- | :-: |\n| 0 | 1 |"
at <anonymous> (/home/runner/work/tsessebe/tsessebe/tests/stats/format_table.test.ts:68:16)
|
|
error: expect(received).toContain(expected):
tests/stats/format_table.test.ts#L62
Expected to contain: "---:"
Received: "| | a |\n| --- | --: |\n| 0 | 1 |"
at <anonymous> (/home/runner/work/tsessebe/tsessebe/tests/stats/format_table.test.ts:62:16)
|
|
error: expect(received).toContain(expected):
tests/stats/format_table.test.ts#L56
Expected to contain: ":---"
Received: "| | a |\n| --- | :-- |\n| 0 | 1 |"
at <anonymous> (/home/runner/work/tsessebe/tsessebe/tests/stats/format_table.test.ts:56:16)
|
|
error: expect(received).toContain(expected):
tests/playground.test.ts#L98
Expected to contain: "--bg"
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = text.trim().split(\"\\n\").filter(l => l.trim());\n
|
|
error: expect(received).toMatch(expected):
tests/playground.test.ts#L94
Expected substring or pattern: /class\s*=\s*["'][^"']*\bplayground-output\b/
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = te
|
|
error: expect(received).toMatch(expected):
tests/playground.test.ts#L90
Expected substring or pattern: /class\s*=\s*["'][^"']*\bplayground-run\b/
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = text.
|
|
error: expect(received).toMatch(expected):
tests/playground.test.ts#L86
Expected substring or pattern: /class\s*=\s*["'][^"']*\bplayground-editor\b/
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = te
|
|
error: expect(received).toMatch(expected):
tests/playground.test.ts#L82
Expected substring or pattern: /class\s*=\s*["'][^"']*\bplayground-block\b/
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = tex
|
|
error: expect(received).toMatch(expected):
tests/playground.test.ts#L78
Expected substring or pattern: /id\s*=\s*["']playground-loading["']/
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = text.trim(
|
|
error: expect(received).toContain(expected):
tests/playground.test.ts#L74
Expected to contain: "playground-runtime.js"
</td><td>\\\\label{} text (requires tableEnv)</td></tr>\n <tr><td><code>floatFormat</code></td><td>number</td><td>undefined</td><td>Decimal places for numeric values</td></tr>\n </table>\n\n <script type=\"module\">\n // Inline minimal tsb subset for playground (no module bundler)\n // We implement the core logic directly here for the demo.\n\n function cellStr(v) {\n if (v === null || v === undefined) return \"\";\n if (typeof v === \"number\" && isNaN(v)) return \"NaN\";\n return String(v);\n }\n\n function toMarkdown(data, cols, rowLabels, opts = {}) {\n const { colAlign = \"none\", index = true, floatFormat } = opts;\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return v.toFixed(floatFormat);\n return cellStr(v);\n };\n const headers = index ? [\"\", ...cols] : [...cols];\n const rows = data.map((row, i) => {\n const cells = [];\n if (index) cells.push(String(rowLabels[i] ?? i));\n cols.forEach((_, c) => cells.push(fmt(row[c])));\n return cells;\n });\n const nCols = headers.length;\n const widths = headers.map(h => Math.max(h.length, 3));\n rows.forEach(row => row.forEach((c, i) => { if (c.length > widths[i]) widths[i] = c.length; }));\n const seps = widths.map((w, ci) => {\n const align = (index && ci === 0) ? \"none\" : colAlign;\n if (align === \"left\") return `:${\"-\".repeat(w-1)}`;\n if (align === \"right\") return `${\"-\".repeat(w-1)}:`;\n if (align === \"center\") return `:${\"-\".repeat(Math.max(w-2,1))}:`;\n return \"-\".repeat(w);\n });\n const pad = (s, w) => s.padEnd(w);\n return [\n `| ${headers.map((h,i) => pad(h, widths[i])).join(\" | \")} |`,\n `| ${seps.join(\" | \")} |`,\n ...rows.map(r => `| ${r.map((c,i) => pad(c, widths[i])).join(\" | \")} |`)\n ].join(\"\\n\");\n }\n\n function latexEsc(s) {\n return String(s)\n .replace(/\\\\/g, \"\\\\textbackslash{}\")\n .replace(/&/g, \"\\\\&\").replace(/%/g, \"\\\\%\").replace(/\\$/g, \"\\\\$\")\n .replace(/#/g, \"\\\\#\").replace(/_/g, \"\\\\_\").replace(/\\{/g, \"\\\\{\")\n .replace(/\\}/g, \"\\\\}\").replace(/~/g, \"\\\\textasciitilde{}\")\n .replace(/\\^/g, \"\\\\textasciicircum{}\");\n }\n\n function toLaTeX(data, cols, rowLabels, opts = {}) {\n const { index = true, booktabs = true, longtable = false, tableEnv = false, floatFormat, caption, label } = opts;\n const nCols = index ? cols.length + 1 : cols.length;\n const colFmt = \"l\".repeat(nCols);\n const env = longtable ? \"longtable\" : \"tabular\";\n const fmt = (v) => {\n if (floatFormat !== undefined && typeof v === \"number\" && isFinite(v))\n return latexEsc(v.toFixed(floatFormat));\n return latexEsc(cellStr(v));\n };\n const lines = [];\n if (tableEnv) {\n lines.push(\"\\\\begin{table}\");\n if (caption) lines.push(`\\\\caption{${latexEsc(caption)}}`);\n if (label) lines.push(`\\\\label{${latexEsc(label)}}`);\n lines.push(\"\\\\centering\");\n }\n lines.push(`\\\\begin{${env}}{${colFmt}}`);\n lines.push(booktabs ? \"\\\\toprule\" : \"\\\\hline\");\n const hdrCells = index ? [\"\", ...cols.map(latexEsc)] : cols.map(latexEsc);\n lines.push(`${hdrCells.join(\" & \")} \\\\\\\\`);\n lines.push(booktabs ? \"\\\\midrule\" : \"\\\\hline\");\n data.forEach((row, i) => {\n const cells = index ? [latexEsc(String(rowLabels[i] ?? i)), ...row.map(fmt)] : row.map(fmt);\n lines.push(`${cells.join(\" & \")} \\\\\\\\`);\n });\n lines.push(booktabs ? \"\\\\bottomrule\" : \"\\\\hline\");\n lines.push(`\\\\end{${env}}`);\n if (tableEnv) lines.push(\"\\\\end{table}\");\n return lines.join(\"\\n\");\n }\n\n function parseInput(text) {\n const lines = text.trim().split(\"\\n\").filter(
|
|
Test & Lint
Node.js 20 actions are deprecated. The following actions are running on Node.js 20 and may not work as expected: actions/checkout@v4. Actions will be forced to run with Node.js 24 by default starting June 2nd, 2026. Node.js 20 will be removed from the runner on September 16th, 2026. Please check if updated versions of these actions are available that support Node.js 24. To opt into Node.js 24 now, set the FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true environment variable on the runner or in your workflow file. Once Node.js 24 becomes the default, you can temporarily opt out by setting ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
|
|
Playground E2E (Playwright)
Node.js 20 actions are deprecated. The following actions are running on Node.js 20 and may not work as expected: actions/cache@v4, actions/checkout@v4. Actions will be forced to run with Node.js 24 by default starting June 2nd, 2026. Node.js 20 will be removed from the runner on September 16th, 2026. Please check if updated versions of these actions are available that support Node.js 24. To opt into Node.js 24 now, set the FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true environment variable on the runner or in your workflow file. Once Node.js 24 becomes the default, you can temporarily opt out by setting ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
|
|
Validate Python Examples
Node.js 20 actions are deprecated. The following actions are running on Node.js 20 and may not work as expected: actions/checkout@v4, actions/setup-python@v5. Actions will be forced to run with Node.js 24 by default starting June 2nd, 2026. Node.js 20 will be removed from the runner on September 16th, 2026. Please check if updated versions of these actions are available that support Node.js 24. To opt into Node.js 24 now, set the FORCE_JAVASCRIPT_ACTIONS_TO_NODE24=true environment variable on the runner or in your workflow file. Once Node.js 24 becomes the default, you can temporarily opt out by setting ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
|