Skip to content

Enable stdio on wasm#482

Merged
peter-jerry-ye merged 1 commit into
mainfrom
codex/async-stdio-wasm
Jul 7, 2026
Merged

Enable stdio on wasm#482
peter-jerry-ye merged 1 commit into
mainfrom
codex/async-stdio-wasm

Conversation

@peter-jerry-ye

@peter-jerry-ye peter-jerry-ye commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Why

moonbitlang/async/stdio was still native-only, so wasm users could not access standard input, output, or error through the async IO abstractions.

What

This enables the internal stdio event-loop setup and public stdio package on wasm, then adds a small handle-availability regression test.

Why This Is Correct

The public stdio API stays unchanged. The shared stdio setup still takes logical standard stream ids (0, 1, 2) like the native implementation. Upstream now always routes stdio through the thread pool, so wasm only needs a target-specific get_stdio_handle(id) import and the existing fd-kind import.

Scope

This is limited to wasm stdio package support. Native stdio behavior is unchanged.

@peter-jerry-ye peter-jerry-ye changed the base branch from main to codex/realpath-host-bindings July 7, 2026 06:26
@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch from ef88854 to 6463004 Compare July 7, 2026 06:32
@coveralls

coveralls commented Jul 7, 2026

Copy link
Copy Markdown

Coverage Report for CI Build 777

Coverage increased (+0.04%) to 77.236%

Details

  • Coverage increased (+0.04%) from the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 4696
Covered Lines: 3627
Line Coverage: 77.24%
Coverage Strength: 11898.9 hits per line

💛 - Coveralls

@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch 3 times, most recently from 4d93627 to 1a13f81 Compare July 7, 2026 06:57
@peter-jerry-ye peter-jerry-ye marked this pull request as ready for review July 7, 2026 07:27
@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch from 1a13f81 to c0da033 Compare July 7, 2026 07:37

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1a13f819a8

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/internal/event_loop/stdio.mbt
@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch from c0da033 to 6c3ba8d Compare July 7, 2026 08:02
@peter-jerry-ye peter-jerry-ye changed the base branch from codex/realpath-host-bindings to main July 7, 2026 08:03
@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch from 6c3ba8d to 142c753 Compare July 7, 2026 08:09
@peter-jerry-ye peter-jerry-ye force-pushed the codex/async-stdio-wasm branch from 142c753 to a6ab975 Compare July 7, 2026 09:31
@peter-jerry-ye peter-jerry-ye merged commit 11366d0 into main Jul 7, 2026
31 of 36 checks passed
@peter-jerry-ye peter-jerry-ye deleted the codex/async-stdio-wasm branch July 7, 2026 10:24
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.

2 participants