GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — ci: report code coverage on pull requests by ReubenBond · Pull Request #10733 · dotnet/orleans

Conversation

@ReubenBond

@ReubenBond ReubenBond commented Aug 21, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Pull requests currently publish test outcomes but do not expose code coverage after the Microsoft.Testing.Platform migration.

This change enables native MTP dynamic coverage in the existing Linux/.NET 10 BVT, SlowBVT, and Functional test matrix cells, so coverage is collected during the original test executions. Those jobs upload compact binary coverage data separately from TRX results, and a post-test job uses Microsoft's dotnet-coverage tool to merge every module and suite into one deduplicated Cobertura report.

The trusted default-branch workflow_run summarizes that single report into a Code Coverage check, the job summary, and one marker-tagged PR comment which is updated on every successful run. The comment keeps the percentage and covered-line count visible, with source counts, scope, commit, workflow, and artifact links in collapsed details.

Coverage is limited to maintained repository source under src/, excluding test and build-output sources. The split keeps fork pull requests on read-only permissions while the reporter uses the default branch implementation and parses one bounded static XML artifact before writing results.

Microsoft Reviewers: Open in CodeFlow

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Copilot AI lite review requested due to automatic review settings August 21, 2026 06:57
Copilot started reviewing on behalf of ReubenBond August 21, 2026 06:58
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Pull request overview

This PR restores PR-visible code coverage reporting after the Microsoft.Testing.Platform migration by collecting Cobertura coverage artifacts in PR CI runs and aggregating them in a trusted workflow_run reporter which publishes a “Code Coverage” check and job summary.

Changes:

  • Add the MTP Code Coverage extension package to Orleans test applications (net10.0 only) and centrally manage its version.
  • Collect and upload Cobertura (*.cobertura.xml) artifacts from the Linux/.NET 10 BVT/SlowBVT/Functional CI matrix on pull requests.
  • Add a trusted workflow_run job which downloads coverage artifacts, summarizes repository src/ line coverage, and publishes a “Code Coverage” check.
Show a summary per file
File Description
test/Directory.Build.props Adds Microsoft.Testing.Extensions.CodeCoverage to test apps for net10.0.
Directory.Packages.props Introduces a central version pin for the Code Coverage extension.
.github/workflows/ci.yml Enables coverage collection on PR Linux/net10 test runs and uploads suite-scoped coverage artifacts.
.github/workflows/test-results.yml Adds a workflow_run coverage reporter which summarizes artifacts and publishes a check run.
.github/scripts/summarize-coverage.py New script to parse Cobertura XML, aggregate line coverage, and emit JSON/Markdown summaries.
.github/coverage.config.xml Adds MTP code coverage configuration for static instrumentation and exclusions.

Review details

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 6/6 changed files
  • Comments generated: 1
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/workflows/ci.yml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 07:13
Copilot started reviewing on behalf of ReubenBond August 21, 2026 07:14
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

  • Files reviewed: 6/6 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@ReubenBond

ReubenBond commented Aug 21, 2026

Copy link
Copy Markdown
Member Author

The current Ubuntu/net10 coverage jobs fail because a filtered test module with zero selected tests times out in MTP's TRX process-lifetime handler after coverage is enabled. The module aborts with exit 134 (System.TimeoutException in TrxProcessLifetimeHandler), so the aggregate run reports an infrastructure error despite 0 failed tests. This occurs in BVT, SlowBVT, and Functional coverage jobs. Please adjust the coverage invocation/project selection so zero-selection modules complete cleanly without masking real failures.\n\nExample job: https://github.com/dotnet/orleans/actions/runs/32457710648/job/96698103245

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 11:44
Copilot started reviewing on behalf of ReubenBond August 21, 2026 11:45
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

Suppressed comments (1)

.github/workflows/ci.yml:1100

  • This condition skips uploading the test_output_* artifact for pull_request runs on ubuntu-latest/net10.0. With the new coverage collection happening specifically in that matrix slice, skipping the artifact prevents test-results.yml from reporting those suite outcomes (it only reads test_output_* artifacts). If coverage and test outcomes are both desired, upload test results unconditionally and keep excluding **/*.cobertura.xml to avoid duplication.
    - name: Archive Test Results
      if: always() && (github.event_name != 'pull_request' || matrix.os != 'ubuntu-latest' || matrix.framework != 'net10.0')
      continue-on-error: true
  • Files reviewed: 6/6 changed files
  • Comments generated: 1
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/workflows/ci.yml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 11:59
Copilot started reviewing on behalf of ReubenBond August 21, 2026 12:00
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

Suppressed comments (1)

Previously missed (1) — in code that hasn't changed since the last review.

.github/workflows/test-results.yml:56

  • This step invokes python, which is not guaranteed to exist as an alias on all ubuntu-latest images (some only provide python3). Using python3 makes the workflow more robust without changing behavior.
          python .github/scripts/summarize-coverage.py coverage \
  • Files reviewed: 6/6 changed files
  • Comments generated: 1
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/scripts/summarize-coverage.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 12:13
Copilot started reviewing on behalf of ReubenBond August 21, 2026 12:13
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

Suppressed comments (2)

Previously missed (2) — in code that hasn't changed since the last review.

.github/workflows/ci.yml:1123

  • The coverage job builds the repo with a plain dotnet build and then runs dotnet test --no-build --framework net10.0. Since test projects target net8.0;net10.0 by default (see test/Directory.Build.props:19), this build step will typically build both TFMs even though the job only runs the net10.0 tests, increasing job time. Consider dropping the explicit build step and letting dotnet test --framework net10.0 build only the required net10.0 graph.
    - name: Build
      run: dotnet build
    - name: Collect coverage
      run: dotnet test
        --no-build

.github/scripts/summarize-coverage.py:36

  • get_repository_path accepts filenames which start with the source_root prefix (or /_/src/) but does not reject ../. path segments. A crafted Cobertura report could therefore escape src/ (e.g. .../src/../.github/...) and skew the coverage calculation even though the summary claims it only measures files under src/. Consider rejecting filenames which contain ./.. segments after the prefix is stripped.
    if normalized.casefold().startswith(source_prefix.casefold()):
        return f"src/{normalized[len(source_prefix):]}"

    if normalized.startswith(DETERMINISTIC_SOURCE_PREFIX):
        return f"src/{normalized[len(DETERMINISTIC_SOURCE_PREFIX):]}"
  • Files reviewed: 7/7 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Copilot AI review requested due to automatic review settings August 21, 2026 13:16
Copilot started reviewing on behalf of ReubenBond August 21, 2026 13:16
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

  • Files reviewed: 9/9 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Copilot AI review requested due to automatic review settings August 21, 2026 14:57
@ReubenBond
ReubenBond force-pushed the rb-ci-pr-coverage-reporting branch from 4bf3682 to 445b1c4 Compare August 21, 2026 14:57
Copilot started reviewing on behalf of ReubenBond August 21, 2026 14:57
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

  • Files reviewed: 9/9 changed files
  • Comments generated: 3
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/scripts/summarize-coverage.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread .github/scripts/test_summarize_coverage.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread .github/workflows/test-results.yml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 15:19
@ReubenBond
ReubenBond force-pushed the rb-ci-pr-coverage-reporting branch from 445b1c4 to 87b4fdd Compare August 21, 2026 15:19
Copilot started reviewing on behalf of ReubenBond August 21, 2026 15:20
View session
Copilot AI reviewed Aug 21, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Review details

Suppressed comments (1)

.github/workflows/test-results.yml:73

  • A Python unit test file (.github/scripts/test_summarize_coverage.py) was added, but this workflow job doesn't run it. Since this job runs the summarizer on trusted default-branch code, executing the unit tests here would help catch XML parsing/path-handling regressions early.
      - name: Summarize coverage
        id: coverage
        run: |
          python .github/scripts/summarize-coverage.py coverage \
           --source-root "$GITHUB_WORKSPACE/src" \
           --markdown-output coverage-summary.md \
           --json-output coverage-summary.json
          cat coverage-summary.md >> "$GITHUB_STEP_SUMMARY"
          echo "line-rate=$(jq -r .line_rate_display coverage-summary.json)" >> "$GITHUB_OUTPUT"
  • Files reviewed: 7/7 changed files
  • Comments generated: 2
  • Review effort level: Lite

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/scripts/summarize-coverage.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread .github/workflows/ci.yml Resolved

Uh oh!

There was an error while loading. Please reload this page.

Copilot AI review requested due to automatic review settings August 21, 2026 15:26
Copilot started reviewing on behalf of ReubenBond August 21, 2026 15:26
View session
@ReubenBond
ReubenBond force-pushed the rb-ci-pr-coverage-reporting branch from 98c3154 to 70fa7f5 Compare August 21, 2026 15:27
This was referenced Sep 8, 2026
Bump the dotnet group with 5 updates dotnet/docs#55911
Merged
Bump the dotnet group with 4 updates IvanMarkitan/dotnet-docs#838
Closed
Bump the dotnet group with 6 updates IvanMarkitan/dotnet-docs#839
Closed
Bump the dotnet group with 7 updates IvanMarkitan/dotnet-docs#840
Closed
Bump Microsoft.Orleans.Sdk and Microsoft.Orleans.Server IvanMarkitan/dotnet-docs#843
Open
Bump Microsoft.Orleans.Clustering.Redis and 4 others IvanMarkitan/dotnet-docs#845
Closed
Bump the dotnet group with 7 updates IvanMarkitan/dotnet-docs#846
Open
Bump the dotnet group with 5 updates BillWagner/docs#9804
Closed
Bump the dotnet group with 4 updates BillWagner/docs#9805
Closed
Bump the dotnet group with 4 updates BillWagner/docs#9806
Closed
Bump the dotnet group with 5 updates BillWagner/docs#9807
Closed
Bump the dotnet group with 7 updates zbalkan/docs#2339
Closed
Bump the dotnet group with 5 updates zbalkan/docs#2340
Closed
Bump the dotnet group with 6 updates zbalkan/docs#2341
Closed
Bump the dotnet group with 10 updates zbalkan/docs#2347
Open
chore(deps): Bump the nuget-patch-and-minor group with 25 updates petesramek/microservices-vs-virtual-actors#9
Closed
chore(deps): Bump Meziantou.Analyzer and 12 others petesramek/microservices-vs-virtual-actors#10
Closed
chore: Bump ManagedCode.Orleans.RateLimiting.Server and 4 others managedcode/Communication#160
Closed
This was referenced Sep 16, 2026
Bump the dotnet group with 4 updates IvanMarkitan/dotnet-docs#869
Open
Bump the dotnet group with 6 updates IvanMarkitan/dotnet-docs#870
Open
Bump the dotnet group with 7 updates IvanMarkitan/dotnet-docs#877
Open
Bump the dotnet group with 7 updates zbalkan/docs#2373
Open
Bump the dotnet group with 5 updates zbalkan/docs#2377
Open
Bump the dotnet group with 6 updates zbalkan/docs#2393
Open
Bump Microsoft.Orleans.Reminders and Microsoft.Orleans.Sdk en-gen/Wayfinder#266
Open
Bump Microsoft.Orleans.Reminders from 10.2.2 to 10.3.1 en-gen/Wayfinder#267
Closed
Bump Microsoft.Orleans.Reminders and Microsoft.Orleans.Reminders.AzureStorage en-gen/Wayfinder#268
Open
chore: Bump the orleans group with 2 updates pathosDev/actor-ts#1607
Closed
chore: Bump the minor-and-patch group with 3 updates pathosDev/actor-ts#1608
Merged
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 21, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

Copilot code review Copilot
Copilot review effort
Applies to this pull request for everyone.Learn more about Copilot code review.
Copilot left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@ReubenBond
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.