Open Closed

While Migrating from 6.0.3 to 7.0.0, DbMigrator is throwing exceptions #4573


User avatar
0
Repunjay created
  • ABP Framework version: v7.0.0
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

While Migration Dotnet Core Solution ABP version from 6.0.3 to 7.0.0, as per migration guide abp is adding 2 new tables, so while running DbMigrator Project after changing the .Net framework version 7 and ABP Version to 7.0.0, I am getting below errors.

Note: Solution is upgraded to OpenIdDict.

Markdown supported.
Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)

6 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    Hi,

    Hi, you can add options.AddDataMigrationEnvironment(); to the DbMigratorHostedService like:

    https://github.com/abpframework/abp/blob/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.DbMigrator/DbMigratorHostedService.cs#L31

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    And need to check if all volo packages are upgraded to 7.0.0.

    Also run abp clean and dotnet build command

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    Repunjay created

    Hi,

    Hi, you can add options.AddDataMigrationEnvironment(); to the DbMigratorHostedService like:

    https://github.com/abpframework/abp/blob/dev/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.DbMigrator/DbMigratorHostedService.cs#L31

    After adding this line of code, DbMigrations are done, but when I ran my solution I am getting below.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    Hi.

    Can you share the error log? thanks.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    Repunjay created

    Hi.

    Can you share the error log? thanks.

    log files are not generating

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    Can you share a project that can reproduce the problem with me? shiwei.liang@volosoft.com I will check it

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on September 28, 2026, 11:44
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.