Terminal Phase 1 [Windows]: own ConPTY layer in atlas-host with bundled OpenConsole

Đang mở
#240 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
10/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
rust
Lĩnh vực
desktop

Hướng nghiên cứu

Read discussion #237 and the Phase 0 probe first, then the existing Windows path that portable-pty replaces before touching crates/atlas-host/src/pty/conpty.rs. The work spans loader flags, IOCP-backed overlapped pipes, close ordering, installer bundling and a self-test fallback ladder, so start by reproducing the Phase 0 matrix measurements on a Win10 1809 box. Done means no throughput regression, byte-exact DCS/sixel/kitty output, and no hangs on resize, mouse or close.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

area: terminal priority: 1 high status: confirmed type: feature

Part of the native GPU terminal roadmap. Design and evidence: discussion #237. Uses the Phase 0 probe.

Why

Win10 never gets ConPTY fixes (microsoft/terminal discussion #17608); only the redistributable Microsoft.Windows.Console.ConPTY (MIT, 17763+) brings the #17510 passthrough (DCS, sixel, kitty APC, ordered sync output, mouse). portable-pty 0.9 and alacritty_terminal load conpty.dll by bare name (DLL planting), have no overlapped pipes, no ReleasePseudoConsole, and cannot set GLYPH_WIDTH_GRAPHEMES.

Change

  • crates/atlas-host/src/pty/conpty.rs over windows-sys, replacing portable-pty on Windows only.
  • LoadLibraryExW(<exe dir>\\conpty.dll, LOAD_LIBRARY_SEARCH_APPLICATION_DIR); resolve ConptyCreate/Resize/Close/ReleasePseudoConsole; kernel32 fallback.
  • Flags: GLYPH_WIDTH_GRAPHEMES, never INHERIT_CURSOR. Release right after CreateProcess.
  • Output: overlapped named pipe, one IOCP reader for all PTYs in hostd. Input stays synchronous until overlapped input is proven on 1809.
  • Close order: drop writer → Close off the reader thread → drain to EOF → join (close blocks before Win11 24H2).
  • Ship a pinned stable pair (x64 + arm64) in the NSIS installer with licence notices; deliberate updates.
  • First-use self-test (10 MB burst + DSR) picks bundled vs inbox per machine; setting terminal.conpty = auto | bundled | system.
  • Fallback ladder: bundled → inbox → xterm.js.

Done when

On the Phase 0 matrix: no throughput regression vs inbox; DCS/sixel/kitty bytes byte-exact; resize, mouse and close without hangs; regression tests on real ptys.

Ngôn ngữ chính
Rust
Star
3
Fork
1
Merge trung bình
9 giờ 51 phút
Pull request đã merge (30 ngày)
310

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của codeatlasdev/atlas

Tất cả issue của codeatlasdev/atlas

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.