We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System.TypeInitializationException HResult=0x80131534 Message=The type initializer for 'Senparc.NeuChar.MessageHandlers.MessageHandler3' threw an exception. Source=Senparc.NeuChar StackTrace: at Senparc.NeuChar.MessageHandlers.MessageHandler3..ctor(Stream inputStream, Int32 maxRecordCount, Object postData) at Senparc.Weixin.MP.MessageHandlers.MessageHandler`1..ctor(Stream inputStream, PostModel postModel, Int32 maxRecordCount, DeveloperInfo developerInfo) at MYOL.WeChatGZH.Service.CustomMessageHandler..ctor(String appId, String appSecret, Stream inputStream, PostModel postModel, Int32 maxRecordCount) in D:\zzh\MYOL.WeChatGZH\MYOL.WeChatGZH\Service\CustomMessageHandler.cs:line 52 at MYOL.WeChatGZH.Controllers.WeixinController.Post(PostModel postModel) in D:\zzh\MYOL.WeChatGZH\MYOL.WeChatGZH\Controllers\WeixinController.cs:line 104 at Microsoft.Extensions.Internal.ObjectMethodExecutor.Execute(Object target, Object[] parameters) at Microsoft.AspNetCore.Mvc.Internal.ActionMethodExecutor.SyncActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.d__12.MoveNext()
3' threw an exception. Source=Senparc.NeuChar StackTrace: at Senparc.NeuChar.MessageHandlers.MessageHandler
内部异常 1: TypeInitializationException: The type initializer for 'Senparc.NeuChar.Register' threw an exception.
内部异常 2: TypeInitializationException: The type initializer for 'Nested' threw an exception.
内部异常 3: ArgumentNullException: Value cannot be null.
The text was updated successfully, but these errors were encountered:
请升级到最新的版本试一下,比较有可能的是 PostModel 没有传入。或者没有按照Demo示例的方法进行注册。您可以更新到最新的版本试一下,如果还有问题可以提供一下Startup和WeixinController的代码帮你看一下。邮件:zsu@senparc.com
Sorry, something went wrong.
是少了 services.AddSenparcGlobalServices(Configuration)//Senparc.CO2NET 全局注册 .AddSenparcWeixinServices(Configuration);//Senparc.Weixin 注册 这两个,今天找到原因了
No branches or pull requests
System.TypeInitializationException
HResult=0x80131534
Message=The type initializer for 'Senparc.NeuChar.MessageHandlers.MessageHandler
3' threw an exception. Source=Senparc.NeuChar StackTrace: at Senparc.NeuChar.MessageHandlers.MessageHandler
3..ctor(Stream inputStream, Int32 maxRecordCount, Object postData)at Senparc.Weixin.MP.MessageHandlers.MessageHandler`1..ctor(Stream inputStream, PostModel postModel, Int32 maxRecordCount, DeveloperInfo developerInfo)
at MYOL.WeChatGZH.Service.CustomMessageHandler..ctor(String appId, String appSecret, Stream inputStream, PostModel postModel, Int32 maxRecordCount) in D:\zzh\MYOL.WeChatGZH\MYOL.WeChatGZH\Service\CustomMessageHandler.cs:line 52
at MYOL.WeChatGZH.Controllers.WeixinController.Post(PostModel postModel) in D:\zzh\MYOL.WeChatGZH\MYOL.WeChatGZH\Controllers\WeixinController.cs:line 104
at Microsoft.Extensions.Internal.ObjectMethodExecutor.Execute(Object target, Object[] parameters)
at Microsoft.AspNetCore.Mvc.Internal.ActionMethodExecutor.SyncActionResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.d__12.MoveNext()
内部异常 1:
TypeInitializationException: The type initializer for 'Senparc.NeuChar.Register' threw an exception.
内部异常 2:
TypeInitializationException: The type initializer for 'Nested' threw an exception.
内部异常 3:
ArgumentNullException: Value cannot be null.
The text was updated successfully, but these errors were encountered: