Could not load type 'ArchiSteamFarm.Plugins.Interfaces.IBotCommand'
Closed this issue · 4 comments
Error:
2022-03-03 00:40:41|dotnet-14196|ERROR|ASF|InitPlugins() Échec dû à une erreur : BoosterCreator, Version=1.2.1.0, Culture=neutral, PublicKeyToken=null
2022-03-03 00:40:41|dotnet-14196|ERROR|ASF|InitPlugins() System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types.
Could not load type 'ArchiSteamFarm.Plugins.Interfaces.IBotCommand' from assembly 'ArchiSteamFarm, Version=5.2.3.5, Culture=neutral, PublicKeyToken=504f46588cc351a9'.
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.Assembly.GetTypes()
at ArchiSteamFarm.Plugins.PluginsCore.InitPlugins()
System.TypeLoadException: Could not load type 'ArchiSteamFarm.Plugins.Interfaces.IBotCommand' from assembly 'ArchiSteamFarm, Version=5.2.3.5, Culture=neutral, PublicKeyToken=504f46588cc351a9'.
Possible Explanation:
[Deprecation] ASF plugins that implement IBotCommand interface or use Bot.HasAccess(), Commands.Response() functionality will need slight code changes in regards to changes done as part JustArchiNET/ArchiSteamFarm#2501. We tried our best to keep them working as part of this release - the deprecated functionality will be removed in the next release cycle.
https://github.com/JustArchiNET/ArchiSteamFarm/releases/tag/5.2.2.4
Useful references:
I can see several spots where the issue could come from:
implement IBotCommand interface
This should be IBotCommand2
.
The signature should be:
use Bot.HasAccess() functionality
This should be GetAccess()
and be compared to known values.
use Commands.Response() functionality
Yes, that's expected, most if not all my plugins will not work with new ASF version. Of course I'm willing to update plugins, but due to war in my country I can't tell you when (or if) this will happen.
Sure. ❤️ I guessed so, but still posted the issue so that it would be documented. I may try to have a look at the code.
Stay safe.