[SOLVED] Issues when switching from Mono to IL2CPP it throws this error Call to failed <methodName> due to: Error creating 'Nethereum.JsonRpc.Client.RpcMessages.RpcParametersJsonConverter'

In Unity, the issue arises when a smart contract is called while the build is in IL2CPP backend. I’ve been testing with Mono backend for quite a while and everything has been running smoothly. But for the purpose of publishing, I switched over to IL2CPP and since then this error occurs when I call smart contract in Android or iOS device.
Call to failed due to: Error creating ‘Nethereum.JsonRpc.Client.RpcMessages.RpcParametersJsonConverter’

I would like to know what could be the issue behind this?
I tried turning stripping off and adding the library causing issue in link.xml but to no avail.

Looking forward to what could be the reason for this.

Regardsa,
Sameer Hassan

I ended up fixing the issue myself.
The problem was that the selected JsonConverter was still stripping off instead of adding this into the link.xml file.
So, instead I tried adding complete libraries like Json, Nethereum, Moralis, etc. in my link.xml which caused the issue to go away.

2 Likes

Hii,
I am facing the same issue can you guide me through how you solved this issue, like where to find the link.xml file and how to add those libraries to the file.
It will be a great help.
Thanks

maybe this article helps: