Try our conversational search powered by Generative AI!

Error when synchronizing a model with an property of type XForm

Vote:
 

Hi,

I am working on an upgrade of a site to Episerver CMS 11.x and getting a strange error when the BackingTypeResolver is synchronizing models.

[NotSupportedException: Specified method is not supported.]
EPiServer.DataAbstraction.Internal.BackingTypeResolver.get_XForm() +28

Peeking into the code, this method surely throws a NotImplemented exception. The question is why this is happening though. I have added the Episerver.XForms nuget package and compilation of the solution does not have any problems.

I cannot find any information about breaking changes that could cause this. Anyone that has seen this or have a clue of why it´s happening?
#196781
Sep 11, 2018 15:29
Vote:
 

Have you added the nuget package EPiServer.XForms (it has been broken out to its own package)?

#196796
Sep 11, 2018 18:07
Vote:
 

Yes, the Episerver.XForms package is added and from what I can see of the fusion logs, the Episerver.XForms assembly is loading correctly. I can see how the XForms assembly tries to override the BackingTypeResolver but this does not seem to happen for me. Not sure if it´s related to how the IOC inititialization is done. The project uses StructureMap initialization direcly but I cannot see what should be causing the error. Will continue trying to resolve it today, but suggestions are welcome :)

#196851
Sep 13, 2018 11:39
Vote:
 

I finally found the error. The assembly was marked as non-scannable in the configuration, so the autoinjection to the IOC was never done due to this. Adding an sample of how the configuration looked like if someone else encounters this:

<episerver.framework updateDatabaseSchema="true">
<scanAssembly forceBinFolderScan="true">
<add assembly="*" />
<remove assembly="EPiServer.XForms" />

#196860
Sep 13, 2018 16:00
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.