SomethingsGottaGive
SomethingsGottaGive

Reputation: 1894

Jhipster jdl error - `Valid source and destination entities are required`

I am trying to import my jdl file into my jhipster project but I am getting the following error:

$ jhipster import-jdl ./Assets/jhipster-jdl.jh --serverOnly
Using JHipster version installed globally
Executing jhipster:import-jdl ./Assets/jhipster-jdl.jh
Options: serverOnly: true, server-only: true
The JDL is being parsed.
Error: Valid source and destination entities are required.
ERROR! ERROR! Error while parsing applications and entities from the JDL Error: Valid source and destination entities are required.
Error: ERROR! Error while parsing applications and entities from the JDL Error: Valid source and destination entities are required.
    at Environment.error (/usr/local/lib/node_modules/generator-jhipster/node_modules/yeoman-environment/lib/environment.js:157:40)
    at module.exports.error (/usr/local/lib/node_modules/generator-jhipster/generators/generator-base.js:1978:18)
    at module.exports.importJDL (/usr/local/lib/node_modules/generator-jhipster/generators/import-jdl/index.js:115:14)
    at new ImporterGenerator (/usr/local/lib/node_modules/generator-jhipster/generators/import-jdl/index.js:80:38)
    at new module.exports (/usr/local/lib/node_modules/generator-jhipster/generators/import-jdl/index.js:122:9)
    at Environment.instantiate (/usr/local/lib/node_modules/generator-jhipster/node_modules/yeoman-environment/lib/environment.js:408:12)
    at Environment.create (/usr/local/lib/node_modules/generator-jhipster/node_modules/yeoman-environment/lib/environment.js:386:17)
    at Environment.run (/usr/local/lib/node_modules/generator-jhipster/node_modules/yeoman-environment/lib/environment.js:443:28)
    at runYoCommand (/usr/local/lib/node_modules/generator-jhipster/cli/cli.js:63:13)
    at Command.command.allowUnknownOption.description.action (/usr/local/lib/node_modules/generator-jhipster/cli/cli.js:83:13)

It's saying that I don't have a valid jdl file to be imported. Looking at my jdl, I can't find any syntactical errors and the error message does not give me a line. Any ideas?

Upvotes: 0

Views: 509

Answers (1)

Jon Ruddell
Jon Ruddell

Reputation: 6352

This error message is returned when one of of the entities in relationships is invalid. Check the relationship sections of your JDL, make sure the entities on both sides of the relationship exist and are spelled correctly.

Upvotes: 2

Related Questions