From 563db65b124faca6791a419fe1c7088ef89383a4 Mon Sep 17 00:00:00 2001 From: ahall Date: Fri, 10 Jul 2026 12:00:51 +0100 Subject: [PATCH 1/4] fix: suppress IL2026/IL2104 trim analysis warnings on mobile TodoApp samples net10.0-ios (and mobile TFMs generally) enable the IL trim analyzer during 'dotnet build', not just 'dotnet publish', because these SDKs are marked trimmable by default. This surfaced IL2026/IL2104 warnings on TodoApp.Avalonia.iOS pointing at documented, trim-unsafe framework APIs (Avalonia's BindingPlugins.DataValidators, EF Core's DbContext(DbContextOptions) ctor) - not bugs in the sample code. The CI pipelines for these samples only ever run 'dotnet build', never 'dotnet publish -p:PublishTrimmed=true', so no actual IL trimming/linking occurs; the analyzer is pure diagnostic noise here. Add true to: - TodoApp.Avalonia.iOS.csproj (the confirmed, reported case) - TodoApp.Avalonia.Android.csproj (same shared code path, precautionary) - TodoApp.MAUI.csproj, scoped to the net10.0-ios TFM only Per Microsoft.NET.ILLink.targets, this property also sets EnableTrimAnalyzer=false, which disables the analyzer pass itself (not just its warning output), avoiding any analyzer-related build-time cost in addition to the noise. Fixes #521 --- .../TodoApp.Avalonia.Android.csproj | 13 +++++++++++++ .../TodoApp.Avalonia.iOS.csproj | 13 +++++++++++++ samples/todoapp/TodoApp.MAUI/TodoApp.MAUI.csproj | 14 ++++++++++++++ 3 files changed, 40 insertions(+) diff --git a/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.Android/TodoApp.Avalonia.Android.csproj b/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.Android/TodoApp.Avalonia.Android.csproj index dbd8391..1012992 100644 --- a/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.Android/TodoApp.Avalonia.Android.csproj +++ b/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.Android/TodoApp.Avalonia.Android.csproj @@ -9,6 +9,19 @@ 1.0 apk false + + + true diff --git a/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.iOS/TodoApp.Avalonia.iOS.csproj b/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.iOS/TodoApp.Avalonia.iOS.csproj index 9533f4d..24c2d93 100644 --- a/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.iOS/TodoApp.Avalonia.iOS.csproj +++ b/samples/todoapp/TodoApp.Avalonia/TodoApp.Avalonia.iOS/TodoApp.Avalonia.iOS.csproj @@ -4,6 +4,19 @@ net10.0-ios 15.0 enable + + + true diff --git a/samples/todoapp/TodoApp.MAUI/TodoApp.MAUI.csproj b/samples/todoapp/TodoApp.MAUI/TodoApp.MAUI.csproj index 6235f7b..df0379e 100644 --- a/samples/todoapp/TodoApp.MAUI/TodoApp.MAUI.csproj +++ b/samples/todoapp/TodoApp.MAUI/TodoApp.MAUI.csproj @@ -29,6 +29,20 @@ 21.0 10.0.17763.0 10.0.17763.0 + + + true From f952d679b728dadce455679e2be403fa2ef65afd Mon Sep 17 00:00:00 2001 From: ahall Date: Fri, 10 Jul 2026 12:31:59 +0100 Subject: [PATCH 2/4] ci: disable real ILLink trimming on iOS build-only sample checks Watching PR #531's CI run revealed a distinct, more expensive problem than the trim-analyzer warnings fixed in the prior commit: net10.0-ios Release builds run the actual ILLink trimmer (not just the analyzer) even for a plain 'dotnet build' against a simulator RID. 'Optimizing assemblies for size' / 'IL stripping assemblies' dominates ~90% of the build time, stretching the todoapp-avalonia/ios and todoapp-maui/ios jobs to 15+ minutes each, while the equivalent Android jobs for the same samples complete in ~3.5 minutes total. Since these CI jobs only ever run 'dotnet build' as a compile sanity check - never 'dotnet publish' - there is no benefit to actually linking here. Pass -p:PublishTrimmed=false on the dotnet build command line for the two affected 'ios' jobs only: - build-samples-todoapp-avalonia.yml - build-samples-todoapp-maui.yml Deliberately a CI-only override (not a .csproj change), so a developer following the tutorial who runs a real 'dotnet publish' still gets the platform's normal trimming default and app size. Related to #521 --- .github/workflows/build-samples-todoapp-avalonia.yml | 9 +++++++++ .github/workflows/build-samples-todoapp-maui.yml | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/.github/workflows/build-samples-todoapp-avalonia.yml b/.github/workflows/build-samples-todoapp-avalonia.yml index 2312b59..66194bd 100644 --- a/.github/workflows/build-samples-todoapp-avalonia.yml +++ b/.github/workflows/build-samples-todoapp-avalonia.yml @@ -126,7 +126,16 @@ jobs: run: dotnet restore ${{ env.iOSProjectFile }} - name: Build iOS project + # -p:PublishTrimmed=false: net10.0-ios Release builds run the real ILLink trimmer + # (not just the trim analyzer) even for a plain `dotnet build` of a simulator RID - + # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the + # build time here (15+ minutes). This job never publishes or ships an app - it's a + # build-only sanity check - so there's no benefit to actually linking. Passed only on + # the command line (not set in the .csproj) so a real `dotnet publish` by a developer + # following the tutorial still gets the platform's normal trimming default. See + # https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.iOSProjectFile }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore + -p:PublishTrimmed=false diff --git a/.github/workflows/build-samples-todoapp-maui.yml b/.github/workflows/build-samples-todoapp-maui.yml index 0f977cb..7c08006 100644 --- a/.github/workflows/build-samples-todoapp-maui.yml +++ b/.github/workflows/build-samples-todoapp-maui.yml @@ -98,8 +98,17 @@ jobs: run: dotnet restore ${{ env.MauiProjectFile }} -p:TargetFramework=${{ env.iOSTargetFramework }} - name: Build MAUI project (iOS TFM only) + # -p:PublishTrimmed=false: net10.0-ios Release builds run the real ILLink trimmer + # (not just the trim analyzer) even for a plain `dotnet build` of a simulator RID - + # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the + # build time here (15+ minutes). This job never publishes or ships an app - it's a + # build-only sanity check - so there's no benefit to actually linking. Passed only on + # the command line (not set in the .csproj) so a real `dotnet publish` by a developer + # following the tutorial still gets the platform's normal trimming default. See + # https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.MauiProjectFile }} -f ${{ env.iOSTargetFramework }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore + -p:PublishTrimmed=false From 40ff56a5577421721073efabeab7e2288920a053 Mon Sep 17 00:00:00 2001 From: ahall Date: Fri, 10 Jul 2026 12:34:23 +0100 Subject: [PATCH 3/4] fix(ci): use MtouchLink=None instead of PublishTrimmed=false for iOS builds The prior commit's -p:PublishTrimmed=false broke both iOS jobs immediately (confirmed via CI run 29089733157): the iOS SDK hard-rejects it - error: iOS projects must build with PublishTrimmed=true. Current value: false. Set 'MtouchLink=None' instead to disable trimming for all assemblies. [Xamarin.Shared.Sdk.targets(304,3)] Switch to the SDK-blessed -p:MtouchLink=None, which keeps the mandatory PublishTrimmed=true while skipping the actual link/strip work that was dominating build time. --- .../build-samples-todoapp-avalonia.yml | 18 +++++++++++------- .../workflows/build-samples-todoapp-maui.yml | 18 +++++++++++------- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build-samples-todoapp-avalonia.yml b/.github/workflows/build-samples-todoapp-avalonia.yml index 66194bd..43383b1 100644 --- a/.github/workflows/build-samples-todoapp-avalonia.yml +++ b/.github/workflows/build-samples-todoapp-avalonia.yml @@ -126,16 +126,20 @@ jobs: run: dotnet restore ${{ env.iOSProjectFile }} - name: Build iOS project - # -p:PublishTrimmed=false: net10.0-ios Release builds run the real ILLink trimmer - # (not just the trim analyzer) even for a plain `dotnet build` of a simulator RID - + # -p:MtouchLink=None: net10.0-ios Release builds run the real ILLink trimmer (not + # just the trim analyzer) even for a plain `dotnet build` of a simulator RID - # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the # build time here (15+ minutes). This job never publishes or ships an app - it's a - # build-only sanity check - so there's no benefit to actually linking. Passed only on - # the command line (not set in the .csproj) so a real `dotnet publish` by a developer - # following the tutorial still gets the platform's normal trimming default. See - # https://github.com/CommunityToolkit/Datasync/issues/521. + # build-only sanity check - so there's no benefit to actually linking. + # `-p:PublishTrimmed=false` is rejected by the SDK for iOS ("iOS projects must build + # with PublishTrimmed=true ... Set 'MtouchLink=None' instead to disable trimming for + # all assemblies" - Xamarin.Shared.Sdk.targets); MtouchLink=None is the SDK-blessed + # way to keep PublishTrimmed=true while skipping the actual link/strip step. Passed + # only on the command line (not set in the .csproj) so a real `dotnet publish` by a + # developer following the tutorial still gets the platform's normal trimming default. + # See https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.iOSProjectFile }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore - -p:PublishTrimmed=false + -p:MtouchLink=None diff --git a/.github/workflows/build-samples-todoapp-maui.yml b/.github/workflows/build-samples-todoapp-maui.yml index 7c08006..cd8b2fc 100644 --- a/.github/workflows/build-samples-todoapp-maui.yml +++ b/.github/workflows/build-samples-todoapp-maui.yml @@ -98,17 +98,21 @@ jobs: run: dotnet restore ${{ env.MauiProjectFile }} -p:TargetFramework=${{ env.iOSTargetFramework }} - name: Build MAUI project (iOS TFM only) - # -p:PublishTrimmed=false: net10.0-ios Release builds run the real ILLink trimmer - # (not just the trim analyzer) even for a plain `dotnet build` of a simulator RID - + # -p:MtouchLink=None: net10.0-ios Release builds run the real ILLink trimmer (not + # just the trim analyzer) even for a plain `dotnet build` of a simulator RID - # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the # build time here (15+ minutes). This job never publishes or ships an app - it's a - # build-only sanity check - so there's no benefit to actually linking. Passed only on - # the command line (not set in the .csproj) so a real `dotnet publish` by a developer - # following the tutorial still gets the platform's normal trimming default. See - # https://github.com/CommunityToolkit/Datasync/issues/521. + # build-only sanity check - so there's no benefit to actually linking. + # `-p:PublishTrimmed=false` is rejected by the SDK for iOS ("iOS projects must build + # with PublishTrimmed=true ... Set 'MtouchLink=None' instead to disable trimming for + # all assemblies" - Xamarin.Shared.Sdk.targets); MtouchLink=None is the SDK-blessed + # way to keep PublishTrimmed=true while skipping the actual link/strip step. Passed + # only on the command line (not set in the .csproj) so a real `dotnet publish` by a + # developer following the tutorial still gets the platform's normal trimming default. + # See https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.MauiProjectFile }} -f ${{ env.iOSTargetFramework }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore - -p:PublishTrimmed=false + -p:MtouchLink=None From a0510a53d93eb3afe00c6de930fc29e17d56a63c Mon Sep 17 00:00:00 2001 From: ahall Date: Fri, 10 Jul 2026 12:57:45 +0100 Subject: [PATCH 4/4] ci: build all samples in Debug instead of Release Per https://blog.verslu.is/maui/exclude-assemblies-from-trimming/, Debug configuration avoids .NET's IL trimming/AOT machinery entirely, which is a simpler and more broadly effective fix than the prior MtouchLink=None command-line workaround (removed here - no longer needed). These CI workflows are build-only compile sanity checks - none of them publish or ship an app - so there is no reason to pay for Release-only optimizations (trimming, AOT) anywhere in this matrix. Switch DOTNET_CONFIGURATION from Release to Debug across all build-samples-*.yml workflows for consistency, not just the two mobile ones that were observed to be slow. build-library.yml and build-template.yml are intentionally left at Release, since those build the actual shipped library and dotnet template, not a sample. Related to #521 --- ...build-samples-datasync-server-cosmosdb.yml | 6 ++++- .../build-samples-datasync-server.yml | 6 ++++- .../build-samples-todoapp-avalonia.yml | 23 ++++++++----------- .../build-samples-todoapp-blazor-wasm.yml | 6 ++++- .../workflows/build-samples-todoapp-maui.yml | 23 ++++++++----------- .../workflows/build-samples-todoapp-mvc.yml | 6 ++++- .../build-samples-todoapp-tutorial.yml | 6 ++++- .../workflows/build-samples-todoapp-uno.yml | 6 ++++- .../build-samples-todoapp-windows.yml | 6 ++++- 9 files changed, 53 insertions(+), 35 deletions(-) diff --git a/.github/workflows/build-samples-datasync-server-cosmosdb.yml b/.github/workflows/build-samples-datasync-server-cosmosdb.yml index 35eab5b..7468ba8 100644 --- a/.github/workflows/build-samples-datasync-server-cosmosdb.yml +++ b/.github/workflows/build-samples-datasync-server-cosmosdb.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' SolutionFile: 'samples/datasync-server-cosmosdb-singlecontainer/Datasync.Server.CosmosDb.SingleContainer.sln' permissions: diff --git a/.github/workflows/build-samples-datasync-server.yml b/.github/workflows/build-samples-datasync-server.yml index dc41baf..1a4f28f 100644 --- a/.github/workflows/build-samples-datasync-server.yml +++ b/.github/workflows/build-samples-datasync-server.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' SolutionFile: 'samples/datasync-server/Sample.Datasync.Server.sln' permissions: diff --git a/.github/workflows/build-samples-todoapp-avalonia.yml b/.github/workflows/build-samples-todoapp-avalonia.yml index 43383b1..e5a1f48 100644 --- a/.github/workflows/build-samples-todoapp-avalonia.yml +++ b/.github/workflows/build-samples-todoapp-avalonia.yml @@ -7,7 +7,15 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release triggers the real ILLink trimmer (not just the trim analyzer) on the iOS head even + # for a plain `dotnet build` of a simulator RID - "Optimizing assemblies for + # size"/"IL stripping assemblies" dominated ~90% of that job's build time (15+ minutes). + # Debug avoids that IL trimming/AOT machinery entirely (see + # https://blog.verslu.is/maui/exclude-assemblies-from-trimming/ and + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug for consistency, even on heads where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' # NOTE: This sample's solution (TodoApp.Avalonia.sln) also contains Android and iOS heads # (net10.0-android / net10.0-ios). Only the shared and Desktop (net10.0) projects are built # directly here, not the full .sln - the Android and iOS heads are built by their own jobs @@ -126,20 +134,7 @@ jobs: run: dotnet restore ${{ env.iOSProjectFile }} - name: Build iOS project - # -p:MtouchLink=None: net10.0-ios Release builds run the real ILLink trimmer (not - # just the trim analyzer) even for a plain `dotnet build` of a simulator RID - - # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the - # build time here (15+ minutes). This job never publishes or ships an app - it's a - # build-only sanity check - so there's no benefit to actually linking. - # `-p:PublishTrimmed=false` is rejected by the SDK for iOS ("iOS projects must build - # with PublishTrimmed=true ... Set 'MtouchLink=None' instead to disable trimming for - # all assemblies" - Xamarin.Shared.Sdk.targets); MtouchLink=None is the SDK-blessed - # way to keep PublishTrimmed=true while skipping the actual link/strip step. Passed - # only on the command line (not set in the .csproj) so a real `dotnet publish` by a - # developer following the tutorial still gets the platform's normal trimming default. - # See https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.iOSProjectFile }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore - -p:MtouchLink=None diff --git a/.github/workflows/build-samples-todoapp-blazor-wasm.yml b/.github/workflows/build-samples-todoapp-blazor-wasm.yml index 8835c45..9fff455 100644 --- a/.github/workflows/build-samples-todoapp-blazor-wasm.yml +++ b/.github/workflows/build-samples-todoapp-blazor-wasm.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' SolutionFile: 'samples/todoapp-blazor-wasm/TodoApp.BlazorWasm.sln' permissions: diff --git a/.github/workflows/build-samples-todoapp-maui.yml b/.github/workflows/build-samples-todoapp-maui.yml index cd8b2fc..40b4ccd 100644 --- a/.github/workflows/build-samples-todoapp-maui.yml +++ b/.github/workflows/build-samples-todoapp-maui.yml @@ -7,7 +7,15 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release triggers the real ILLink trimmer (not just the trim analyzer) on the iOS head even + # for a plain `dotnet build` of a simulator RID - "Optimizing assemblies for + # size"/"IL stripping assemblies" dominated ~90% of that job's build time (15+ minutes). + # Debug avoids that IL trimming/AOT machinery entirely (see + # https://blog.verslu.is/maui/exclude-assemblies-from-trimming/ and + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug for consistency, even on heads where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' # TodoApp.MAUI.csproj targets net10.0-android;net10.0-ios, with net10.0-windows10.0.19041.0 # conditionally appended only when building on Windows (that head is built separately in # build-samples-todoapp-windows.yml). Restore/build here is explicitly scoped to one mobile @@ -98,21 +106,8 @@ jobs: run: dotnet restore ${{ env.MauiProjectFile }} -p:TargetFramework=${{ env.iOSTargetFramework }} - name: Build MAUI project (iOS TFM only) - # -p:MtouchLink=None: net10.0-ios Release builds run the real ILLink trimmer (not - # just the trim analyzer) even for a plain `dotnet build` of a simulator RID - - # "Optimizing assemblies for size"/"IL stripping assemblies" dominates ~90% of the - # build time here (15+ minutes). This job never publishes or ships an app - it's a - # build-only sanity check - so there's no benefit to actually linking. - # `-p:PublishTrimmed=false` is rejected by the SDK for iOS ("iOS projects must build - # with PublishTrimmed=true ... Set 'MtouchLink=None' instead to disable trimming for - # all assemblies" - Xamarin.Shared.Sdk.targets); MtouchLink=None is the SDK-blessed - # way to keep PublishTrimmed=true while skipping the actual link/strip step. Passed - # only on the command line (not set in the .csproj) so a real `dotnet publish` by a - # developer following the tutorial still gets the platform's normal trimming default. - # See https://github.com/CommunityToolkit/Datasync/issues/521. run: > dotnet build ${{ env.MauiProjectFile }} -f ${{ env.iOSTargetFramework }} --configuration ${{ env.DOTNET_CONFIGURATION }} --no-restore - -p:MtouchLink=None diff --git a/.github/workflows/build-samples-todoapp-mvc.yml b/.github/workflows/build-samples-todoapp-mvc.yml index f8415ff..3650820 100644 --- a/.github/workflows/build-samples-todoapp-mvc.yml +++ b/.github/workflows/build-samples-todoapp-mvc.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' SolutionFile: 'samples/todoapp-mvc/part5.sln' permissions: diff --git a/.github/workflows/build-samples-todoapp-tutorial.yml b/.github/workflows/build-samples-todoapp-tutorial.yml index 8e9435a..0ef0a9e 100644 --- a/.github/workflows/build-samples-todoapp-tutorial.yml +++ b/.github/workflows/build-samples-todoapp-tutorial.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' ServerProjectFile: 'samples/todoapp-tutorial/ServerApp/ServerApp.csproj' # ClientApp is a WPF project targeting net10.0-windows, so it is built on a windows-latest # runner in a separate job below. See https://github.com/CommunityToolkit/Datasync/issues/510. diff --git a/.github/workflows/build-samples-todoapp-uno.yml b/.github/workflows/build-samples-todoapp-uno.yml index 196c410..54ea20d 100644 --- a/.github/workflows/build-samples-todoapp-uno.yml +++ b/.github/workflows/build-samples-todoapp-uno.yml @@ -16,7 +16,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' # TodoApp.Uno.csproj is a single Uno.Sdk project with a multi-head TargetFrameworks list # (net10.0-android;net10.0-ios;net10.0-maccatalyst;net10.0-windows10.0.26100; # net10.0-browserwasm;net10.0-desktop). No single runner can build every head (mobile heads diff --git a/.github/workflows/build-samples-todoapp-windows.yml b/.github/workflows/build-samples-todoapp-windows.yml index dd8c2e4..c6300ee 100644 --- a/.github/workflows/build-samples-todoapp-windows.yml +++ b/.github/workflows/build-samples-todoapp-windows.yml @@ -7,7 +7,11 @@ env: DOTNET_VERSION: '10.0.x' DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 DOTNET_NOLOGO: true - DOTNET_CONFIGURATION: 'Release' + # Debug (not Release): this is a build-only compile sanity check, never published/shipped. + # Release builds pointlessly enable IL trimming/AOT machinery on some sample heads (see + # https://github.com/CommunityToolkit/Datasync/issues/521), so all sample CI workflows build + # Debug to avoid that overhead consistently, even where it isn't currently an issue. + DOTNET_CONFIGURATION: 'Debug' # WinUI3 declares x86;x64;ARM64 with no AnyCPU, so Platform must be # specified explicitly - the CLI default of AnyCPU is not a valid configuration for this project. WinUI3ProjectFile: 'samples/todoapp/TodoApp.WinUI3/TodoApp.WinUI3.csproj'