Skip to content

Fix 404 audio in the browser JavaScript sound demo - #7675

Merged
FarhanAliRaza merged 5 commits into
mainfrom
ccr-921eda66-kjt8mt-sound-demo
Oct 27, 2026
Merged

FarhanAliRaza merged 5 commits into
mainfrom
ccr-921eda66-kjt8mt-sound-demo

Conversation

@FarhanAliRaza

@FarhanAliRaza FarhanAliRaza commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Description

The inline-script sound demo on api-reference/browser-javascript hard-coded /vintage-button-sound-effect.mp3, but the docs site is mounted at /docs, so the request returned 404 and both play buttons were silent. The demo now resolves the file with rx.asset, which prepends the frontend path and also shows readers the supported way to reference an asset.

Rendering the page locally confirms the script now references /docs/vintage-button-sound-effect.mp3.

https://claude.ai/code/session_01LwJUCUDZhZY71q8Azr37BQ


Generated by Claude Code

View guided diff Turn on auto-fix

The demo hard-coded /vintage-button-sound-effect.mp3, but the docs site is
mounted at /docs, so the file was never found and both play buttons were
silent. Resolving the file with rx.asset prepends the frontend path and
also shows readers the supported way to reference an asset.

Claude-Session: https://claude.ai/code/session_01LwJUCUDZhZY71q8Azr37BQ
@FarhanAliRaza
FarhanAliRaza requested review from a team and Alek99 as code owners October 27, 2026 20:17
@FarhanAliRaza FarhanAliRaza added the documentation Improvements or additions to documentation label Oct 27, 2026 — with Claude

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 2 files

View guided diff | Turn on auto-fix | Re-trigger cubic

@greptile-apps

greptile-apps Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge; no new actionable issues were found.

Summary

The sound demo now uses rx.asset so its audio URL includes the /docs prefix.

  • The browser JavaScript sound demo loads its audio from the docs path.

Reviews (4) · Last reviewed commit: "Isolate the sound demo test's state regi..." · Reviewed by Greptile

Comment thread docs/api-reference/browser_javascript.md
@codspeed

codspeed Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

Merging this PR will improve performance by 5.1%

2 warnings

⚠️ 16 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

⚠️ Base and head ran on different runner types

Some benchmarks with significant performance changes were compared across different runner types, so the changes might not come from the code. Run base and head on the same runner type, or use CodSpeed Macro Runners for more stable results.

Learn more about Macro Runners

Open the report in CodSpeed to investigate

⚡ 1 improved benchmark
✅ 147 untouched benchmarks

Performance Changes

Benchmark BASE HEAD Efficiency
⚡ test_state_access[write_inherited] 238.7 ms 227.1 ms +5.1%

Tip

Curious why performance improved? Comment @codspeedbot explain why performance improved on this PR, or directly use the CodSpeed MCP with your agent.


Comparing ccr-921eda66-kjt8mt-sound-demo (ba5fbd4) with main (2a2a4c1)

Open in CodSpeed

Rendering the page under the real path registered the demo's state
class first, so test_docgen_double_eval's re-evaluation of the same page
failed with a duplicate substate.

Claude-Session: https://claude.ai/code/session_01LwJUCUDZhZY71q8Azr37BQ

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 1 file (changes from recent commits).

Reply with feedback, questions, or to request a fix.

View guided diff | Turn on auto-fix | Re-trigger cubic

Comment thread docs/app/tests/test_browser_javascript_demo.py
@linear-code

linear-code Bot commented Oct 27, 2026

Copy link
Copy Markdown

ENG-13585

Render inside a RegistrationContext, as the tutorial tests do, so the
demo's state class does not stay in the shared registries.

Claude-Session: https://claude.ai/code/session_01LwJUCUDZhZY71q8Azr37BQ

Copy link
Copy Markdown
Contributor Author

Validated in the docs app running locally on this branch. The demo's audio source is now /docs/vintage-button-sound-effect.mp3 and the file returns 200:

Sound demo


Generated by Claude Code

@FarhanAliRaza
FarhanAliRaza merged commit c458e33 into main Oct 27, 2026
168 checks passed
@FarhanAliRaza
FarhanAliRaza deleted the ccr-921eda66-kjt8mt-sound-demo branch October 27, 2026 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant