Error: Cannot read properties of undefined (reading 'attributes') TypeError: Cannot read properties of undefined (reading 'attributes') Strapi 4

I’m having this same issue after migrating a v3 app and following the docs. Most everything is default from the factory methods. It just doesn’t like something about the setup because this happens before or after any data is added (from the data migration scripts… i.e., they don’t make any difference).

Any clues on where to look would be appreciated:

[2022-07-31 01:25:30.939] debug: ⛔️ Server wasn't able to start properly.
[2022-07-31 01:25:30.939] error: Cannot read properties of undefined (reading 'attributes')
TypeError: Cannot read properties of undefined (reading 'attributes')
    at Object.getNonVisibleAttributes (/Users/rian/github/devoe-strapi-4/node_modules/@strapi/utils/lib/content-types.js:69:11)
    at getNestedFields (/Users/rian/github/devoe-strapi-4/node_modules/@strapi/admin/server/services/content-type.js:30:51)
    at /Users/rian/github/devoe-strapi-4/node_modules/@strapi/admin/server/services/content-type.js:43:31
    at /Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:928:11
    at /Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:4967:15
    at baseForOwn (/Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:3032:24)
    at /Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:4936:18
    at baseReduce (/Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:925:5)
    at Function.reduce (/Users/rian/github/devoe-strapi-4/node_modules/lodash/lodash.js:9749:14)
    at getNestedFields (/Users/rian/github/devoe-strapi-4/node_modules/@strapi/admin/server/services/content-type.js:32:12)
1 Like