-
-
Notifications
You must be signed in to change notification settings - Fork 182
New issue
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
Dictionary<string,byte[]> formatter is being trimmed with PublishAot #272
Comments
Is there any update? I have even attempted to somehow extract and create an instance of the required formatter myself, as I know the types at design time, but it has proven to be very difficult since a lot of the api's require use of inaccessible internal MemoryPack types/properties... I'd even settle for a workaround, specifically for |
Maybe you can put following code somewhere to prevent trimming. MemoryPackFormatterProvider.RegisterDictionary<Dictionary<string, byte[]>, string, byte[]>(); Or use a |
The formatters for IMemoryPackable implementing types are also being trimmed. Is looks like it is possible to register the formatters like you noted, but with many types, it seems verbose, and should probably happen automatically, this is the entire idea behind the attributes I assume... |
Yes, it should happen automatically as you said, registering the formatters manually is just a workaround. |
Seems that the formatter that is being used internally in MemoryPack for
Serialize(Dictionary<string,byte[])
is being trimmed, and the use of such object is now entirely broken.The text was updated successfully, but these errors were encountered: