Build Failure on Mac Catalyst and iOS with SmartComponents.LocalEmbeddings in .NET MAUI Blazor App

Open
#44 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
48/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
csharp, ios, macos

Research direction

Start by reproducing the attached BlazorMAUI.zip project with SmartComponents.LocalEmbeddings on net8.0-ios and net8.0-maccatalyst. Compare dependency resolution for Microsoft.ML.OnnxRuntime 1.21.0 and 1.22.1, then verify that the project builds for iOS, Mac Catalyst, Windows, and Android without the manual workaround.

Written by the indexing model from the issue text.

Description

Description:

When a .NET MAUI Blazor application includes the SmartComponents.LocalEmbeddings NuGet package, the project fails to build specifically for the Mac Catalyst and iOS target frameworks. The build completes successfully for Windows and Android, but fails on macOS with the following error:

No matching framework found

However, updating the Microsoft.ML.OnnxRuntime package to the latest version (1.22.1) resolves the issue, allowing the project to build successfully across all platforms.

Image

BlazorMAUI.zip

Steps to Reproduce:

  1. Create a new .NET MAUI Blazor project.
  2. Add the SmartComponents.LocalEmbeddings NuGet package.
  3. Attempt to build the project targeting net8.0-ios or net8.0-maccatalyst.
  4. Observe the build failure.

(or)

  1. Download the attached .NET MAUI Blazor project. BlazorMAUI.zip
  2. Attempt to build the project targeting net8.0-ios or net8.0-maccatalyst.
  3. Observe the build failure.

Expected Behavior:

The project should build successfully for all target platforms, including Mac Catalyst and iOS.


Actual Behavior:

Build fails on Mac Catalyst and iOS with a framework mismatch error.


Environment:

  • .NET SDK: 8.0.203
  • MAUI Version: 8.0.x
  • macOS: macOS Sequoia 15.6
  • Target Frameworks: net8.0-ios, net8.0-maccatalyst
  • Device: Simulator and Physical Device
  • SmartComponents.LocalEmbeddings Version: 0.1.0-preview10148
  • Microsoft.ML.OnnxRuntime Version: 1.21.0 (fails), 1.22.1 (works)

Workaround:

Manually updating the Microsoft.ML.OnnxRuntime package to version 1.22.1 resolves the build issue.

<PackageReference Include="Microsoft.ML.OnnxRuntime" Version="1.22.1" />
Dominant language
C#
Stars
509
Forks
61
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from dotnet/smartcomponents

All issues in dotnet/smartcomponents

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.