Title: Port the upstream suite-unicode-bom Rslint E2E · Issue #42 · rstackjs/rstack-editor · GitHub
Open Graph Title: Port the upstream suite-unicode-bom Rslint E2E · Issue #42 · rstackjs/rstack-editor
X Title: Port the upstream suite-unicode-bom Rslint E2E · Issue #42 · rstackjs/rstack-editor
Description: Problem The standalone rslint extension's suite-unicode-bom E2E was never ported. Every other functional upstream suite has a counterpart under packages/vscode/e2e/lint/; this one is missing, so the worker/proxy layer this extension adds...
Open Graph Description: Problem The standalone rslint extension's suite-unicode-bom E2E was never ported. Every other functional upstream suite has a counterpart under packages/vscode/e2e/lint/; this one is missing, so th...
X Description: Problem The standalone rslint extension's suite-unicode-bom E2E was never ported. Every other functional upstream suite has a counterpart under packages/vscode/e2e/lint/; this one is missing, s...
Opengraph URL: https://github.com/rstackjs/rstack-editor/issues/42
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Port the upstream suite-unicode-bom Rslint E2E","articleBody":"## Problem\n\nThe standalone rslint extension's `suite-unicode-bom` E2E was never ported. Every other functional upstream suite has a counterpart under `packages/vscode/e2e/lint/`; this one is missing, so the worker/proxy layer this extension adds between VS Code and the Go server has no coverage for the BOM boundary case.\n\nUpstream source: `rslint@origin/main:packages/vscode-extension/__tests__/suite-unicode-bom/unicode-bom.test.ts` and `__tests__/fixtures-unicode-bom/`. Added in web-infra-dev/rslint#1560 (port of the `unicode-bom` rule, 2026-08-06), fixture moved from `rslint.json` to a native config in web-infra-dev/rslint#1951. rstackjs/rstack-editor#26 ported #1611 and #1279 but skipped #1560.\n\n## What the upstream test guards\n\nVS Code consumes a UTF-8 BOM as encoding metadata, so the document model sent over LSP contains no U+FEFF even though the file bytes start with `EF BB BF`. The `unicode-bom` rule once emitted a BOM-removal fix with range `[-1, 0]`, which cannot be expressed as a VS Code `TextEdit`; the final fix skips the rule for editor linting and leaves BOM fixes to the CLI (`internal/lsp/lint_generation.go:20-39`). The test asserts:\n\n1. disk starts with `EF BB BF`, `TextDocument.getText()` has no U+FEFF;\n2. diagnostics contain `no-var` (positive control) and nothing from `unicode-bom`;\n3. whole-document Quick Fixes contain `Disable no-var for this line` and no BOM-related action;\n4. document text and dirty state are unchanged.\n\n## Why it still matters here\n\nStatic reading says this extension is transparent: the router only gates by runtime ownership (`stacks/lint/WorkspaceDocumentRouter.ts:101-176`), `vscode-languageclient` serializes `getText()` and forwards UTF-16 incremental ranges unchanged, and the worker forwards requests without rewriting text or positions (`stacks/lint/worker/index.ts:109-166,219-241`). The existing emoji test (`e2e/lint/suite/extension.test.ts:388-448`) proves UTF-16 incremental alignment, not BOM handling. That is reasoning, not evidence; E2E is the ground truth for editor behavior in this repo.\n\n## Proposal\n\nPort `suite-unicode-bom` and its fixture into `packages/vscode/e2e/lint/` as-is (native `rslint.config.mjs` enabling `unicode-bom` and `no-var`, per the post-#1951 shape), register it in `e2e/run.mjs`, and run `pnpm test:e2e:lint`.\n","author":{"url":"https://github.com/fi3ework","@type":"Person","name":"fi3ework"},"datePublished":"2026-09-03T08:15:00Z","url":"https://github.com/rstackjs/rstack-editor/issues/42"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:eebb6d9f-a67c-1b71-7cc2-c0fe9e4b3a8b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D76A:10D9D9:B22B59:FB7D5E:6AEC6C0C |
| html-safe-nonce | 2ddc0001fd8d178ef6862d4de6849fb258501f90d4832f42afab1ec3e9834468 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENzZBOjEwRDlEOTpCMjJCNTk6RkI3RDVFOjZBRUM2QzBDIiwidmlzaXRvcl9pZCI6IjY2NjMyNDI3NTQ3ODExMTMzNTYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2006286149e2bf7e35ab5597c96d3c7f2e6cd9e70cb6523f17e515aaaec698c0 |
| hovercard-subject-tag | issue:5334085033 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/rstackjs/rstack-editor/42/issue_layout |
| twitter:image | https://opengraph.githubassets.com/d23400ed0de5772a6e0a0a2063eea8d5fe0c0eced6aacfb9b47fd78dd362f92b/rstackjs/rstack-editor/issues/42 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/d23400ed0de5772a6e0a0a2063eea8d5fe0c0eced6aacfb9b47fd78dd362f92b/rstackjs/rstack-editor/issues/42 |
| og:image:alt | Problem The standalone rslint extension's suite-unicode-bom E2E was never ported. Every other functional upstream suite has a counterpart under packages/vscode/e2e/lint/; this one is missing, so th... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | fi3ework |
| hostname | github.com |
| expected-hostname | github.com |
| None | 81a8a223b8411e760195a15942ff045b37d56328f5bf02c4ca5f903e3dcb475e |
| turbo-cache-control | no-preview |
| go-import | github.com/rstackjs/rstack-editor git https://github.com/rstackjs/rstack-editor.git |
| octolytics-dimension-user_id | 129049372 |
| octolytics-dimension-user_login | rstackjs |
| octolytics-dimension-repository_id | 1316963958 |
| octolytics-dimension-repository_nwo | rstackjs/rstack-editor |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1316963958 |
| octolytics-dimension-repository_network_root_nwo | rstackjs/rstack-editor |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | a2c6dc5933515805b39ac7c5b9ab4e947c2f5a42 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width