You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After #1 merges, we'll have the foundations in place, which is to say, we'll have a TypeRegistry that we can insert named types into and resolve them, possible in the scope of a specific pallet.
The next step, I think, should be to allow ingestion of some JSON file containing all of the necessary chain specific type information. So soemthing like:
Define a struct eg TypeDescriptions which accepts all of the relevant type information for a specific chain, eg:
A list of types which are globally relevant (Name -> Shape).
A list of types scoped to specific pallets (pallet, Name -> Shape).
Any of the above which are relevant only between certain spec versions.
(There is a typesSpec thing too in PJS but need to ask Tarik about this and work out if it's needed)
Have this format be deserializable from JSON. See about keeping the format similar to PJS if possible.
Allow default "substrate" types to exist and then be extended by such a JSON document. This means either:
Allow the TypeDescriptions type to be built/extended from more than one such JSON document
Allow the resulting type registry (below, TypeRegistrySet) to be built from multiple such documents.
Define something like a TypeRegistrySet which can be created by taking TypeDescriptions+ a spec version. This is internally a list of TypeRegistrys wherein we will try one at a time to locate some type. TypeRegistrySet will impl TypeResolver.
Start cobbling together a JSON doc with basic Substrate/Polkadot types, and write an example which takes some bytes of such types and decodes them (being able to somewhat manually decode a historic block would be ideal).
The text was updated successfully, but these errors were encountered:
After #1 merges, we'll have the foundations in place, which is to say, we'll have a
TypeRegistry
that we can insert named types into and resolve them, possible in the scope of a specific pallet.The next step, I think, should be to allow ingestion of some JSON file containing all of the necessary chain specific type information. So soemthing like:
TypeDescriptions
which accepts all of the relevant type information for a specific chain, eg:typesSpec
thing too in PJS but need to ask Tarik about this and work out if it's needed)TypeDescriptions
type to be built/extended from more than one such JSON documentTypeRegistrySet
) to be built from multiple such documents.TypeRegistrySet
which can be created by takingTypeDescriptions
+ a spec version. This is internally a list ofTypeRegistry
s wherein we will try one at a time to locate some type.TypeRegistrySet
will implTypeResolver
.The text was updated successfully, but these errors were encountered: