Skip to content

fix(webaudio): resolve issues with atomics support#1225

Merged
roderickvd merged 3 commits into
developfrom
fix/webaudio-atomics
May 30, 2026
Merged

fix(webaudio): resolve issues with atomics support#1225
roderickvd merged 3 commits into
developfrom
fix/webaudio-atomics

Conversation

@roderickvd
Copy link
Copy Markdown
Member

Fixes:

  • WebAudio's Send + Sync assertion was unsound when compiled with +atomics.
  • WebAudio should not indicate availability in non-window contexts.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR addresses WebAudio behavior in wasm builds by making availability detection more accurate and avoiding unsound Send + Sync assertions when wasm atomics are enabled.

Changes:

  • Splits WebAudio Stream storage/control paths between non-atomics and atomics builds.
  • Routes atomics play/pause through a main-thread spawn_local task.
  • Updates WebAudio availability checks and changelog entries.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
src/host/webaudio/mod.rs Refactors WebAudio stream internals for atomics support and window-only availability.
Cargo.toml Adds futures dependencies to the wasm-bindgen feature and reformats dependency lists.
CHANGELOG.md Documents the WebAudio fixes.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/host/webaudio/mod.rs Outdated
Comment thread src/host/webaudio/mod.rs
Comment thread src/host/webaudio/mod.rs
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

Comment thread src/host/webaudio/mod.rs Outdated
Comment thread src/host/webaudio/mod.rs Outdated
Comment thread src/host/webaudio/mod.rs Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

Comment thread src/host/webaudio/mod.rs
@roderickvd roderickvd changed the title fix: resolve WebAudio issues with atomics support fix(webaudio): resolve issues with atomics support May 30, 2026
@roderickvd roderickvd requested a review from Copilot May 30, 2026 22:16
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Comment thread src/host/webaudio/mod.rs
Comment thread src/host/webaudio/mod.rs
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

@roderickvd roderickvd force-pushed the fix/webaudio-atomics branch from 5e657b1 to bc55bac Compare May 30, 2026 22:30
@roderickvd roderickvd merged commit 0a4a3ee into develop May 30, 2026
32 checks passed
@roderickvd roderickvd deleted the fix/webaudio-atomics branch May 30, 2026 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants