i got this issue with a circular dependency on blueprints on ue5. and solved by referencing the base class of one of them (it was a simple cast check).
this is still an issue and i was able to avoid it, but seems like it can become a big issue in the future.