Repository navigation
Support shared/custom Platforms folder mappings in SingleProject - #35045
Conversation
Add MauiPlatformSpecificFolder-driven compile filtering support for shared and condition-gated Platforms/* folders while preserving the existing ExcludeFromCurrentConfiguration flow. Fixes #35042 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.sh | bash -s -- 35045Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.ps1) } 35045" |
There was a problem hiding this comment.
Pull request overview
Updates MAUI Controls SingleProject platform compile filtering to honor @(MauiPlatformSpecificFolder) mappings (including shared/custom Platforms/* folders), while keeping the existing ExcludeFromCurrentConfiguration + _MauiRemovePlatformCompileItems design-time behavior and maintaining backward compatibility.
Changes:
- Add
TargetPlatformIdentifiers(plural) support with a normalization step for legacyTargetPlatformIdentifier(singular). - Collect “allowed” platform compile items from
@(MauiPlatformSpecificFolder)and exclude them from the Platforms-folder removal pass. - Add MSBuild unit tests covering shared folders, extending built-in mappings, backward compatibility, and condition-gated folders.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/Controls/tests/Xaml.UnitTests/MSBuild/MSBuildTests.cs | Adds focused MSBuild unit tests and helpers to validate SingleProject compile filtering for shared/custom folder mappings and legacy metadata. |
| src/Controls/src/Build.Tasks/nuget/buildTransitive/netstandard2.0/Microsoft.Maui.Controls.SingleProject.targets | Implements compile-item collection based on MauiPlatformSpecificFolder.TargetPlatformIdentifiers and updates the removal logic to preserve allowed files. |
| src/Controls/src/Build.Tasks/nuget/buildTransitive/netstandard2.0/Microsoft.Maui.Controls.SingleProject.Before.targets | Adds default plural metadata and a normalization target to map legacy singular metadata to the new plural form. |
Handle whitespace in TargetPlatformIdentifiers lists and add coverage for spaced lists alongside the backward-compat path. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
MauiBot
left a comment
There was a problem hiding this comment.
Expert Review — 2 findings
See inline comments for details.
MauiBot
left a comment
There was a problem hiding this comment.
Expert Review — 6 findings
See inline comments for details.
…ata flip, whitespace tolerance, tests
Targets changes:
- Drop redundant TargetPlatformIdentifiers from built-in MauiPlatformSpecificFolder items;
let _MauiNormalizePlatformSpecificFolders be the single source of truth for back-filling
the plural metadata from the legacy singular TargetPlatformIdentifier.
- Apply EnsureTrailingSlash() to %(MauiPlatformSpecificFolder.Identity) at the use site so a
user-supplied <MauiPlatformSpecificFolder Include="Platforms\Apple" /> (no trailing slash)
cannot silently match sibling folders such as Platforms\AppleX or Platforms\AppleLegacy.
- Switch the TPI list comparison from String.Replace(' ', '') to Regex.Replace(\s+, '') so
TPI lists formatted across multiple lines or copy-pasted with tabs continue to match.
- Add new _MauiUnflipKeptCompileItemMetadata target running AfterTargets _MauiRemovePlatformCompileItems
to flip ExcludeFromCurrentConfiguration=false on the kept items, so files in shared folders
(e.g. Platforms/Apple/) render correctly in VS Solution Explorer / IntelliSense for the
active configuration. Runs AFTER the remove target to avoid interfering with the
cross-item-type batching it relies on.
- Document the cross-item-type batching pattern in _MauiPlatformCompileToRemove so future
refactors don't unintentionally break it.
Test changes:
- Add tab/mixed-whitespace InlineData rows to SingleProject_SharedPlatformFolderMappingsAreRespected
exercising the Regex.Replace(\s+, '') path.
- Restructure SingleProject_BuiltInPlatformFoldersCanBeExtended to use a
<Target BeforeTargets="_MauiNormalizePlatformSpecificFolders"> wrapper. Real users author
this as a Target rather than an inline ItemGroup; in a normal SDK-style csproj the user's
project body is evaluated before NuGet imports, so an inline Update would silently no-op.
- Add SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders regression test
with a sibling AppleX folder verifying the EnsureTrailingSlash guard.
- Add SingleProject_NonPlatformBuildExcludesPlatformSpecificFoldersButKeepsConditionGated for the
empty TPI / non-platform / design-time evaluation path.
- Add SingleProject_SingularPlatformFolderMetadataRemainsBackwardCompatible and
SingleProject_ConditionGatedPlatformFoldersCanParticipateWithoutATargetPlatformIdentifier
to lock in normalize-target back-fill and empty-TPI behavior.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…in sibling-folder test - _MauiNormalizePlatformSpecificFolders no longer lists _MauiCollectPlatformSpecificCompileItems in BeforeTargets; Collect already declares DependsOnTargets='_MauiNormalizePlatformSpecificFolders' so the ordering for that pair was already guaranteed. The remaining BeforeTargets entry on _MauiRemovePlatformCompileItems is load-bearing because Remove does not depend on Collect (so Normalize-Before-Remove is the only way to back-fill TargetPlatformIdentifiers when SingleProject runs Remove without having gone through Collect). - SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders now also exercises maccatalyst (was ios-only). The trailing-slash logic is TPI-independent, but covering both halves of the mapping closes the gap. 23/23 SingleProject_* MSBuild integration tests pass locally. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Multi-round multi-model code review summaryI ran a multi-round multi-model code review on this PR and pushed the resulting refinements directly to the branch (commits Round 1 (against
|
| Concern | Resolution |
|---|---|
Plural/singular metadata duplication on built-in MauiPlatformSpecificFolder items |
Built-ins now declare only the singular TargetPlatformIdentifier; a new _MauiNormalizePlatformSpecificFolders target back-fills TargetPlatformIdentifiers. Single source of truth. |
Sibling-folder glob foot-gun (Platforms\Apple would match Platforms\AppleX\) |
EnsureTrailingSlash() applied at the glob use site in _MauiCollectPlatformSpecificCompileItems. |
Whitespace tolerance in TargetPlatformIdentifiers |
Replace(' ', '') → Regex.Replace(\s+, ''), so tabs/newlines in multi-line metadata are tolerated. |
| Shared-folder files appearing greyed-out in VS IntelliSense | New _MauiUnflipKeptCompileItemMetadata target flips ExcludeFromCurrentConfiguration back to false on kept items. |
| Cross-item-type batching foot-gun is undocumented | Long inline comment on _MauiPlatformCompileToRemove explains why the %(Compile.X) reference triggers per-batch evaluation, and why anything that mutates ExcludeFromCurrentConfiguration before remove will silently break it. |
| Test coverage gaps (sibling-folder regression, IDE-flip target ordering, normalize back-fill, condition-gated paths, whitespace) | 4 new test methods + 4 new InlineData rows in MSBuildTests.cs. |
Subtle gotcha worth highlighting
The IDE metadata flip was initially placed inline inside _MauiCollectPlatformSpecificCompileItems (i.e. before remove). That broke the cross-item-type batching on %(Compile.ExcludeFromCurrentConfiguration): with no items left in the 'true' batch, the to-remove glob never fired and every platform .cs file landed in the compile list, producing CS0102 duplicate-definition errors when both iOS/ and MacCatalyst/ CurrentPlatform.cs were compiled together.
The fix: the flip lives in a dedicated _MauiUnflipKeptCompileItemMetadata target running AfterTargets="_MauiRemovePlatformCompileItems". The inline comment on that target spells this out so a future maintainer doesn't "simplify" it back into Collect. 16-of-21 → 21-of-21 tests pass locally with this placement.
Round 2 (against 664616d726) → minor cleanups in 6448db07ff
All three reviewers returned LGTM with high confidence. The only follow-up items were maintainability nits, which I applied:
- Redundant
BeforeTargetsentry on_MauiNormalizePlatformSpecificFolders— the target listed both_MauiCollectPlatformSpecificCompileItemsand_MauiRemovePlatformCompileItemsinBeforeTargets, but Collect already declaresDependsOnTargets="_MauiNormalizePlatformSpecificFolders". Dropped the redundant entry; only the load-bearing_MauiRemovePlatformCompileItemsremains (Remove does not depend on Collect). SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFoldersonly probed iOS — added two more[InlineData]rows so the test exercises bothiosandmaccatalyst(the trailing-slash logic is TPI-independent, but covering both halves of the mapping is cheap insurance).
Local verification
dotnet test src/Controls/tests/Xaml.UnitTests/Controls.Xaml.UnitTests.csproj \
-c Debug --no-build \
--filter "FullyQualifiedName~MSBuildTests.SingleProject_"
Passed! - Failed: 0, Passed: 23, Skipped: 0, Total: 23, Duration: 28 s
Remaining 💡 suggestions (non-blocking, optional follow-ups)
- Element-form whitespace test case — the new whitespace
InlineDatarows go through XAttribute serialisation, where literal\tis emitted as	and bypasses XML attribute-value normalisation. A user who types element-form metadata (<TargetPlatformIdentifiers>ios;\n maccatalyst</TargetPlatformIdentifiers>) would hit a different (and arguably more realistic) authoring path that preserves whitespace per XML rules. Belt-and-suspenders only; not a blocker. - VS IntelliSense visual verification — the
_MauiUnflipKeptCompileItemMetadatatarget sets metadata that is consumed by Visual Studio, which can't be asserted from an MSBuild integration test. The build-output side is locked in by the test suite, but the actual IDE rendering of files in shared folders (e.g.Platforms/Apple/) deserves a quick manual check before sign-off.
Reviewer methodology
Each round ran three reviewers concurrently (Claude Opus, GPT-5.5, Claude Sonnet) following the repo's code-review skill rules. Reviewers were instructed to read full source files (not just diffs) and form an independent assessment before reading the PR narrative. Findings were synthesised across reviewers; multi-model consensus was treated as elevated signal. The exit criterion was "all reviewers return LGTM"; that was met in Round 2.
Note
This is a multi-model AI review summary; please apply your own judgement before merging.
|
/review -b feature/refactor-copilot-yml |
kubaflo
left a comment
There was a problem hiding this comment.
Could you review the ai's suggestions?
|
/review -b feature/refactor-copilot-yml -p ios |
MauiBot
left a comment
There was a problem hiding this comment.
Expert Review — 1 findings
See inline comments for details.
This comment has been minimized.
This comment has been minimized.
|
/review -b feature/enhanced-reviewer -p android |
MauiBot
left a comment
There was a problem hiding this comment.
AI Review Summary
@Redth — new AI review results are available based on this last commit:
f46fc26. To request a fresh review after new comments or commits, comment/review rerun.
Review Sessions — click to expand
Gate — Test Before & After Fix
Gate Result: ✅ PASSED
Platform: ANDROID · Base: main · Merge base: bb4e7040
| Test | Without Fix (expect FAIL) | With Fix (expect PASS) |
|---|---|---|
📄 MSBuildTests MSBuildTests |
✅ FAIL — 241s | ✅ PASS — 120s |
🔴 Without fix — 📄 MSBuildTests: FAIL ✅ · 241s
(truncated to last 15,000 chars)
t10.0/System.Net.ServicePoint.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.Sockets.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.WebClient.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.WebHeaderCollection.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.WebProxy.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.WebSockets.Client.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Net.WebSockets.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Numerics.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Numerics.Vectors.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.ObjectModel.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.DispatchProxy.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Emit.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Emit.ILGeneration.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Emit.Lightweight.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Extensions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Metadata.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.Primitives.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Reflection.TypeExtensions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Resources.Reader.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Resources.ResourceManager.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Resources.Writer.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.CompilerServices.Unsafe.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.CompilerServices.VisualC.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Extensions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Handles.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.InteropServices.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.InteropServices.JavaScript.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.InteropServices.RuntimeInformation.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Intrinsics.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Loader.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Numerics.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Serialization.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Serialization.Formatters.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Serialization.Json.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Serialization.Primitives.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Runtime.Serialization.Xml.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.AccessControl.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Claims.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.Algorithms.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.Cng.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.Csp.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.Encoding.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.OpenSsl.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.Primitives.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Cryptography.X509Certificates.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Principal.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.Principal.Windows.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Security.SecureString.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.ServiceModel.Web.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.ServiceProcess.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.Encoding.CodePages.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.Encoding.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.Encoding.Extensions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.Encodings.Web.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.Json.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Text.RegularExpressions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.AccessControl.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Channels.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Overlapped.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Tasks.Dataflow.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Tasks.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Tasks.Extensions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Tasks.Parallel.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Thread.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.ThreadPool.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Threading.Timer.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Transactions.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Transactions.Local.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.ValueTuple.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Web.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Web.HttpUtility.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Windows.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.Linq.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.ReaderWriter.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.Serialization.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.XDocument.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.XmlDocument.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.XmlSerializer.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.XPath.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/System.Xml.XPath.XDocument.dll /reference:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/ref/net10.0/WindowsBase.dll /features:"InterceptorsNamespaces=;Microsoft.Extensions.Validation.Generated;Microsoft.Maui.Controls.Generated" /debug+ /debug:portable /filealign:512 /optimize- /out:obj/Debug/net10.0/test.dll /refout:obj/Debug/net10.0/refint/test.dll /target:library /warnaserror- /utf8output /deterministic+ /sourcelink:obj/Debug/net10.0/test.sourcelink.json /langversion:14.0 /embed:Entry.cs /embed:"obj/Debug/net10.0/.NETCoreApp,Version=v10.0.AssemblyAttributes.cs" /embed:obj/Debug/net10.0/test.AssemblyInfo.cs /analyzerconfig:/home/vsts/work/1/s/.editorconfig /analyzerconfig:obj/Debug/net10.0/test.GeneratedMSBuildEditorConfig.editorconfig /analyzerconfig:/home/vsts/work/1/s/.dotnet/sdk/10.0.100/Sdks/Microsoft.NET.Sdk/analyzers/build/config/analysislevel_10_default.globalconfig /analyzer:/home/vsts/work/1/s/.dotnet/sdk/10.0.100/Sdks/Microsoft.NET.Sdk/targets/../analyzers/Microsoft.CodeAnalysis.CSharp.NetAnalyzers.dll /analyzer:/home/vsts/work/1/s/.dotnet/sdk/10.0.100/Sdks/Microsoft.NET.Sdk/targets/../analyzers/Microsoft.CodeAnalysis.NetAnalyzers.dll /analyzer:/home/vsts/work/1/s/.buildtasks/Microsoft.Maui.Controls.SourceGen.dll /analyzer:/home/vsts/work/1/s/.buildtasks/Microsoft.Maui.Controls.BindingSourceGen.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/Microsoft.Interop.ComInterfaceGenerator.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/Microsoft.Interop.JavaScript.JSImportGenerator.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/Microsoft.Interop.LibraryImportGenerator.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/Microsoft.Interop.SourceGeneration.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/System.Text.Json.SourceGeneration.dll /analyzer:/home/vsts/work/1/s/.dotnet/packs/Microsoft.NETCore.App.Ref/10.0.0/analyzers/dotnet/cs/System.Text.RegularExpressions.Generator.dll Entry.cs "obj/Debug/net10.0/.NETCoreApp,Version=v10.0.AssemblyAttributes.cs" obj/Debug/net10.0/test.AssemblyInfo.cs /warnaserror+:NU1605,SYSLIB0011'
Attempt to open named pipe 'mjyEUbkln+tmf2umAOfDBNUVhsWP+SWAbrVpw2i1Cms'
Attempt to connect named pipe 'mjyEUbkln+tmf2umAOfDBNUVhsWP+SWAbrVpw2i1Cms'
Named pipe 'mjyEUbkln+tmf2umAOfDBNUVhsWP+SWAbrVpw2i1Cms' connected
Begin writing request for test (net10.0)
End writing request for test (net10.0)
Begin reading response for test (net10.0)
End reading response for test (net10.0)
1>/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/Entry.cs(6,32): error CS0103: The name 'ExtendedIosMarker' does not exist in the current context [/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/test.csproj]
CompilerServer: server - server processed compilation - test (net10.0)
1>Done Building Project "/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/test.csproj" (Build target(s)) -- FAILED.
Build FAILED.
"/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/test.csproj" (Build target) (1:7) ->
(CoreCompile target) ->
/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/Entry.cs(6,32): error CS0103: The name 'ExtendedIosMarker' does not exist in the current context [/home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/test.csproj]
0 Warning(s)
1 Error(s)
Time Elapsed 00:00:01.50
MSBuild binlog: /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/temp/SingleProject_BuiltInPlatformFoldersCanBeExtended/msbuild.binlog
Passed DesignTimeBuild [3 s]
Passed RandomEmbeddedResource [1 s]
Passed TargetsShouldSkip [3 s]
[xUnit.net 00:01:28.51] TouchXamlFile [SKIP]
[xUnit.net 00:01:28.51] source gen changes
[xUnit.net 00:01:28.51] Finished: Microsoft.Maui.Controls.Xaml.UnitTests
Skipped TouchXamlFile [1 ms]
Test Run Failed.
Total tests: 39
Passed: 19
Failed: 18
Skipped: 2
Total time: 1.4846 Minutes
🟢 With fix — 📄 MSBuildTests: PASS ✅ · 120s
Determining projects to restore...
All projects are up-to-date for restore.
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Graphics -> /home/vsts/work/1/s/artifacts/bin/Graphics/Debug/net10.0/Microsoft.Maui.Graphics.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Essentials -> /home/vsts/work/1/s/artifacts/bin/Essentials/Debug/net10.0/Microsoft.Maui.Essentials.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Core -> /home/vsts/work/1/s/artifacts/bin/Core/Debug/net10.0/Microsoft.Maui.dll
Controls.BindingSourceGen -> /home/vsts/work/1/s/artifacts/bin/Controls.BindingSourceGen/Debug/netstandard2.0/Microsoft.Maui.Controls.BindingSourceGen.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Maps -> /home/vsts/work/1/s/artifacts/bin/Maps/Debug/net10.0/Microsoft.Maui.Maps.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.Core -> /home/vsts/work/1/s/artifacts/bin/Controls.Core/Debug/net10.0/Microsoft.Maui.Controls.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.Xaml -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml/Debug/net10.0/Microsoft.Maui.Controls.Xaml.dll
Controls.Maps -> /home/vsts/work/1/s/artifacts/bin/Controls.Maps/Debug/net10.0/Microsoft.Maui.Controls.Maps.dll
TestUtils -> /home/vsts/work/1/s/artifacts/bin/TestUtils/Debug/netstandard2.0/Microsoft.Maui.TestUtils.dll
Maui25871Library -> /home/vsts/work/1/s/artifacts/bin/Maui25871Library/Debug/net10.0/Maui25871Library.dll
Controls.Xaml.UnitTests.InternalsVisibleAssembly -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests.InternalsVisibleAssembly/Debug/net10.0/Microsoft.Maui.Controls.Xaml.UnitTests.InternalsVisibleAssembly.dll
Controls.Xaml.UnitTests.InternalsHiddenAssembly -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests.InternalsHiddenAssembly/Debug/net10.0/Microsoft.Maui.Controls.Xaml.UnitTests.InternalsHiddenAssembly.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Graphics -> /home/vsts/work/1/s/artifacts/bin/Graphics/Debug/netstandard2.0/Microsoft.Maui.Graphics.dll
Controls.Xaml.UnitTests.ExternalAssembly -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests.ExternalAssembly/Debug/net10.0/Microsoft.Maui.Controls.Xaml.UnitTests.ExternalAssembly.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Essentials -> /home/vsts/work/1/s/artifacts/bin/Essentials/Debug/netstandard2.0/Microsoft.Maui.Essentials.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Core -> /home/vsts/work/1/s/artifacts/bin/Core/Debug/netstandard2.0/Microsoft.Maui.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.Core -> /home/vsts/work/1/s/artifacts/bin/Controls.Core/Debug/netstandard2.0/Microsoft.Maui.Controls.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.Xaml -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml/Debug/netstandard2.0/Microsoft.Maui.Controls.Xaml.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.SourceGen -> /home/vsts/work/1/s/artifacts/bin/Controls.SourceGen/Debug/netstandard2.0/Microsoft.Maui.Controls.SourceGen.dll
##vso[build.updatebuildnumber]10.0.90-ci+azdo.14370757
Controls.Build.Tasks -> /home/vsts/work/1/s/artifacts/bin/Controls.Build.Tasks/Debug/netstandard2.0/Microsoft.Maui.Controls.Build.Tasks.dll
Controls.Xaml.UnitTests -> /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/Microsoft.Maui.Controls.Xaml.UnitTests.dll
Test run for /home/vsts/work/1/s/artifacts/bin/Controls.Xaml.UnitTests/Debug/net10.0/Microsoft.Maui.Controls.Xaml.UnitTests.dll (.NETCoreApp,Version=v10.0)
VSTest version 18.0.1 (x64)
Starting test execution, please wait...
A total of 1 test files matched the specified pattern.
[xUnit.net 00:00:00.00] xUnit.net VSTest Adapter v2.8.2+699d445a1a (64-bit .NET 10.0.0)
[xUnit.net 00:00:00.56] Discovering: Microsoft.Maui.Controls.Xaml.UnitTests
[xUnit.net 00:00:05.85] Discovered: Microsoft.Maui.Controls.Xaml.UnitTests
[xUnit.net 00:00:05.86] Starting: Microsoft.Maui.Controls.Xaml.UnitTests
Passed SingleProject_NonPlatformBuildExcludesPlatformSpecificFoldersButKeepsConditionGated [2 s]
Passed NoXamlFiles [2 s]
Passed LinkedFile [2 s]
Passed HotReloadSupportForXSG(configuration: "Debug") [2 s]
Passed HotReloadSupportForXSG(configuration: "Release") [2 s]
Passed Clean [3 s]
Passed ValidateOnly(configuration: "ReleaseProd") [2 s]
Passed ValidateOnly(configuration: "Debug") [2 s]
Passed ValidateOnly(configuration: "Release") [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "ios", targetPlatformIdentifiers: "ios;maccatalyst", shouldIncludeAppleSharedFile: True) [1 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "maccatalyst", targetPlatformIdentifiers: "ios;\tmaccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "maccatalyst", targetPlatformIdentifiers: "ios; maccatalyst", shouldIncludeAppleSharedFile: True) [1 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "maccatalyst", targetPlatformIdentifiers: "ios;maccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "android", targetPlatformIdentifiers: "ios;maccatalyst", shouldIncludeAppleSharedFile: False) [1 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "maccatalyst", targetPlatformIdentifiers: "ios; \t maccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "ios", targetPlatformIdentifiers: "ios;\tmaccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "ios", targetPlatformIdentifiers: "ios; \t maccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "android", targetPlatformIdentifiers: "ios; maccatalyst", shouldIncludeAppleSharedFile: False) [1 s]
Passed SingleProject_SharedPlatformFolderMappingsAreRespected(targetPlatformIdentifier: "ios", targetPlatformIdentifiers: "ios; maccatalyst", shouldIncludeAppleSharedFile: True) [2 s]
Passed SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders(includePath: "Platforms\\Apple", targetPlatformIdentifier: "ios") [1 s]
Passed SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders(includePath: "Platforms\\Apple\\", targetPlatformIdentifier: "ios") [2 s]
Passed SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders(includePath: "Platforms\\Apple\\", targetPlatformIdentifier: "maccatalyst") [1 s]
Passed SingleProject_PlatformFolderWithoutTrailingSlashDoesNotMatchSiblingFolders(includePath: "Platforms\\Apple", targetPlatformIdentifier: "maccatalyst") [1 s]
[xUnit.net 00:00:55.93] ValidateOnly_WithErrors [SKIP]
[xUnit.net 00:00:55.93] source gen changes
Skipped ValidateOnly_WithErrors [1 ms]
Passed AddNewFile [3 s]
Passed BuildAProject [1 s]
Passed RandomXml [1 s]
Passed SingleProject_ConditionGatedPlatformFoldersCanParticipateWithoutATargetPlatformIdentifier(useLinuxFolder: True) [1 s]
Passed SingleProject_ConditionGatedPlatformFoldersCanParticipateWithoutATargetPlatformIdentifier(useLinuxFolder: False) [1 s]
Passed SingleProject_SingularPlatformFolderMetadataRemainsBackwardCompatible(targetPlatformIdentifier: "maccatalyst", shouldIncludeLegacyFile: False) [1 s]
Passed SingleProject_SingularPlatformFolderMetadataRemainsBackwardCompatible(targetPlatformIdentifier: "android", shouldIncludeLegacyFile: False) [2 s]
Passed SingleProject_SingularPlatformFolderMetadataRemainsBackwardCompatible(targetPlatformIdentifier: "ios", shouldIncludeLegacyFile: True) [1 s]
Passed SingleProject_CodesignEntitlementsRespected [1 s]
Passed SingleProject_DefaultEntitlementsUsedWhenNoCustomSet [1 s]
Passed SingleProject_BuiltInPlatformFoldersCanBeExtended [1 s]
Passed DesignTimeBuild [3 s]
Passed RandomEmbeddedResource [1 s]
Passed TargetsShouldSkip [3 s]
[xUnit.net 00:01:27.94] TouchXamlFile [SKIP]
[xUnit.net 00:01:27.94] source gen changes
[xUnit.net 00:01:27.95] Finished: Microsoft.Maui.Controls.Xaml.UnitTests
Skipped TouchXamlFile [1 ms]
Test Run Successful.
Total tests: 39
Passed: 37
Skipped: 2
Total time: 1.4841 Minutes
📁 Fix files reverted (3 files)
eng/pipelines/ci-copilot.ymlsrc/Controls/src/Build.Tasks/nuget/buildTransitive/netstandard2.0/Microsoft.Maui.Controls.SingleProject.Before.targetssrc/Controls/src/Build.Tasks/nuget/buildTransitive/netstandard2.0/Microsoft.Maui.Controls.SingleProject.targets
UI Tests
Full UI test matrix will run (no specific categories detected from PR changes).
Pre-Flight — Context & Validation
Issue: #35042 - Support shared/custom Platforms/* folder mappings in SingleProject
PR: #35045 - Support shared/custom Platforms folder mappings in SingleProject
Platforms Affected: android requested for testing; build-target behavior applies to all SingleProject platform TFMs
Files Changed: 2 implementation, 1 test
Key Findings
- PR extends
@(MauiPlatformSpecificFolder)compile filtering so shared/custom folders such asPlatforms/Apple/can be included for multiple target platform identifiers. - Prior review findings around trailing slash normalization, whitespace tolerance, IDE metadata unflipping, and workload-neutral tests appear addressed in the current PR code.
ghis unauthenticated in this environment; GitHub checks and private review surfaces could not be queried withgh, so public API/local checkout evidence was used where possible.
Code Review Summary
Verdict: NEEDS_DISCUSSION
Confidence: low
Errors: 0 | Warnings: 0 | Suggestions: 0
Key code review findings:
- No ❌ Error or
⚠️ Warning findings found in the current code. - CI status is undetermined/red from available evidence because authenticated
gh pr checks --requiredis unavailable.
Fix Candidates
| # | Source | Approach | Test Result | Files Changed | Notes |
|---|---|---|---|---|---|
| PR | PR #35045 | Normalize platform-folder metadata, collect per-platform keep-list, exclude keep-list from removal, unflip kept IDE metadata after removal | ✅ PASSED (Gate) | Microsoft.Maui.Controls.SingleProject.Before.targets, Microsoft.Maui.Controls.SingleProject.targets, MSBuildTests.cs |
Original PR |
Code Review — Deep Analysis
Code Review — PR #35045
Independent Assessment
What this changes: Adds MSBuild support for custom/shared MauiPlatformSpecificFolder mappings in SingleProject builds. It normalizes singular TargetPlatformIdentifier into plural TargetPlatformIdentifiers, collects platform-specific compile keep-items, excludes them from the blanket Platforms/** removal, and restores ExcludeFromCurrentConfiguration=false for kept files.
Inferred motivation: Enable folders such as Platforms/Apple/ to compile for both ios and maccatalyst without manual remove/re-include workarounds.
Reconciliation with PR Narrative
Author claims: The PR supports shared/custom platform folder mappings, keeps backward compatibility, preserves the existing removal/IDE metadata flow, and adds focused MSBuild tests.
Agreement/disagreement: Matches my independent assessment. The linked issue #35042 asks for exactly this extensibility point. The implementation covers the issue's examples plus additional edge cases: whitespace, missing trailing slash, singular metadata compatibility, condition-gated folders, and extending built-ins.
Prior Review Reconciliation
| Prior ❌ Error Finding | Source | Status | Evidence |
|---|---|---|---|
Tests passed real Apple TargetPlatformIdentifier globally, causing workload resolution failures on Linux/Android CI (NETSDK1178/NETSDK1208). |
MauiBot [major] on MSBuildTests.cs |
✅ Fixed | Current helper injects _SingleProjectTestTargetPlatformIdentifier inside a target before MAUI targets (MSBuildTests.cs:299-315), and test builds pass that private property instead of global TargetPlatformIdentifier (MSBuildTests.cs:712, 775, 839, 953). |
| Same global-TPI workload-resolution problem still present after partial mitigation. | MauiBot [major] on later commit |
✅ Fixed | Current code no longer uses global -p:TargetPlatformIdentifier=ios/maccatalyst in the added tests; the synthetic target sets $(TargetPlatformIdentifier) after SDK evaluation. |
Other prior warning/info findings were addressed or are non-blocking: whitespace now uses Regex.Replace(..., '\s+', ''), no-trailing-slash globs use EnsureTrailingSlash, and built-ins now keep singular metadata as the source of truth.
Blast Radius Assessment
- Runs for all instances: Yes, for all
SingleProject=trueMAUI builds, but only in MSBuild compile filtering. - Startup impact: No runtime/startup code affected.
- Static/shared state: No.
- Infrastructure risk: Medium blast radius because this touches shared build targets and item removal ordering.
CI Status
- Required-check result:
gh pr checks --requiredunavailable becauseghis unauthenticated in this environment. - Classification: Undetermined from local tools; public PR metadata indicates unstable/required failures, and prior public comments suggest likely infrastructure failures.
- Action taken: Confidence capped low; no LGTM while required CI is undetermined/red.
Findings
No ❌ Error or
The delegated maui-expert-reviewer returned no concrete inline findings:
[]Failure-Mode Probing
- If
MauiPlatformSpecificFolder Include="Platforms\Apple"omits the slash:EnsureTrailingSlashprevents matchingPlatforms\AppleX; regression is covered by the SingleProject tests. - If
TargetPlatformIdentifierscontains spaces/tabs/newlines: whitespace is stripped with regex before matching; tab cases are covered by the SingleProject tests. - If
TargetPlatformIdentifieris empty: non-empty platform lists do not match, while empty condition-gated folders still participate. - If built-in singular metadata is used: normalization back-fills plural metadata before collect/remove.
Verdict: NEEDS_DISCUSSION
Confidence: low
Summary: Code review found no current blocking implementation issues, and prior major findings appear fixed. Required CI could not be authenticated/fully classified locally, so confidence remains low.
Fix — Analysis & Comparison
Fix Candidates
| # | Source | Approach | Test Result | Files Changed | Notes |
|---|---|---|---|---|---|
| 1 | maui-expert-reviewer | Metadata-first inclusion: update matching Compile items to ExcludeFromCurrentConfiguration=false before original removal |
❌ FAIL | 1 file | Original broad glob removal still removed/kept wrong files; 17/23 focused tests failed |
| 2 | maui-expert-reviewer | Actual-Compile-Item Removal: mark existing @(Compile) platform items and remove only actual items still excluded |
❌ FAIL | 2 files | First iteration hit MSB4092; syntax-fixed iteration still leaked platform files; 17/23 focused tests failed |
| 3 | maui-expert-reviewer | Remove then reinclude matching folders after collecting active MauiPlatformSpecificFolder globs |
❌ FAIL | 2 files | Inactive platform files still leaked; final remove-all-then-reinclude iteration failed |
| PR | PR #35045 | Normalize folder metadata, collect keep-list, exclude keep-list from removal, unflip kept metadata | ✅ PASSED (Gate) | 3 files | Original PR; remains best validated fix |
Cross-Pollination
| Model | Round | New Ideas? | Details |
|---|---|---|---|
| maui-expert-reviewer | 1 | Yes | Metadata-first inclusion; failed because the original glob removal remained too broad |
| maui-expert-reviewer | 2 | Yes | Actual @(Compile) item removal; failed because item classification/removal timing still leaked files |
| maui-expert-reviewer | 3 | Yes | Snapshot/remove/reinclude strategy; failed and became riskier than PR due reinclude metadata/order concerns |
Exhausted: Yes
Selected Fix: PR #35045 — all meaningfully different alternatives tested here failed the focused SingleProject regression tests, while the PR fix already passed the gate. The failures consistently point back to the PR's design choice as the robust approach: compute the active keep-list before removal and exclude it in the same removal operation, with post-removal metadata correction for IDE/design-time behavior.
Report — Final Recommendation
Comparative Report — PR #35045
Candidates compared
| Rank | Candidate | Result | Summary |
|---|---|---|---|
| 1 | pr |
✅ Gate passed | Normalizes platform-folder metadata, computes a matching keep-list before removal, excludes kept files from the Platforms/** removal, and unflips kept compile metadata afterward. This is the only independently validated passing implementation. |
| 1 | pr-plus-reviewer |
✅ Equivalent to pr |
Expert review found no actionable inline findings, so this candidate has no changes beyond the raw PR fix. It is tied functionally with pr, but does not supersede it because there is no reviewer patch. |
| 3 | try-fix-1 |
❌ Failed regression tests | Metadata-first inclusion updated matching compile items but left the broad glob removal in place, so kept files were still removed and 17/23 focused tests failed. |
| 4 | try-fix-2 |
❌ Failed regression tests | Actual-Compile-Item removal attempted to classify existing compile items, but the first iteration hit MSB4092 and the syntax-fixed iteration still leaked platform files; 17/23 focused tests failed. |
| 5 | try-fix-3 |
❌ Failed regression tests | Remove-then-reinclude still leaked inactive platform files, including condition-gated/non-platform cases, and moved toward a riskier version of the PR's keep-list design. |
Analysis
The passing/failing split is decisive. The orchestrator gate shows the PR fix catches the original bug and passes with the fix, while all three STEP 5a alternatives failed the focused SingleProject regression tests. Per ranking rule, candidates that failed regression tests are ranked below candidates that passed.
The expert review did not identify any correctness issue to apply on top of the PR, so pr-plus-reviewer is not materially different from pr. The raw PR remains the best candidate because it is the minimal passing implementation and already incorporates the important design property that the failed alternatives converged back toward: compute active custom/shared platform-folder files before the blanket removal and exclude them during that same removal.
Winner
pr wins. It is the only non-failing implementation with a real behavioral delta, it passed the supplied gate, and the expert reviewer found no actionable change needed.
Future Action — review latest findings
No alternative fix was selected for this run. Review the session findings and CI results before merging.
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
|
/review tests |
Tests Failure Analysis
Test Failure Review: Likely unrelated - click to expandOverall verdict: Likely unrelated All 5 recent
Recommended actionNo action needed from this PR. The device test failures are pre-existing on Evidence detailsBuild 1463001 (
Base-branch comparison (
PR scope (3 changed files):
Limitations: No AzDO authentication token was available; Helix work-item console logs returned 404 and could not be inspected for specific test names. Device-test hidden failures beyond those logged in AzDO build logs could not be fully verified. |
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! ## Description of Change This updates SingleProject compile filtering so `MauiPlatformSpecificFolder` can participate in the existing `Platforms/*` pipeline for shared and custom folder mappings. Highlights: - add plural `TargetPlatformIdentifiers` metadata while keeping the singular metadata path backward compatible - preserve the existing `ExcludeFromCurrentConfiguration` / `_MauiRemovePlatformCompileItems` flow and its design-time behavior - support shared folders such as `Platforms/Apple/` for `ios;maccatalyst` - support extending built-in folder mappings and condition-gated non-TPI folders - add focused MSBuild unit coverage for the new behavior and compatibility path ## Issues Fixed Fixes #35042 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Note
Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!
Description of Change
This updates SingleProject compile filtering so
MauiPlatformSpecificFoldercan participate in the existingPlatforms/*pipeline for shared and custom folder mappings.Highlights:
TargetPlatformIdentifiersmetadata while keeping the singular metadata path backward compatibleExcludeFromCurrentConfiguration/_MauiRemovePlatformCompileItemsflow and its design-time behaviorPlatforms/Apple/forios;maccatalystIssues Fixed
Fixes #35042