Skip to content

[ci-fix-net11] Needs review: avoid empty interpreter version evaluation (refs #39223) - #39242

Merged
kubaflo merged 1 commit into
net11.0from
ci-fix/issue-39223-0dbe182972edffbb
Oct 8, 2026
Merged

kubaflo merged 1 commit into
net11.0from
ci-fix/issue-39223-0dbe182972edffbb

Conversation

@github-actions

@github-actions github-actions Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection results could not be parsed.

Review the workflow run logs for details.

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!

Workflow artifact: ci-fix
Artifact kind: help
Refs: #39223
Target branch: net11.0
Attempt: 1/10

Attempt 1 of 10

Derive the interpreter version check from the target framework and evaluate it only for Apple target frameworks.

Previous attempts (prior commits on this PR)

None; this is the first attempt for this tracking issue.

This attempt differs by: correcting the evaluation inputs and condition ordering, rather than reverting the .NET 11 interpreter policy or merely suppressing evaluation when an SDK property is missing.

Root cause

src/Controls/src/Build.Tasks/nuget/buildTransitive/netstandard2.0/Microsoft.Maui.Controls.Common.targets is copied into .buildtasks and imported by consumers. Its Debug interpreter condition calls VersionLessThan on TargetFrameworkVersion before checking the platform. That property can still be empty during import, including cross-targeting evaluation.

The latest completed maui-pr build, 1626245, fails on both Windows and macOS with MSB4184 evaluating VersionLessThan('', 11.0). The condition was introduced by #39032. Importing the unchanged target into an SDK-free MSBuild project reproduces the same diagnostic locally.

Fix

Check for iOS or Mac Catalyst before performing the version comparison, and obtain the framework version directly from TargetFramework with MSBuild's GetTargetFrameworkVersion.

This preserves automatic interpreter selection for pre-.NET 11 Apple Debug targets, leaves .NET 11 Apple targets unchanged, preserves explicit UseInterpreter values, and leaves the existing Android/Windows/Tizen Mono condition untouched. Empty outer-build target frameworks do not enter the Apple version comparison.

No test, assertion, timeout, exclusion, analyzer setting, or public API is changed.

What is unverified / where I need help

  • The affected project could not build locally because the required Arcade SDK package could not be downloaded under the runner's network restrictions. The runner has .NET 10 SDKs, not the repository's requested .NET 11 SDK.
  • Solution formatting was attempted with --no-restore but did not complete within the bounded wait and was canceled. This patch changes only an MSBuild condition, not C# formatting.
  • Please confirm the automatically queued maui-pr Windows and macOS builds clear MSB4184 and preserve the intended interpreter defaults in real SDK imports.

Validation

  • Command: pwsh /tmp/gh-aw/agent/validate-controls.ps1
  • Result: passed 19 isolated MSBuild evaluation cases against the actual changed target using the installed .NET 10 SDK. Cases cover empty outer-build TFM, .NET 9/10/11 Apple TFMs (including platform versions), non-Apple TFMs, Mono defaults, Release configuration, explicit interpreter values, and populated or empty TargetFrameworkVersion.
  • Baseline command: dotnet msbuild eval-controls.proj -t:Validate -p:TargetFramework=net11.0-ios -p:ExpectedUseInterpreter= -v:minimal -nologo, from the temporary validation directory. The unchanged target fails with the original MSB4184 diagnostic.
  • Command: dotnet build src/Controls/src/Build.Tasks/Controls.Build.Tasks.csproj --no-restore -v:minimal -nologo
  • Result: not validated; blocked before compilation by Arcade SDK resolution (MSB4236).
  • Command: git diff --check
  • Result: passed.

Evidence


Filed by ci-status-fix-net11. This is the single PR for #39223: the workflow watches its own CI and pushes up to 10 attempts on this same PR (it never opens a second PR). It advances only when the fix's own build settles red and that red is caused by the fix. Comments, reviews, and commits do not transfer ownership; the loop remains autonomous until this PR is closed. Eligible CHANGES_REQUESTED reviews are handled through Track C. After 10 attempts it stops and defers to humans. The trusted CI-fix validator automatically queues maui-pr, uitests, and devicetests for every new PR head.

Warning

Firewall blocked 2 domains

The following domains were blocked by the firewall during workflow execution:

  • ajhvsblobprodcus363.vsblob.vsassets.io
  • dc.services.visualstudio.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "ajhvsblobprodcus363.vsblob.vsassets.io"
    - "dc.services.visualstudio.com"

See Network Configuration for more information.

Generated by CI Failure Fixer (net11.0) · ⊞ 29.2K · ◷

…39223, attempt 1/10)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Threat detection produced a warning for this pull request output.

These changes need to be scrutinized before merge and only merged after a careful manual review.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
There may be pipelines that require an authorized user to comment /azp run to run.

@kubaflo
kubaflo marked this pull request as ready for review October 8, 2026 10:37
Copilot AI balanced review requested due to automatic review settings October 8, 2026 10:37
@kubaflo
kubaflo merged commit 64c8ec3 into net11.0 Oct 8, 2026
27 of 36 checks passed
@kubaflo
kubaflo deleted the ci-fix/issue-39223-0dbe182972edffbb branch October 8, 2026 10:38
@github-actions github-actions Bot added this to the .NET 11.0-rc2 milestone Oct 8, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The shared target change still needs verified .NET 11 Windows and macOS build results.

0 open findings

What changed in this PR

Fixes interpreter-condition evaluation in MAUI’s shared build targets while preserving the .NET 11 Apple interpreter policy from #39032.

Changes:

  • Checks for Apple target frameworks before comparing versions.
  • Derives the framework version from TargetFramework, avoiding an empty TargetFrameworkVersion.
File Description
src/​Controls/​src/​Build.Tasks/​nuget/​buildTransitive/​netstandard2.0/​Microsoft.Maui.Controls.Common.targets Reorders the Apple condition and changes the version input.

🧠 Review effort: Balanced


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

kubaflo added a commit that referenced this pull request Nov 3, 2026
<!-- 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!

<!--
!!!!!!! MAIN IS THE ONLY ACTIVE BRANCH. MAKE SURE THIS PR IS TARGETING
MAIN. !!!!!!!
-->

### Description of Change

<!-- Enter description of the fix in this section -->

Add the first useful Build Insights migration slice to test-review
context: collect supplementary GitHub check reports for the exact
captured PR head, while retaining direct Azure/Helix acquisition and
existing attribution behavior.

- Accept only the exact `build-insights` / `Build Insights`
publisher/name pair, with matching head SHA. No legacy publisher support
or compatibility aliases.
- Reuse the existing deadline-bound `gh` transport. Bound collection to
three pages of 100 check runs, eight reports, and 65,536 combined
title/summary/text characters per report. Surface transport,
response-shape, pagination, missing-body, and truncation errors
explicitly.
- Request `filter=all` explicitly so earlier same-named reports are
considered within the existing caps, rather than silently accepting the
check-runs API's latest-only default.
- Collect supplementary reports only after primary Azure/Helix evidence,
target-branch history, and baseline attribution, using the remaining
gather budget. A stalled report request cannot consume time needed by
those sources. Both no-results shortcuts avoid report acquisition.
- Add `context.buildInsights` through `Get-BuildInsightsCheckReports`,
with report metadata, bounded raw bodies, status, timestamps, and
collection limitations. Normalize timestamps materialized by
`ConvertFrom-Json` as `DateTime` or `DateTimeOffset`.
- Teach the consumer to treat reports as untrusted supplementary leads,
not instructions, proof of coverage across all pipelines, or grounds to
dismiss failures as known issues. Pending or missing content is not
negative evidence.
- Add regression coverage and wire the review-test-failures script
directory into the existing PowerShell CI gate. Update its coupled
suite-discovery assertion to include this third skill-script directory.

This builds on earlier MAUI evidence and known-issue matcher groundwork;
it does not imply that groundwork already migrated to Build Insights.
This PR does not replace the full collector, change verdict gates, alter
raw Azure/Helix acquisition logic, or change attribution and
known-build-error matching.

**Current local verification (commit `5c6ef8dda7`):** Pester 5.9.0
across all three review-script suites plus
`.github/scripts/NotificationCenterScripts.Tests.ps1`: **368 passed, 0
failed, 0 skipped**. This includes 61 Build Insights cases. All three
new regression cases failed against the pre-fix collector at `d02e27d0`:
earlier same-named report retention, primary-before-supplementary
ordering, and a stalled supplementary request exhausting the remaining
budget. The orchestration tests execute the collector entrypoint with
mocked I/O and verify that primary evidence, history, baseline sampling,
and attribution survive. `git diff --check` passed.

**Earlier replay evidence:** Offline replay of retained October 27 check
responses preserved exact head/check/text/build links for historical
[#39242](#39242) and
[#39348](#39348),
retaining exactly one Build Insights report from each and ignoring the
legacy report. That replay is not a fresh independent service check or
deployment acceptance and was not rerun for the follow-up fixes.

**Hosted validation limitations:** No green hosted-CI claim is made for
the new commit. At the preceding head, PowerShell CI failed stale
model-pin assertions in files unchanged by this PR. Skill validation
produced no evaluation results: model probing reported `gpt-6-astra`
unavailable, and its separate harness-hermeticity job failed during
checkout. These failures have not been repaired or bypassed by this
change.

### Issues Fixed

<!-- Please make sure that there is a bug logged for the issue being
fixed. The bug should describe the problem and how to reproduce it. -->

N/A — incremental CI report-intake integration; no linked issue.

<!--
Are you targeting main? All PRs should target the main branch unless
otherwise noted.
-->

---------

Co-authored-by: Jakub Florkowski <42434498+kubaflo@users.noreply.github.com>
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 8, 2026
@github-actions github-actions Bot modified the milestones: .NET 11.0-rc2, .NET 11.0 GA Nov 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants