Skip to content

Resolve dotnet-ef tool path from package contents - #69905

Merged
wtgodbe merged 1 commit into
dotnet:mainfrom
wtgodbe:wtgodbe/fix-template-dotnet-ef-path
Oct 16, 2026
Merged

wtgodbe merged 1 commit into
dotnet:mainfrom
wtgodbe:wtgodbe/fix-template-dotnet-ef-path

Conversation

@wtgodbe

@wtgodbe wtgodbe commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Resolve dotnet-ef tool path from package contents

Impact: Restores 28 template tests that failed before execution because the test infrastructure pointed at a nonexistent tools/net12.0/any/dotnet-ef.dll.

Resolve dotnet-ef from the restored package layout

Description

Finds the single tools/*/any/dotnet-ef.dll supplied by the restored dotnet-ef package instead of deriving the tool host target framework from the product target framework. The target now reports an explicit error if the package contains zero or multiple matching tool assemblies.

The failing package version, 12.0.0-alpha.1.26473.114, contains tools/net10.0/any/dotnet-ef.dll; the previous net12.0 path does not exist.

Validation:

  • source activate.sh && dotnet build src/ProjectTemplates/test/Templates.Tests/Templates.Tests.csproj -v:minimal — passed after preparing the documented template-test prerequisites.
  • Evaluating PrepareForTest against dotnet-ef 12.0.0-alpha.1.26473.114 resolved DotNetEfFullPath to the existing tools/net10.0/any/dotnet-ef.dll.
  • source activate.sh && dotnet test src/ProjectTemplates/test/Templates.Tests/Templates.Tests.csproj --no-build --no-restore --filter "FullyQualifiedName~IdentityUIPackage_WorksWithDifferentOptions" — reached generated-project restore, then was blocked by the incomplete local ASP.NET Core and EF package graph (NU1102); it did not fail on the dotnet-ef path.

Related to internal CI build 3107295; no public issue.

Copilot AI balanced review requested due to automatic review settings October 16, 2026 21:57
@github-actions github-actions Bot added the area-commandlinetools Includes: Command line tools, dotnet-dev-certs, dotnet-user-jwts, and OpenAPI label Oct 16, 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

Required review evidence was unavailable, and end-to-end template-test validation remains incomplete.

No open issues 🎉

What changed in this PR

Resolves the template tests’ dotnet-ef path from restored package contents instead of assuming a target framework.

Changes:

  • Discovers tools/*/any/dotnet-ef.dll during test preparation.
  • Reports explicit errors when zero or multiple assemblies match.
File Description
src/​ProjectTemplates/​TestInfrastructure/​PrepareForTest.targets Discovers and validates the tool path before emitting assembly metadata.

Review effort: Balanced

@wtgodbe
wtgodbe merged commit 8fd1ce3 into dotnet:main Oct 16, 2026
30 checks passed
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:24 — with GitHub Actions Inactive
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:25 — with GitHub Actions Inactive
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:25 — with GitHub Actions Inactive
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:27 — with GitHub Actions Inactive
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:28 — with GitHub Actions Inactive
@wtgodbe
wtgodbe temporarily deployed to copilot-pat-pool October 16, 2026 23:29 — with GitHub Actions Inactive
@github-actions

Copy link
Copy Markdown
Contributor

✅ No documentation PR was created.

Confidence that documentation is needed: 2%

No docs needed: the PR fixes dotnet-ef path resolution in template test infrastructure only.

Documentation surfaces considered

  • Conceptual article: Not required — Only test infrastructure targets changed; no public behavior.
  • Migration guidance: Not required — No upgrade action for users.
  • Breaking change: Not required — No compatibility impact.

This branch was previously deployed

1 inactive deployment
copilot-pat-pool — e4d6fdc5 Deployed Oct 16, 2026 by wtgodbe via conclusion #63
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-commandlinetools Includes: Command line tools, dotnet-dev-certs, dotnet-user-jwts, and OpenAPI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants