Maui icon indicating copy to clipboard operation
Maui copied to clipboard

[BUG] IOS version supported

Open ForkBug opened this issue 3 years ago • 6 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current Behavior

A project said the following errors when being compiled: "warning CA1416: This call site is reachable on: 'iOS' 10.0 and later, 'maccatalyst' 10.0 and later. 'ColorConversionExtensions.WithRed(Color, double)' is only supported on: 'iOS' 14.2 and later, 'maccatalyst' 14.2 and later."

And these lines found in the CommunityToolkit.Maui/CommunityToolkit.Maui.csproj project file:

    <SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">14.2</SupportedOSPlatformVersion>
    <SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">14.0</SupportedOSPlatformVersion>

But according to the document, https://docs.microsoft.com/en-us/dotnet/communitytoolkit/maui/, iOS 10 or higher is supported.

Which one is correct?

Expected Behavior

iOS 10 or higher is supported.

Steps To Reproduce

No

Link to public reproduction project repository

https://github.com/ForkBug/MauiIOSVersion

Environment

- .NET MAUI CommunityToolkit:1.2.0
- .NET MAUI: 6.0

Anything else?

No response

ForkBug avatar Sep 07 '22 12:09 ForkBug

These are the same lines of code which are in default .NET MAUI template. Maybe the API which we use is only supported on version 14.2 and later.

VladislavAntonyuk avatar Sep 07 '22 21:09 VladislavAntonyuk

Hope Ukraine get peace soon.

MAUI supports IOS 10 or higher (doc)

ForkBug avatar Sep 08 '22 01:09 ForkBug

Thank you @ForkBug. Could you please send a link to a small repro project. It will help us investigate the issue

VladislavAntonyuk avatar Sep 08 '22 06:09 VladislavAntonyuk

See this project: https://github.com/ForkBug/MauiIOSVersion Build the solution with VS 17.3.3, and many warnings will show up.

MauiIOSVersion\MauiProgram.cs(10,3,11,48): warning CA1416: This call site is reachable on: 'iOS' 10.0 and later, 'maccatalyst' 10.0 and later. 'AppBuilderExtensions.UseMauiCommunityToolkit(MauiAppBuilder)' is only supported on: 'iOS' 14.2 and later, 'maccatalyst' 14.2 and later. MauiIOSVersion\CommunityToolkit.Maui.SourceGenerators\CommunityToolkit.Maui.SourceGenerators.Generators.TextColorToGenerator\TimePickerTextColorTo.g.shared.cs(48,146,48,175): warning CA1416: This call site is reachable on: 'iOS' 10.0 and later, 'maccatalyst' 10.0 and later.

I think it is due to these lines in the CommunityToolkit.Maui/CommunityToolkit.Maui.csproj project file: <SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">14.2</SupportedOSPlatformVersion> <SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">14.0</SupportedOSPlatformVersion>

ForkBug avatar Sep 08 '22 13:09 ForkBug

I confirm it is reproduced. We will discuss the issue on next stand up

VladislavAntonyuk avatar Sep 08 '22 16:09 VladislavAntonyuk

I second this issue, I cannot use the community toolkit unless ios 11 is at least supported

LennoxP90 avatar Sep 09 '22 17:09 LennoxP90