Open Closed

Using ABP suite generate CRUD page encountered An internal error occurred during your request - [ERR] Value cannot be null. (Parameter 'path') #9600


User avatar
0
trendline created

With Abp 9.2.1, abp suite 9.2.1

  • Exception message and full stack trace: === ENTITY GENERATION STARTED ===
  • SOLUTION: Viewtance.PointLink.AdministrationService
  • ENTITY:{ "Id": "1f31352e-9316-44e6-8d09-b4cd6812deb4", "Name": "TenantDomain", "OriginalName": "TenantDomain", "NamePlural": "TenantDomains", "DatabaseTableName": "TenantDomains", "Namespace": "TenantDomains", "Type": 1, "MasterEntityName": null, "MasterEntity": null, "BaseClass": "FullAuditedEntity", "PageTitle": "TenantDomains", "MenuIcon": "file-alt", "PrimaryKeyType": "Guid", "PreserveCustomCode": true, "IsMultiTenant": true, "CheckConcurrency": true, "BulkDeleteEnabled": true, "ShouldCreateUserInterface": true, "ShouldCreateBackend": true, "ShouldExportExcel": true, "ShouldAddMigration": false, "ShouldUpdateDatabase": false, "CreateTests": true, "Properties": [ { "Id": "8c6af49d-8a07-4d1b-9c7b-c88f7305c670", "Name": "DomainName", "Type": "string", "EnumType": "", "EnumNamespace": "", "EnumAngularImport": "shared/enums", "EnumFilePath": null, "DefaultValue": null, "IsNullable": false, "IsRequired": true, "IsFilterable": true, "AllowEmptyStrings": false, "IsTextArea": false, "MinLength": 1, "MaxLength": 128, "SortOrder": 0, "SortType": 0, "Regex": "", "EmailValidation": false, "ShowOnList": true, "ShowOnCreateModal": true, "ShowOnEditModal": true, "ReadonlyOnEditModal": false, "EnumValues": null, "IsSelected": true, "MaxFileSize": null, "OrdinalIndex": 0 }, { "Id": "66956a19-def1-49f7-9525-6b085f48121f", "Name": "DomainType", "Type": "enum", "EnumType": "DomainType", "EnumNamespace": "Viewtance.PointLink.AdministrationService.Tenants", "EnumAngularImport": "shared/enums/domain-type", "EnumFilePath": "/Viewtance.PointLink.AdministrationService.Contracts/Tenants/DomainType.cs", "DefaultValue": null, "IsNullable": false, "IsRequired": false, "IsFilterable": true, "AllowEmptyStrings": false, "IsTextArea": false, "MinLength": null, "MaxLength": null, "SortOrder": 0, "SortType": 0, "Regex": "", "EmailValidation": false, "ShowOnList": true, "ShowOnCreateModal": true, "ShowOnEditModal": true, "ReadonlyOnEditModal": false, "EnumValues": { "Console": 1, "AuthServer": 2, "Public": 3, "Mobile": 4 }, "IsSelected": true, "MaxFileSize": null, "OrdinalIndex": 0 }, { "Id": "29e4f2bc-97f2-4682-8695-ba1ffbe47316", "Name": "DomainTenantId", "Type": "Guid", "EnumType": "", "EnumNamespace": "", "EnumAngularImport": "shared/enums", "EnumFilePath": null, "DefaultValue": null, "IsNullable": false, "IsRequired": false, "IsFilterable": true, "AllowEmptyStrings": false, "IsTextArea": false, "MinLength": null, "MaxLength": null, "SortOrder": 0, "SortType": 0, "Regex": "", "EmailValidation": false, "ShowOnList": true, "ShowOnCreateModal": true, "ShowOnEditModal": true, "ReadonlyOnEditModal": false, "EnumValues": null, "IsSelected": false, "MaxFileSize": null, "OrdinalIndex": 0 } ], "NavigationProperties": [], "NavigationConnections": [], "ChildEntities": [], "PhysicalFileName": "TenantDomain.json" }

2025-07-13 04:57:07.493 +08:00 [INF] 1/10 - EntityGenerateCommand started... 2025-07-13 04:57:07.948 +08:00 [INF] 1/10 - EntityGenerateCommand completed. | Duration: 454 ms. 2025-07-13 04:57:07.948 +08:00 [INF] 2/10 - RepositoryCommand started... 2025-07-13 04:57:08.740 +08:00 [INF] 2/10 - RepositoryCommand completed. | Duration: 791 ms. 2025-07-13 04:57:08.740 +08:00 [INF] 3/10 - ManagerCommand started... 2025-07-13 04:57:08.988 +08:00 [INF] 3/10 - ManagerCommand completed. | Duration: 247 ms. 2025-07-13 04:57:08.988 +08:00 [INF] 4/10 - AppServiceCommand started... 2025-07-13 04:57:13.792 +08:00 [INF] 4/10 - AppServiceCommand completed. | Duration: 4804 ms. 2025-07-13 04:57:13.792 +08:00 [INF] 5/10 - PermissionCommand started... 2025-07-13 04:57:13.849 +08:00 [INF] 5/10 - PermissionCommand completed. | Duration: 56 ms. 2025-07-13 04:57:13.849 +08:00 [INF] 6/10 - ApplicationObjectMappingCommand started... 2025-07-13 04:57:13.878 +08:00 [ERR] ---------- RemoteServiceErrorInfo ---------- { "code": null, "message": "An internal error occurred during your request!", "details": null, "data": null, "validationErrors": null }

2025-07-13 04:57:13.879 +08:00 [ERR] Value cannot be null. (Parameter 'path') System.ArgumentNullException: Value cannot be null. (Parameter 'path') at System.ArgumentNullException.Throw(String paramName) at System.ArgumentNullException.ThrowIfNull(Object argument, String paramName) at System.ArgumentException.ThrowNullOrEmptyException(String argument, String paramName) at System.IO.File.ReadAllTextAsync(String path, CancellationToken cancellationToken) at Volo.Abp.Suite.Areas.AbpSuite.CrudPageGenerator.Commands.ApplicationObjectMappingCommand.IJBgcTmZJf() at Volo.Abp.Suite.Areas.AbpSuite.CrudPageGenerator.Commands.ApplicationObjectMappingCommand.ExecuteAsync(CrudPageCommandOptions options) at Volo.Abp.Suite.Areas.AbpSuite.CrudPageGenerator.CommandManager.ExecuteAllAsync(CrudPageCommandOptions options) at Volo.Abp.Suite.Areas.AbpSuite.CrudPageGenerator.Commands.CrudPageGenerator.GenerateAsync(EntityModel entity, Solution solution, EntityModel masterEntity, List1 navigationConnections) at Volo.Abp.Suite.Controllers.CrudPageGeneratorController.SaveAndGenerateEntityAsync(Guid solutionId, EntityModel entity) at lambda_method2003(Closure, Object) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.TaskOfActionResultExecutor.Execute(ActionContext actionContext, IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask1 actionResultValueTask) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted) at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExceptionFilterAsync>g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted) 2025-07-13 04:57:13.884 +08:00 [INF] Executing ObjectResult, writing value of type 'Volo.Abp.Http.RemoteServiceErrorResponse'. 2025-07-13 04:57:13.885 +08:00 [INF] Executed action Volo.Abp.Suite.Controllers.CrudPageGeneratorController.SaveAndGenerateEntityAsync (Volo.Abp.Suite) in 62760.4142ms 2025-07-13 04:57:13.885 +08:00 [INF] Executed endpoint 'Volo.Abp.Suite.Controllers.CrudPageGeneratorController.SaveAndGenerateEntityAsync (Volo.Abp.Suite)' 2025-07-13 04:57:13.885 +08:00 [INF] Request finished HTTP/1.1 POST http://localhost:3000/api/abpSuite/crudPageGenerator/6f93a03f-284a-4842-ae53-00aec0831ca6/save-and-generate-entity - 500 null application/json; charset=utf-8 62761.8723ms

  • Steps to reproduce the issue: Configured a Entity as below logs described, generate the CRUD page

2 Answer(s)
  • User Avatar
    0
    AI-Bot created
    Support Team ABP Agent

    This error (Value cannot be null. (Parameter 'path')) during the "ApplicationObjectMappingCommand" step in ABP Suite CRUD generation is a known issue, especially in microservice or modular solutions. It typically occurs when ABP Suite cannot find or resolve the expected file path for the Application layer's AutoMapper profile or related mapping files.

    How to Resolve

    1. Check Application Layer Structure

      • Ensure your Application project contains an AutoMapper profile (e.g., YourModuleApplicationAutoMapperProfile.cs) in the correct folder (usually under Application or Application.Contracts).
      • The file should be included in the .csproj and not excluded or missing.
    2. Verify File Paths in Suite Configuration

      • ABP Suite expects certain files to exist at standard locations. If you have moved, renamed, or deleted mapping/profile files, restore them or update their paths.
      • If you have custom folder structures, try reverting to the default ABP module layout.
    3. Check for Multiple or Missing *DbContextModelCreatingExtensions.cs Files

      • Having more than one *DbContextModelCreatingExtensions.cs file in your module can confuse Suite. Keep only one such file per module and move all configuration methods into it.
    4. Regenerate or Restore Missing Files

      • If you have deleted or renamed any of the following, restore them:
        • *ApplicationAutoMapperProfile.cs
        • *DbContextModelCreatingExtensions.cs
      • If you are missing an AutoMapper profile, create one:

    public class TenantDomainApplicationAutoMapperProfile : Profile { public TenantDomainApplicationAutoMapperProfile() { // Mapping configuration here } }

    
    5. **Remove and Re-Add Solution in Suite**
       - Remove your solution from ABP Suite and add it again to refresh its internal file path cache.
    
    6. **Check for Known Issues**
       - This is a documented problem in the ABP support portal. See the following for more details and workarounds:
         - [ABP Suite CRUD Generator: startIndex must be non-negative](https://abp.io/support/questions/9489)
    
    ### Additional Notes
    
    - If you are using a microservice module, ABP Suite may not fully support CRUD code generation for all module types.
    - If you have a custom or non-standard folder structure, try aligning it with the default ABP template.
    
    ---
    
    Sources:
    - [ABP Suite CRUD Generator: startIndex must be non-negative](https://abp.io/support/questions/9489)
    
    
    ---
    _This response was generated by AI. If it didn’t solve your problem, feel free to post a new answer — our support team will jump in to help you soon._
    
  • User Avatar
    0
    trendline created

    Powerful AI, resolved

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.0.0-preview. Updated on September 04, 2025, 16:11