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

getAkashTypeRegistry function returns null - v0.10.0 #95

Open
TalPiven13 opened this issue May 22, 2024 · 1 comment
Open

getAkashTypeRegistry function returns null - v0.10.0 #95

TalPiven13 opened this issue May 22, 2024 · 1 comment

Comments

@TalPiven13
Copy link

import { getAkashTypeRegistry} from "@akashnetwork/akashjs/build/stargate"

const types = getAkashTypeRegistry();

console.log(types);

Current Result => undefined;

Expected Result => a map of all types created from Message enum using the string valued as keys and the interfaces for each one as value.

@ygrishajev
Copy link
Contributor

@TalPiven13 thanks for pointing at the issue. Although I'm unsure how we'd want to approach this atm I just want to provide some context.
Every message registers itself into the typeRegistry which happens on certain message file import/require. So to fix this every message you expect on the registry needs to be imported first.
Potentially we could solve this by dynamically importing all the types inside that function call but we'd need to give it some thought first.

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

No branches or pull requests

2 participants