Skip to content

WASM: Media player fails to load local asset #17771

Description

@baskren

Current behavior

In WASM platform, Media player fails to load local asset.

        MediaPlayer.Source = MediaSource.CreateFromUri(new Uri("ms-appx:///Assets/Sounds/Alarm.mp3"));
        MediaPlayer.Play();

NOTES:

  • Occurs when using Uno.WinUI.MediaPlayer.WebAssembly NuGet package AND/OR MediaElement Feature
  • Occurs if building in VisualStudio 2022 as well as from command line: dotnet build + dotnet serve.
  • bin/Debug/net8.0-browserwasm/dist/package_xxxx/Assets/Sounds/Alarm.mp3 exists
  • Tested on the following browsers:
    • Edge (Windows/Mac)
    • Chrome (Windows/Mac)
    • Safari (Mac)

Expected behavior

Local assets are loaded by WASM MediaPlayer, just as they are with other platforms

How to reproduce it (as minimally and precisely as possible)

Demo Project: https://github.com/baskren/WasmMedia

Workaround

Build custom media player?

Works on UWP/WinUI

Yes

Environment

Uno.WinUI / Uno.WinUI.WebAssembly / Uno.WinUI.Skia

NuGet package version(s)

5.3.90

Affected platforms

WebAssembly

IDE

Visual Studio 2022

IDE version

Microsoft Visual Studio Community 2022 (ARM 64-bit) - Current Version 17.10.4

Relevant plugins

n/a

Anything else we need to know?

No response

Activity

  1. added
    difficulty/tbd
    kind/bug
    triage/untriaged
    on Jul 30, 2024
  2. jeromelaban commented on Jul 31, 2024

    @jeromelaban
    Member

    Thanks for the report. This feature is not implemented at this time, we're tracking this as part of #2642.

  3. added
    kind/enhancement
    and removed
    kind/bug
    triage/untriaged
    on Jul 31, 2024
  4. added theissue type on Jul 22, 2025
  5. github-actions commented on May 6, 2026

    @github-actions
    Contributor

    This issue has had no activity for 120 days. It will be closed in 10 days if there is no further activity. Remove the Stale label or leave a comment to keep it open.

  6. added
    stale
    on May 6, 2026
  7. added
    project/media 📺
    difficulty/starter 🚀
    and removed
    stale
    difficulty/tbd
    on May 6, 2026
  8. github-actions commented on Sep 7, 2026

    @github-actions
    Contributor

    This issue has had no activity for 120 days. It will be closed in 10 days if there is no further activity. Remove the Stale label or leave a comment to keep it open.

  9. added
    stale
    on Sep 7, 2026
  10. github-actions commented on Sep 18, 2026

    @github-actions
    Contributor

    This issue was closed because it had no activity for 10 days after being marked as stale. If you believe this is still relevant, feel free to reopen it or open a new issue with updated context.

  11. Jen-Uno commented on Oct 28, 2026

    @Jen-Uno
    Contributor

    This issue was closed as not planned, so there is nothing for QA to verify. Moving it from Ready for QA Review to Done on the Uno Team Backlog.

  12. removed
    stale
    on Nov 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    difficulty/starter 🚀kind/enhancementproject/media 📺

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions