loopback-next icon indicating copy to clipboard operation
loopback-next copied to clipboard

[@loopback/sequelize] Nested Loopback model types are not supported

Open KalleV opened this issue 2 years ago • 0 comments

Describe the bug

If you have existing Loopback model properties set up that are nesting other Loopback models such as this "Address" example: https://github.com/loopbackio/loopback-next/blob/be0c53e30bbe9edf7753c4fcd7ab3199f7cd3b8c/packages/repository-json-schema/src/tests/unit/build-schema.unit.ts#L478-L518 it will lead to an error about unsupported types.

Logs

Example error:

Error: Unhandled DataType "class Address extends repository_1.Model {
  }" for column "address" in sequelize extension

Additional information

References: https://loopback.io/doc/en/lb4/Model.html#json-schema-inference

Reproduction

N/A

KalleV avatar Jul 17 '23 19:07 KalleV