Skip to content
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

TypeManifest still written after generic type declared in knowntypes #240

Open
mrxrsd opened this issue Jul 11, 2021 · 1 comment
Open

Comments

@mrxrsd
Copy link

mrxrsd commented Jul 11, 2021

Hi,

I've tried to declare my generics type in known types but with no luck.

First I've tried that way:

public class KnownTypesProvider : IKnownTypesProvider {

private static List<Type> _knownTypes = new List<Type> {
      typeof(Akka.Persistence.Persistent),
      typeof(Event<>)
};
public IEnumerable<Type> GetKnownTypes() => _knownTypes;
}

But I got an exception on startup. So I've changed to:

public class KnownTypesProvider : IKnownTypesProvider {

private static List<Type> _knownTypes = new List<Type> {
      typeof(Akka.Persistence.Persistent),
      typeof(Event<TokenCreated>)
};
public IEnumerable<Type> GetKnownTypes() => _knownTypes;
}

Now my app are running but type manifest still be written . Is there any limitation about generics or I missed something?

@Aaronontheweb
Copy link
Member

What exception do you get at startup?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants