Skip to content

Commit b88cb03

Browse files
authored
Updates
1 parent 666eb37 commit b88cb03

File tree

1 file changed

+27
-64
lines changed
  • aspnetcore/blazor/tutorials/movie-database-app

1 file changed

+27
-64
lines changed

aspnetcore/blazor/tutorials/movie-database-app/part-2.md

Lines changed: 27 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ dotnet add package Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore
163163
> </PackageReference>
164164
> ```
165165
>
166-
> The preceding update to the package reference is a workaround for a breaking change in .NET 9 EF Core tooling. The change to the package reference can be reverted in apps that are eventually updated to .NET 10 or later. For more information, see [Breaking changes in EF Core 9 (EF9)](/ef/core/what-is-new/ef-core-9.0/breaking-changes#microsoftentityframeworkcoredesign-not-found-when-using-ef-tools).
166+
> The preceding update to the package reference is a workaround for a breaking change in .NET 9 EF Core tooling. The entire package reference can be removed in apps that are eventually updated to .NET 10 or later. For more information, see [Breaking changes in EF Core 9 (EF9)](/ef/core/what-is-new/ef-core-9.0/breaking-changes#microsoftentityframeworkcoredesign-not-found-when-using-ef-tools).
167167
168168
:::moniker-end
169169
@@ -197,73 +197,36 @@ Paste all of the following commands at the prompt (`>`) of the command shell. W
197197
198198
When you paste multiple commands, all of the commands execute except the last one. The last command doesn't execute until you press <kbd>Enter</kbd> on the keyboard.
199199
200-
:::moniker range=">= aspnetcore-10.0"
201-
202-
```dotnetcli
203-
dotnet tool install --global dotnet-aspnet-codegenerator
204-
dotnet tool install --global dotnet-ef
205-
dotnet add package Microsoft.EntityFrameworkCore.SQLite
206-
dotnet add package Microsoft.VisualStudio.Web.CodeGeneration.Design
207-
dotnet add package Microsoft.EntityFrameworkCore.SqlServer
208-
dotnet add package Microsoft.EntityFrameworkCore.Tools
209-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid
210-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid.EntityFrameworkAdapter
211-
dotnet add package Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore
212-
```
213-
214-
> [!IMPORTANT]
215-
> After the first eight commands execute, make sure that you press <kbd>Enter</kbd> on the keyboard to execute the last command.
216-
217-
:::moniker-end
218-
219200
:::moniker range=">= aspnetcore-9.0 < aspnetcore-10.0"
220201
221-
```dotnetcli
222-
dotnet tool install --global dotnet-aspnet-codegenerator
223-
dotnet tool install --global dotnet-ef
224-
dotnet add package Microsoft.EntityFrameworkCore.SQLite
225-
dotnet add package Microsoft.VisualStudio.Web.CodeGeneration.Design
226-
dotnet add package Microsoft.EntityFrameworkCore.SqlServer
227-
dotnet add package Microsoft.EntityFrameworkCore.Tools
228-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid
229-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid.EntityFrameworkAdapter
230-
dotnet add package Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore
231-
dotnet add package Microsoft.EntityFrameworkCore.Design
232-
```
233-
234-
> [!IMPORTANT]
235-
> After the first nine commands execute, make sure that you press <kbd>Enter</kbd> on the keyboard to execute the last command.
236-
237-
Open the app's project file (`BlazorWebAppMovies.csproj`). Mark the `Microsoft.EntityFrameworkCore.Design` assembly reference as publishable by adding `<Publish>true</Publish>` to the package reference. In the following example, the `{VERSION}` placeholder is the package's version and remains unchanged:
238-
239-
```diff
240-
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="{VERSION}">
241-
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
242-
<PrivateAssets>all</PrivateAssets>
243-
+ <Publish>true</Publish>
244-
</PackageReference>
245-
```
246-
247-
The preceding update to the package reference is a workaround for a breaking change in .NET 9 EF Core tooling. The change to the package reference can be reverted in apps that are eventually updated to .NET 10 or later. For more information, see [Breaking changes in EF Core 9 (EF9)](/ef/core/what-is-new/ef-core-9.0/breaking-changes#microsoftentityframeworkcoredesign-not-found-when-using-ef-tools).
248-
249-
:::moniker-end
250-
251-
:::moniker range="< aspnetcore-9.0"
252-
253-
```dotnetcli
254-
dotnet tool install --global dotnet-aspnet-codegenerator
255-
dotnet tool install --global dotnet-ef
256-
dotnet add package Microsoft.EntityFrameworkCore.SQLite
257-
dotnet add package Microsoft.VisualStudio.Web.CodeGeneration.Design
258-
dotnet add package Microsoft.EntityFrameworkCore.SqlServer
259-
dotnet add package Microsoft.EntityFrameworkCore.Tools
260-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid
261-
dotnet add package Microsoft.AspNetCore.Components.QuickGrid.EntityFrameworkAdapter
262-
dotnet add package Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore
263-
```
202+
<!-- UPDATE 10.0 - Update the first bullet. -->
264203
265204
> [!IMPORTANT]
266-
> After the first eight commands execute, make sure that you press <kbd>Enter</kbd> on the keyboard to execute the last command.
205+
> If using the .NET 9 SDK, a breaking change in EF Core tooling prevents scaffolding from executing with the following exception:
206+
>
207+
> > :::no-loc text="Could not load file or assembly 'Microsoft.EntityFrameworkCore.Design, Version=9.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find the file specified.":::
208+
>
209+
> Adopt ***either*** of the following approaches:
210+
>
211+
> * Use a .NET SDK for [.NET 10](https://dotnet.microsoft.com/download/dotnet/10.0) or later. .NET 10 is currently in preview and is secheduled for release in November, 2025. If you obtain and use the .NET 10 SDK for this tutorial, you can leave the app targeting .NET 9.
212+
>
213+
> * Add a package reference to the app for the [`Microsoft.EntityFrameworkCore.Design`](https://www.nuget.org/packages/Microsoft.EntityFrameworkCore.Design) NuGet package:
214+
>
215+
> ```dotnetcli
216+
> dotnet add package Microsoft.EntityFrameworkCore.Design
217+
> ```
218+
>
219+
> Open the app's project file (`BlazorWebAppMovies.csproj`). Mark the `Microsoft.EntityFrameworkCore.Design` assembly reference as publishable by adding `<Publish>true</Publish>` to the package reference. In the following example, the `{VERSION}` placeholder is the package's version and remains unchanged:
220+
>
221+
> ```diff
222+
> <PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="{VERSION}">
223+
> <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
224+
> <PrivateAssets>all</PrivateAssets>
225+
> + <Publish>true</Publish>
226+
> </PackageReference>
227+
> ```
228+
>
229+
> The preceding update to the package reference is a workaround for a breaking change in .NET 9 EF Core tooling. The entire package reference can be removed in apps that are eventually updated to .NET 10 or later. For more information, see [Breaking changes in EF Core 9 (EF9)](/ef/core/what-is-new/ef-core-9.0/breaking-changes#microsoftentityframeworkcoredesign-not-found-when-using-ef-tools).
267230
268231
:::moniker-end
269232

0 commit comments

Comments
 (0)