Skip to content

Add Code OSS browser and native desktop compatibility - #76

Draft
wieslawsoltes wants to merge 1 commit into
mainfrom
feature/code-oss-browser-compatibility
Draft

wieslawsoltes wants to merge 1 commit into
mainfrom
feature/code-oss-browser-compatibility

Conversation

@wieslawsoltes

@wieslawsoltes wieslawsoltes commented Sep 15, 2026

Copy link
Copy Markdown
Collaborator

VS Code OSS 1.137's unchanged server-web workbench runs through WebScene without Electron, CEF, WebView, Chromium, or a browser process. Generic browser behavior stays in WebScene, native application behavior stays in AppScene, and product acceptance stays in SceneTech/vscode-demo. Porting VS Code to C++ is explicitly out of scope.

Consolidation status

This draft is refreshed through WebScene main 4ccadd1333c54e91e83e65234e783685964ae1d9 at consolidation head f9ec2992c59c5e8715d2a7d3edfa73c82d4bb6d2. Its unique diff is the preserved docs/code-oss-compatibility.md guide (164 added lines); all reusable implementation and regression work is already on main through focused PRs. Keep this PR draft, open, and unmerged.

Recent focused merges included in this exact base cover navigation/workspace handoff, remote task fairness, iframe sandbox and frame-owned CSS resource bases, ServiceWorker/message-port foundations, Web API/WPT ledgers, CSS property identity/cascade/CSSOM batching, URL/string escapes, controlled range/cache requests, and generated-content unitless line-height geometry.

Validation and merge policy

Focused changes require a browser-oracle or WPT-derived regression, native coverage, and bounded performance/allocation/memory/lifecycle evidence for changed hot paths. Related PRs use GitHub-native stacks and validate the cumulative top. Only directly related runners gate focused merges; broad product/platform validation runs at cumulative tops and final release. Duplicate, superseded, unrelated, and post-merge jobs are canceled.

This consolidation PR contains guidance only. It must remain based on current main, draft, and unmerged.

@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch 2 times, most recently from 9d57164 to 1ede308 Compare September 15, 2026 09:52
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch 9 times, most recently from 8955e9e to 41cf43c Compare September 15, 2026 11:14
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch from cfccdbf to 61ea9d4 Compare September 15, 2026 12:26
@wieslawsoltes wieslawsoltes changed the title Move Code OSS browser compatibility into WebScene Add Code OSS browser and native desktop compatibility Sep 15, 2026
@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Full macOS arm64 Release distribution qualification at AppScene e9fd26777747adfda5fadd571b0b5c73412dfe67 / WebScene b639b4c49985891c2521421229a2f22e976ead2c:

  • CMake Release app editor smoke: 8.041 s, exit 0, executable SHA-256 678b9106885e42ad37fe1db03d22cf32d1f2027387ab262899950138acec6e99.
  • Distribution app editor smoke after audit/re-signing: 8.127 s, exit 0, executable SHA-256 772824a2491f1e4d9edaea095a1e5ca67a75b58e1bca30c39cb0f1671c19b0bd.
  • ZIP: 267,696,685 bytes, SHA-256 7fcf191a381d67054a5dbe70fd842739e9c8e508b852f4c59ffb4b7c0bdac8ab.
  • DMG: 327,921,410 bytes, SHA-256 48b85d5747735d1e85072915496b7119938f6acdbdd2ee74f6c67b205357fdb4.
  • The packager audited 27 arm64 Mach-O files. Deep code-sign, DMG verification, and every SHA256SUMS entry pass.
  • The complete final WebScene hosted/native/package/consumer matrix and AppScene portable PR matrix are green.

The package is retained locally only. Both PRs remain draft, open, and unmerged; the parent integration branch remains unpushed.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Release validation for current head 31e3d8ad:

  • Deterministic public-ABI before/after: retained b639b4c4 exits 139 when destroyed with a pending legacy-copy request and matches all eight Code OSS crash offsets; the current package exits 0.
  • macOS packaged dylib/dSYM UUID: A8A72CF9-8783-3C1E-A89D-02369DB0CC1E; compressed symbol artifact 5,352,939 bytes, three-day retention.
  • Green: hosted macOS/Ubuntu/Windows, both macOS NativeAOT versions, Windows NativeAOT, Linux native contracts, macOS/Linux/Windows packages and consumers, cross-RID required/candidate evidence, and release-set verification.
  • Rebuilt Code OSS/AppScene editor smoke passes in 4.478 seconds; separately signed distribution smoke passes in 8.651 seconds; deep signature, 27-Mach-O audit, ZIP/DMG/checksums, and size budgets pass.
  • Real Monaco copy and normal close pass without the prior worker crash. The real Monaco paste copyback mismatch remains documented in Add a bounded async Clipboard API host ABI for native runtimes #86 and must be fixed before the clipboard feature is fully qualified.

Keep this PR draft/open and unmerged while #86, #81, #56, and #83 remain on the consumer critical path.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Paste compatibility update: commit 9b9a17d fixes the empty Code OSS paste path by exposing clipboard string representations through an iterable DataTransferItemList subset. The regression test consumes each item through asynchronous getAsString(), matching VS Code's toVSDataTransfer implementation.

Local validation: WebScene.Architecture.Tests 26/26 passed. I will rebuild and manually validate the complete AppScene Code OSS release after all native runtime/package/consumer jobs pass.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Qualification update for 9b9a17d:

  • The complete WebScene CI matrix is green, including all three native packages, cross-RID evidence/release-set verification, and installed consumers.
  • The rebuilt Code OSS/AppScene Release editor smoke passes in 4.029 s.
  • Two Release-build and one separately signed distribution computer-use runs pass real Monaco typing, byte-exact OS copy, byte-exact OS paste/copyback, all 88 input records accepted, normal close, and exit 0.
  • ZIP/DMG/checksums, deep signing, 27 arm64 Mach-O audit, and size budgets pass.
  • Runtime UUID: A5D0DFD7-6BC8-3B61-A249-31319C6BE186.

Keep this PR draft, open, and unmerged while the other consumer gaps remain.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Performance timeline update: 290b9b8 fixes #83 by supplying a stable numeric performance.timeOrigin and removing the temporary non-retaining mark/measure methods. The retained timeline is installed before later browser compatibility scripts in both main and iframe realms.

The regression mirrors Code OSS's environment selection and immediate didStartWorkbench measure. Native tests additionally cover captured free-function calls, method/query identity, wall-clock alignment, and read-only origin after snapshot hydration. Local RuntimeCompatibility passes 25/25 with 50,000 marks in 43.75 ms; Architecture passes 26/26. Cross-platform package CI is running.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Current integration head: 5baf7e5.

This branch now includes merged main/PR #71 and keeps Code OSS in Full JavaScript mode. New work since 9b9a17d:

Local gates: RuntimeCompatibility 25/25; architecture 29/29; precompiled Python/CMake 17/17; parent packaging/SDK/smoke 46/46. The 50,000-mark gate completed in 32.12 ms under its 1.5 s budget.

A clean Code OSS 1.137.0 production rebuild and Release package passed:

  • editor smoke 7.097 s with no missing-mark exception;
  • manual real-Monaco input/copy/paste/copy-back/normal-close 11.32 s, 184/184 inputs accepted;
  • 27 arm64 Mach-O dependency and minimum-OS audits;
  • deep signature, ZIP, DMG, manifest, and checksum validation.

The preceding 59c3e09 CI/native-Linux/precompiled workflows and macOS package job passed. Its package run was cancelled after local integration exposed a 26.5 inherited deployment minimum. Exact-head 5baf7e5 precompiled checks pass; CI/package/native-Linux remain queued without job allocation because the required self-hosted Linux runner is unavailable. Keep this PR draft and unmerged.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Implemented at 0f3a320e12c8cc716c8818e8ef5654054477df31 and pushed to draft PR #76.

The native paste path now requests all supported representations and exposes returned images as browser-shaped file items:

  • DataTransferItem.kind === "file"
  • exact host MIME type
  • getAsFile() returns a WebScene File
  • DataTransfer.files contains the file
  • DataTransfer.types contains Files
  • File.arrayBuffer() preserves the host bytes
  • unsupported returned MIME types reject with NotSupportedError
  • readText() rejects a non-text result with DataError

Local WebScene gates passed:

  • full native V8 runtime suite
  • RuntimeCompatibility: 25/25
  • Architecture: 29/29
  • exact 68-byte PNG signature/file metadata regression
  • maximum 16 MiB image paste: 0.157494 s (5 s budget)
  • typed maximum 16 MiB clipboard: 0.108963 s
  • typed clipboard 10,000 operations: 0.0367825 s
  • legacy clipboard 10,000 operations: 1.90916 s

The production Code OSS 1.137.0 package built from this runtime also passed macOS computer use through the real unchanged workbench. NSPasteboard -> AppScene -> typed WebScene ABI -> paste delivered:

{"status":"passed","kind":"file","type":"image/png","name":"clipboard.png","size":68,"byteLength":68,"first":137,"last":130,"fnv1a32":1588682394,"itemCount":1,"fileCount":1,"types":["Files"]}

The same signed bundle passed editor render/edit/undo in 7.077 s, text keyboard/copy/paste in 11.308 s with 88/88 inputs accepted, image paste in 6.452 s, normal close, the 27-Mach-O dependency/signature audit, ZIP extraction verification, and DMG verification.

Issue acceptance remains open until the new exact-head cross-platform CI matrix is green.

@wieslawsoltes

Copy link
Copy Markdown
Collaborator Author

Current consolidation head: b8785dd06c324e25e7caa9b40547e87c79e60302.

This head retains the real Code OSS iframe Worker fix and adds:

  • d807f7ab: makes the detached-iframe regression timing-safe by counting callbacks only after the synchronous removeChild boundary. The prior Linux failure was a fixture race that counted a legal pre-removal MessagePort delivery. The corrected native regression passed 10/10 repeats, graphics CTest 28/28, and worker/iframe WPT 31/31.
  • 3294fa39: expands fragment attachment selector-invalidation regressions.
  • b8785dd0: expands IndexedDB snapshot and structured-data restart regressions.

The fully packaged Code OSS 1.137.0 development composite passed editor smoke, two-process IndexedDB persistence, original-browser visual parity, native keyboard/text clipboard, native PNG clipboard, and all 14 performance budgets. Key results: zero layout-geometry deltas; pixel MAE 0.004786; ready 3,227.787 ms; visible/hidden idle CPU mean 0.866%/0.105%; input p95 3.429 ms; CSS recascade p95 0.337 ms; 256-child panel attach/detach p95 8.637/0.824 ms.

The parent integration contracts pass 43/43 Node and 67/67 Python. Exact-head b8785dd0 workflows are running; keep this PR draft until the complete applicable matrix is green.

@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch 5 times, most recently from 1adbe83 to e279fc4 Compare September 17, 2026 01:12
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch from 710858d to 0885009 Compare September 17, 2026 10:24
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch from 1d47333 to f9ec299 Compare September 17, 2026 20:48
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch 3 times, most recently from 82853d3 to 7382d7e Compare September 17, 2026 22:01
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch from 7382d7e to c6a1457 Compare September 18, 2026 05:43
@wieslawsoltes
wieslawsoltes force-pushed the feature/code-oss-browser-compatibility branch from c6a1457 to af6985f Compare September 18, 2026 06:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant