Persisted entity object in widget-configuration cannot be deserialized (after reload)
I have a widget with a persisted entity object (e.g. MyNamespace\SpecialProduct derived from MyNamespace\Product) in its widget-configuration.
The object gets serialized in the session and is accessable in a ajax-request (everything works).
When i reload the page with the widget, the ajax calls fail with the following error:
Fatal error: ... The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "MyEntity" of the object you are trying to operate on was loaded before unserialize() gets called or provide a __autoload() function to load the class definition in "my widget ajax action controller" on line 65
I noticed that in Data/Temporary/Development/SubContextMyContext/Cache/Data/Flow_Session_Storage the entity is serialized. After reload the file contains the serialized entity two times. That seemes strange.