XXX is a ChangeTracker but has no PropertyChangeListener

Dear CUBA team,
I have a custom app component which contains a few screens and entities. I’ve tested it separately and everything works fine. But after I integrated it into another CUBA application I got a strange error which you can find in attachment.
What I can say is I didn’t do much on the component just added some screen from the CUBA Studio and some entities with a few fields.
I have googled and searched on the forum and I didn’t find any clue. it will be highly appreciated if I can get any help from you.

Thanks for your time.

Jietu20170627-114720

2 Likes

Hi,

This problem is related to entity classes enhancing (bytecode modification) at build time. Make sure that global modules in all your app components have build/enhanced-classes directories and the resulting JAR files contain classes exactly from this directories.

Hi,
First of all, thanks for the timely response.
I have double checked. Every class file is from the enhanced-classes folder. I have to mention that only entities from app component raise such error but entities in my application are fine.
Is there anything I missed.

Could you try to reproduce it on a test project? (actually two projects - a component and an app)

Sorry for late. Finally, I found the root cause, I have a local copy gradle which version is 4.0. I used this gradle to compile and I think this cause some mismatch with CUBA studio built-in version of gradle. After I use gradle inside studio to build my project from scratch everything works. now I can move on.

Thanks for your help.

Good. Thank you for explaining the cause. We haven’t tested build with Gradle 4.0 yet. The upcoming platform version 6.6 will use Gradle 3.4 by default.

Hi guys sorry to jump on this thread, but I am having the same issue but after inserting entities via REST.
The scenario is as follows:
Route entity is created via gui - no problem
RouteLog entity (1-*) tries to insert via REST from mobile app/postman - then the error ocurrs and I can no longer use the Route created before.

Any help on this? Am I doing something wrong

Thanks for any help

Did you try to clean and rebuild your application?

Hi thanks for the response, yes I even cleaned the gradle cache and downloaded all dependencies again. And after this the Route entity gets corrupted I have to re-create DB again

How does it relate to DB? What exactly exception do you get?

After the exception is thrown any Route entity cannot be accessed.
here is the exception just trying to browse Route entity.

So this entity is not enhanced for some reason.

In your project’s global module there should be build/enhanced-classes folder. Please make sure that it contains your Route entity class, and this class is exactly the same as packed inside your *-global.jar artifact.