Open Closed

Unable to generate Angular UI from ABP Suite #9791


User avatar
0
AlderCove created
  • Template: app
  • Created ABP Studio Version: 1.2.1
  • Current ABP Studio Version: 1.2.1
  • Tiered: Yes
  • Multi-Tenancy: No
  • UI Framework: angular
  • Theme: leptonx
  • Theme Style: system
  • Theme Menu Placement: side
  • Run Install Libs: Yes
  • Progressive Web App: No
  • Run Progressive Web App Support: No
  • Database Provider: ef
  • Database Management System: sqlserver
  • Separate Tenant Schema: No
  • Create Initial Migration: Yes
  • Run Db Migrator: Yes
  • Mobile Framework: none
  • Public Website: No
  • Social Login: No
  • Include Tests: No
  • Kubernetes Configuration: No
  • Distributed Event Bus: none
  • Use Local References: No
  • Optional Modules:
    • GDPR
    • TextTemplateManagement
    • LanguageManagement
    • AuditLogging
    • OpenIddictAdmin
  • Selected Languages: English, English (United Kingdom), Chinese (Simplified), Spanish, Arabic, Hindi , Portuguese (Brazil), French, Russian, German (Germany), Turkish, Italian, Czech, Hungarian, Romanian (Romania), Swedish, Finnish, Slovak, Icelandic, Chinese (Traditional)
  • Default Language: English
  • Create Command: abp new Acs.Cts.SecureMessaging -t app --tiered --ui-framework angular --database-provider ef --database-management-system sqlserver --theme leptonx --no-tests --without-cms-kit --dont-run-bundling --no-multi-tenancy --no-social-logins -no-saas -no-file-management

ExecaError: Command failed with exit code 1: .suite/schematics/node_modules/.bin/ng g "/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/collection.json:entity" --template module-pro --target Acs.Cts.SecureMessaging --source "C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/.suite/entities/MessagingAccessDelegation.json"

More than one module matches. Use the '--skip-import' option to skip importing the component into the closest module or use the module option to specify a module. at getFinalError (file:///C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/node_modules/execa/lib/return/final-error.js:6:9) at makeError (file:///C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/node_modules/execa/lib/return/result.js:108:16) at getAsyncResult (file:///C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/node_modules/execa/lib/methods/main-async.js:168:4) at handlePromise (file:///C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/node_modules/execa/lib/methods/main-async.js:151:17) at async file:///C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/run-schematics.mjs:13:20 { shortMessage: 'Command failed with exit code 1: .suite/schematics/node_modules/.bin/ng g "/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/collection.json:entity" --template module-pro --target Acs.Cts.SecureMessaging --source "C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/.suite/entities/MessagingAccessDelegation.json"', command: '.suite/schematics/node_modules/.bin/ng g /Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/collection.json:entity --template module-pro --target Acs.Cts.SecureMessaging --source C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/.suite/entities/MessagingAccessDelegation.json', escapedCommand: '.suite/schematics/node_modules/.bin/ng g "/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/angular/.suite/schematics/collection.json:entity" --template module-pro --target Acs.Cts.SecureMessaging --source "C:/Users/Jamie/Repo/Acs/modules/Acs.Cts.SecureMessaging/.suite/entities/MessagingAccessDelegation.json"', cwd: 'C:\Users\Jamie\Repo\Acs\modules\Acs.Cts.SecureMessaging\angular', durationMs: 3457.2956, failed: true, timedOut: false, isCanceled: false, isGracefullyCanceled: false, isTerminated: false, isMaxBuffer: false, isForcefullyTerminated: false, exitCode: 1, stdout: '', stderr: "\x1B[1m\x1B[31mMore than one module matches. Use the '--skip-import' option to skip importing the component into the closest module or use the module option to specify a module.\x1B[39m\x1B[22m", stdio: [ undefined, '', "\x1B[1m\x1B[31mMore than one module matches. Use the '--skip-import' option to skip importing the component into the closest module or use the module option to specify a module.\x1B[39m\x1B[22m" ], ipcOutput: [], pipedFrom: [] }

Node.js v22.16.0

2025-08-20 10:35:09.875 -07:00 [INF] 2/2 - AngularUiGenerateWithSchematicsCommand completed. | Duration: 4107 ms.

  • Steps to reproduce the issue:

Scaffold an existing or new entity in ABP Suite and nothing is generated - abp suite log error found (see above).


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

    The error message:

    More than one module matches. Use the '--skip-import' option to skip importing the component into the closest module or use the module option to specify a module.
    

    indicates that the Angular schematics used by ABP Suite cannot determine which Angular module to import the generated component into, because multiple modules match the criteria.

    Solution

    1. Specify the Module Explicitly
      • In your Angular project, locate the .module.ts file where you want the generated component to be imported (e.g., app.module.ts or a feature module).
      • When running the schematic (or when configuring the entity in ABP Suite), use the --module option to specify the exact module file path. For example:
    --module=src/app/your-feature/your-feature.module.ts
    
    • If you are using ABP Suite's UI, ensure that your project structure does not have multiple modules with similar names in the same directory, or manually edit the generated command to include the --module option.
    1. Clean Up Duplicate Modules

      • Check your Angular project for multiple modules that could match the import path. Remove or rename unnecessary modules to avoid ambiguity.
    2. Workaround: Use --skip-import

      • If you do not want the component to be imported automatically, you can use the --skip-import option. You will then need to manually import the generated component into the desired module.
    3. Regenerate After Fix

      • After specifying the module or cleaning up duplicates, rerun the entity generation in ABP Suite.

    Reference

    This is a known issue with Angular schematics when multiple modules match. See the following for more details and workarounds:


    By specifying the module explicitly or cleaning up your module structure, you should be able to resolve the error and generate Angular UI code from ABP Suite.


    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
    AlderCove created

    I had 2 .module.ts files in one folder - moved one and it resolved the issue

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Thanks @AlderCove

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 01, 2025, 08:37