-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Make all type information available via the metadata endpoint #7971
Comments
Yes this will be solved by using scale-info https://github.com/paritytech/scale-info so that full type description will be available in the metadata. cc @ascjones |
@thiolliere Thanks for that information. Do you have an idea of roughly when this feature will be rolled into substrate? We don't have an urgent need for it now but it would be good to know whether this is an imminent feature or something that still has large challenges to overcome (I don't believe for a second it's a trivial issue). |
I'm actively working on this, but I wouldn't expect it to be in master for a while yet. Not until March at least. I have a proof-of-concept branch https://github.com/paritytech/substrate/compare/aj-metadata-vnext to keep an eye on, but it is not in a working state at the moment. Also it depends on all pallets being converted to the new pallet attribute syntax #7882 so keep an eye on the progress there. |
Duplicates to #917 |
closed in favor of #917 |
Almost 2.5 years in the making :) This feature will (hopefully) lower the maintenance burden on the API-layer teams significantly. |
Hopefully in the next few weeks I can provide a working branch that will produce the new metadata to get some feedback on it. |
When I request the metadata from my node, I see a description of the Balances transfer call that looks like this:
However, nowhere in the rest of the metadata is it described the structure of the
LookupSource
datatype. This means there is no automatic way to determine what datatype is expected by the node when making calls to this API. Authors of the python and javascript API clients must manually maintain a mapping of high to low level types as you can see here:https://github.com/polkadot-js/api/tree/master/packages/types/src/interfaces/contracts
https://github.com/polkascan/py-scale-codec/tree/master/scalecodec/type_registry
Please make this information available in the existing metadata endpoint or perhaps a new endpoint.
The text was updated successfully, but these errors were encountered: